Summary
Extend APM marketplace support so a marketplace can be registered from a URL-based discovery index, including standards-compliant Agent Skills discovery endpoints such as:
https://example.com/.well-known/agent-skills/index.json
- or an origin that resolves to that index, such as
https://example.com
The primary UX should be:
apm marketplace add https://example.com/.well-known/agent-skills/index.json --name workbooks
apm install code-review@workbooks
and optionally also:
apm marketplace add https://example.com --name workbooks --type well-known
apm install code-review@workbooks
This keeps the existing NAME@MARKETPLACE install flow intact while allowing marketplace backends that are not GitHub repos with marketplace.json.
Why
Today APM marketplace registration assumes a Git repository source:
apm marketplace add OWNER/REPO
- fetch
marketplace.json
- install with
plugin-name@marketplace-name
That works for GitHub/Git-hosted indexes, but it does not work for the open Agent Skills discovery model, where the source of truth is an HTTP origin exposing a standards-based index at /.well-known/agent-skills/index.json.
Supporting URL-based marketplace registration would:
- preserve the current
name@marketplace UX
- let APM consume standards-compliant Agent Skills catalogs
- avoid inventing a separate skill install syntax
- reduce implementation duplication by treating well-known discovery as another marketplace backend
- make APM friendlier for internal enterprise domains and non-GitHub publishers
Reference Specs
Related Issues
Relevant points:
- Skills are centered on
SKILL.md with required name and description.
- Discovery is origin-based through
/.well-known/agent-skills/.
- Publishers should expose
/.well-known/agent-skills/index.json.
- The index lists skill entries with metadata such as
name, type, description, url, and optional digest.
- RFC 8615 security considerations apply because
/.well-known/ is origin-scoped metadata.
Design Direction
This should follow marketplace flow, not introduce a separate install model.
That means:
- registration remains
apm marketplace add ... --name workbooks
- install remains
apm install code-review@workbooks
- browse/search/update/remove continue to work under the marketplace command group
- the implementation generalizes the marketplace source model rather than adding a second discovery subsystem with different UX
In short:
- same install UX as current marketplaces
- new marketplace backend for URL-based discovery indexes
Update Semantics
The issue should explicitly preserve the same update model APM already uses for marketplaces:
1. Marketplace index updates
These update discovery metadata, not the installed dependency itself.
For URL-backed marketplaces:
apm marketplace update workbooks
should:
- re-fetch the registered URL-backed index
- refresh the local marketplace cache
- update what
browse, search, and future name@marketplace resolutions see
- not silently change already-installed skills in the project
2. Installed dependency updates
Installed skills should continue to be controlled by normal install/update flows and the lockfile.
That means:
apm install code-review@workbooks resolves using the current marketplace index
- the resolved artifact URL, digest, and provenance are then written into
apm.lock.yaml
- once installed, the project stays pinned to what was resolved at install time
- if the publisher later changes
/.well-known/agent-skills/index.json, the existing project should not drift automatically
- users must explicitly re-run install/update flows to adopt the newly published artifact
3. Publisher behavior at the well-known URL
Publishers manage updates by changing the well-known discovery index.
Examples of publisher-managed changes:
- updating a skill's
description
- changing the artifact
url
- publishing a new
digest
- adding or removing skills from the index
APM should consume those changes only after the user refreshes marketplace metadata and then performs an install/update action.
4. Lockfile responsibility
The lockfile is the boundary between discovery and installation.
The well-known URL controls:
- what skills are discoverable
- what artifact URL and digest are currently advertised
The lockfile controls:
- what artifact was actually installed in this project
- what provenance should be shown later
- whether future installs count as an update or remain unchanged
5. Required provenance for update management
To make update behavior clear and auditable, URL-backed marketplace installs should record at least:
- marketplace name
- marketplace source type
- index URL and/or origin URL
- resolved artifact URL at install time
- digest from the index if present
- locally computed content hash of the fetched skill artifact or fetched file set
This allows APM to distinguish:
- marketplace metadata changed
- publisher-advertised artifact changed
- installed artifact changed
- lockfile still points to the previous artifact
6. Digest-first update algorithm
When the discovery index provides a digest, APM should use it as the fast-path signal for update detection.
Recommended behavior during explicit install/update flows:
- Resolve
skill-name@marketplace against the latest marketplace index.
- If the index provides a digest:
- compare the advertised digest to the digest stored in the lockfile
- if the digest matches, treat the install as a no-op unless the user explicitly forces a reinstall
- if the digest differs, fetch the artifact and verify the fetched content matches the advertised digest before accepting the update
- If the index does not provide a digest:
- fetch the skill files needed for installation
- compute a deterministic local content hash
- compare that hash to the value stored in the lockfile
- After a successful install/update:
- store the advertised digest if present
- store the locally computed content hash
This gives APM two useful signals:
- publisher digest for cheap update detection
- local content hash for integrity verification and fallback when digest is missing
7. Metadata-only changes
If only index metadata changes, such as:
- description text
- ordering in the index
- non-install-affecting index fields
and the digest or local content hash does not change, APM should treat the installed skill as unchanged.
Scope
In scope
- allow
apm marketplace add <URL> --name <marketplace>
- support well-known Agent Skills indexes as a marketplace backend
- resolve
skill-name@marketplace-name against the registered URL-based index
- download and install the selected skill through the existing APM install pipeline
- persist provenance in
apm.lock.yaml
- add trust/policy controls for URL-based marketplace origins
- document the new registration flow
- document how marketplace metadata updates differ from installed dependency updates
- document digest-first update checks with local hash fallback
Out of scope for the first iteration
- replacing the existing Git-based marketplace flow
- publisher tooling for generating
/.well-known/agent-skills/
- arbitrary multi-origin search/federation
- background crawling outside explicit marketplace registration
- remote activation without install/lockfile resolution
- automatic background upgrade of installed skills when the well-known index changes
Detailed Plan
1. Generalize the marketplace source model
Goal: make one marketplace registry capable of storing either repo-backed sources or URL-backed sources.
Steps:
Definition of done:
2. Extend apm marketplace add to accept URLs
Goal: users can register a well-known Agent Skills index without referencing a Git repo.
Steps:
Definition of done:
3. Add parsing for well-known Agent Skills indexes
Goal: parse /.well-known/agent-skills/index.json into a structure the marketplace layer can use.
Steps:
Definition of done:
4. Generalize marketplace fetching and caching
Goal: one marketplace client can fetch both Git-hosted marketplace.json and URL-based skill indexes.
Steps:
Definition of done:
5. Map URL-based index entries into marketplace items
Goal: name@workbooks resolves using the same marketplace flow regardless of backend type.
Steps:
Definition of done:
6. Resolve name@marketplace into an installable artifact
Goal: the install command can resolve a marketplace item into a concrete remote artifact without changing user syntax.
Steps:
Definition of done:
7. Download and normalize discovered skill artifacts
Goal: remote artifacts discovered through a URL-backed marketplace are converted into something APM already knows how to install.
Steps:
Definition of done:
8. Reuse the existing package validation and skill integration flow
Goal: keep the implementation centered on the current APM install pipeline rather than a custom remote-skill path.
Steps:
Definition of done:
9. Tighten validation for standards-based remote skills
Goal: standards-based indexes should get standards-based validation.
Steps:
Definition of done:
10. Capture provenance in the lockfile
Goal: installs remain auditable and reproducible even when the backing index changes.
Steps:
Definition of done:
11. Add security and governance controls
Goal: URL-based marketplaces introduce origin trust concerns that need explicit policy.
Steps:
Definition of done:
12. Make all marketplace commands work with URL-backed sources
Goal: adding a new backend should not fragment the marketplace UX.
Steps:
Definition of done:
13. Document the new flow
Goal: explain the feature in terms users and maintainers can actually follow.
Steps:
Definition of done:
14. Add tests in implementation order
Goal: land the feature with enough coverage to refactor safely.
Steps:
Definition of done:
15. Deliver in phases
Goal: keep the first merge small enough to review and ship.
Phase 1:
Phase 2:
Phase 3:
Acceptance Criteria
Open Questions
- Should
--type well-known be required for origin URLs, or should APM infer it?
- Should both direct index URL and origin URL forms be supported in v1?
- Should URL-based marketplace sources be limited to well-known Agent Skills indexes in the first iteration, or generalized to arbitrary JSON indexes?
- Should first iteration support only
skill-md, or also archives?
- Should strict Agent Skills validation apply only to URL-backed standards-based sources, or to all skill installs?
Notes on Current Code Fit
Relevant existing areas that appear reusable:
- marketplace caching and index parsing under
src/apm_cli/marketplace/
- marketplace source modeling in
src/apm_cli/marketplace/models.py
- marketplace registry in
src/apm_cli/marketplace/registry.py
- marketplace resolution in
src/apm_cli/marketplace/resolver.py
- dependency normalization in
src/apm_cli/models/dependency/reference.py
- package validation in
src/apm_cli/models/validation.py
- skill deployment in
src/apm_cli/integration/skill_integrator.py
- install and resolver pipeline under
src/apm_cli/commands/install.py and src/apm_cli/deps/
- policy infrastructure under
src/apm_cli/policy/
This should be implemented as a generalization of the current marketplace model so the user-facing install experience remains name@marketplace regardless of whether the marketplace is backed by a Git repo or a URL-based discovery index.
Summary
Extend APM marketplace support so a marketplace can be registered from a URL-based discovery index, including standards-compliant Agent Skills discovery endpoints such as:
https://example.com/.well-known/agent-skills/index.jsonhttps://example.comThe primary UX should be:
and optionally also:
This keeps the existing
NAME@MARKETPLACEinstall flow intact while allowing marketplace backends that are not GitHub repos withmarketplace.json.Why
Today APM marketplace registration assumes a Git repository source:
apm marketplace add OWNER/REPOmarketplace.jsonplugin-name@marketplace-nameThat works for GitHub/Git-hosted indexes, but it does not work for the open Agent Skills discovery model, where the source of truth is an HTTP origin exposing a standards-based index at
/.well-known/agent-skills/index.json.Supporting URL-based marketplace registration would:
name@marketplaceUXReference Specs
Related Issues
.well-knownURIs #554Relevant points:
SKILL.mdwith requirednameanddescription./.well-known/agent-skills/./.well-known/agent-skills/index.json.name,type,description,url, and optionaldigest./.well-known/is origin-scoped metadata.Design Direction
This should follow marketplace flow, not introduce a separate install model.
That means:
apm marketplace add ... --name workbooksapm install code-review@workbooksIn short:
Update Semantics
The issue should explicitly preserve the same update model APM already uses for marketplaces:
1. Marketplace index updates
These update discovery metadata, not the installed dependency itself.
For URL-backed marketplaces:
should:
browse,search, and futurename@marketplaceresolutions see2. Installed dependency updates
Installed skills should continue to be controlled by normal install/update flows and the lockfile.
That means:
apm install code-review@workbooksresolves using the current marketplace indexapm.lock.yaml/.well-known/agent-skills/index.json, the existing project should not drift automatically3. Publisher behavior at the well-known URL
Publishers manage updates by changing the well-known discovery index.
Examples of publisher-managed changes:
descriptionurldigestAPM should consume those changes only after the user refreshes marketplace metadata and then performs an install/update action.
4. Lockfile responsibility
The lockfile is the boundary between discovery and installation.
The well-known URL controls:
The lockfile controls:
5. Required provenance for update management
To make update behavior clear and auditable, URL-backed marketplace installs should record at least:
This allows APM to distinguish:
6. Digest-first update algorithm
When the discovery index provides a
digest, APM should use it as the fast-path signal for update detection.Recommended behavior during explicit install/update flows:
skill-name@marketplaceagainst the latest marketplace index.This gives APM two useful signals:
7. Metadata-only changes
If only index metadata changes, such as:
and the digest or local content hash does not change, APM should treat the installed skill as unchanged.
Scope
In scope
apm marketplace add <URL> --name <marketplace>skill-name@marketplace-nameagainst the registered URL-based indexapm.lock.yamlOut of scope for the first iteration
/.well-known/agent-skills/Detailed Plan
1. Generalize the marketplace source model
Goal: make one marketplace registry capable of storing either repo-backed sources or URL-backed sources.
Steps:
MarketplaceSourceshape insrc/apm_cli/marketplace/models.pyand list which fields are GitHub/repo-specific.source_typediscriminator such asrepo,url_index, orwell_known.url,index_url, and optionalorigin_url.to_dict()so repo-backed entries serialize exactly as they do today unless new fields are needed.from_dict()to load both old registry entries and new URL-backed entries.Definition of done:
~/.apm/marketplaces.jsoncan contain a mix of both source types.2. Extend
apm marketplace addto accept URLsGoal: users can register a well-known Agent Skills index without referencing a Git repo.
Steps:
src/apm_cli/commands/marketplace.pyadd()and identify where input is currently assumed to beOWNER/REPOorHOST/OWNER/REPO.apm marketplace add https://example.com/.well-known/agent-skills/index.json --name workbooksapm marketplace add https://example.com --name workbooks --type well-known--type well-knownis supported, resolve the origin tohttps://example.com/.well-known/agent-skills/index.json.NAME@MARKETPLACErules.Definition of done:
apm marketplace add OWNER/REPOstill works.apm marketplace add https://example.com/.well-known/agent-skills/index.json --name workbooksworks.3. Add parsing for well-known Agent Skills indexes
Goal: parse
/.well-known/agent-skills/index.jsoninto a structure the marketplace layer can use.Steps:
$schemafield.skillsarray.nametypedescriptionurldigesturlvalues against the registered index URL.Definition of done:
4. Generalize marketplace fetching and caching
Goal: one marketplace client can fetch both Git-hosted
marketplace.jsonand URL-based skill indexes.Steps:
src/apm_cli/marketplace/client.pyand separate repo-specific fetch logic from generic cache logic.apm marketplace update <name>refreshes for URL-backed marketplaces.Definition of done:
5. Map URL-based index entries into marketplace items
Goal:
name@workbooksresolves using the same marketplace flow regardless of backend type.Steps:
src/apm_cli/marketplace/resolver.pyand identify where it assumes a plugin source comes from repo metadata.name,description, and source marketplace name.find_plugin()/search-style behavior can work for URL-backed entries too.Definition of done:
code-review@workbooksfrom a URL-backed marketplace.6. Resolve
name@marketplaceinto an installable artifactGoal: the install command can resolve a marketplace item into a concrete remote artifact without changing user syntax.
Steps:
name@marketplaceresolution path from CLI input throughparse_marketplace_ref()toresolve_marketplace_plugin().Definition of done:
apm install code-review@workbooksresolves to a specific URL-backed skill artifact.name@marketplacerepo-backed resolution still works.7. Download and normalize discovered skill artifacts
Goal: remote artifacts discovered through a URL-backed marketplace are converted into something APM already knows how to install.
Steps:
skill-mdfirst.skill-mdentries:SKILL.mdSKILL.mdand not related assets referenced from the file.Definition of done:
skill-mdartifact can be turned into a local temporary package.8. Reuse the existing package validation and skill integration flow
Goal: keep the implementation centered on the current APM install pipeline rather than a custom remote-skill path.
Steps:
SKILL.mdpackages are validated insrc/apm_cli/models/validation.py.src/apm_cli/integration/skill_integrator.py.PackageInfoandAPMPackagestill carry what downstream code needs.Definition of done:
9. Tighten validation for standards-based remote skills
Goal: standards-based indexes should get standards-based validation.
Steps:
SKILL.mdhandling in validation code.nameanddescription.licensecompatibilitymetadataallowed-toolsDefinition of done:
10. Capture provenance in the lockfile
Goal: installs remain auditable and reproducible even when the backing index changes.
Steps:
deps list,deps tree, andviewcan surface useful provenance for these installs.no change,metadata changed only, orartifact changed.Definition of done:
11. Add security and governance controls
Goal: URL-based marketplaces introduce origin trust concerns that need explicit policy.
Steps:
src/apm_cli/policy/.digestis present in the index.Definition of done:
12. Make all marketplace commands work with URL-backed sources
Goal: adding a new backend should not fragment the marketplace UX.
Steps:
apm marketplace listto show the source kind for each registration.apm marketplace browseso it can render entries from URL-backed indexes.apm marketplace updateto refresh URL-backed caches.apm marketplace removeto unregister URL-backed marketplaces cleanly.apm search "query@marketplace"still works from the user’s perspective.marketplace updaterefreshes index metadata and does not auto-upgrade already-installed skills.Definition of done:
13. Document the new flow
Goal: explain the feature in terms users and maintainers can actually follow.
Steps:
apm marketplace add https://example.com/.well-known/agent-skills/index.json --name workbooksapm install code-review@workbooks--type well-known.apm.ymlandapm.lock.yaml.marketplace.jsonindexes and standards-based well-known indexes.apm marketplace update <name>refreshes discovery metadata onlyDefinition of done:
14. Add tests in implementation order
Goal: land the feature with enough coverage to refactor safely.
Steps:
name@marketplaceskill-name@workbooksadd -> browse/search -> installDefinition of done:
15. Deliver in phases
Goal: keep the first merge small enough to review and ship.
Phase 1:
apm marketplace add https://example.com/.well-known/agent-skills/index.json --name workbooks.skill-mdinstall vianame@marketplace.Phase 2:
Phase 3:
--type well-knownif deferred.Acceptance Criteria
apm install code-review@workbooksafter registeringworkbooksfrom a URL-based index.apm.lock.yamlcaptures marketplace name plus backing URL provenance, advertised digest when present, and a local content hash.apm marketplace update <name>refreshes only marketplace metadata and does not silently upgrade already-installed skills.Open Questions
--type well-knownbe required for origin URLs, or should APM infer it?skill-md, or also archives?Notes on Current Code Fit
Relevant existing areas that appear reusable:
src/apm_cli/marketplace/src/apm_cli/marketplace/models.pysrc/apm_cli/marketplace/registry.pysrc/apm_cli/marketplace/resolver.pysrc/apm_cli/models/dependency/reference.pysrc/apm_cli/models/validation.pysrc/apm_cli/integration/skill_integrator.pysrc/apm_cli/commands/install.pyandsrc/apm_cli/deps/src/apm_cli/policy/This should be implemented as a generalization of the current marketplace model so the user-facing install experience remains
name@marketplaceregardless of whether the marketplace is backed by a Git repo or a URL-based discovery index.