Files
holocron/plugins/kyberforge/docs/research/docs/microsoft-apm/cli-reference.md
Defame1297 1d07d1a76b docs(kyberforge): add Microsoft APM research reference set
Capture Microsoft's Agent Package Manager (APM) — overview, install,
config, CLI reference, registries/marketplace, monorepo shapes,
testing/validation, troubleshooting, and examples — as structured
reference docs under plugins/kyberforge/docs/research/docs/microsoft-apm/.

Lays the groundwork for issue #88 (build agents/skills to execute a
marketplace-to-APM conversion of this repo).
2026-08-10 17:06:07 +00:00

3.3 KiB

topic, source_keys
topic source_keys
cli-reference
context7-microsoft-apm

Install

apm install [PACKAGE_REF...] [OPTIONS]

With no arguments, resolves and installs everything declared in apm.yml against apm.lock.yaml. Explicit PACKAGE_REF arguments (e.g. acme/internal-tools#^1.0.0) install and add that dependency. apm install --update re-resolves and accepts new upstream content even when it doesn't match the recorded lockfile hash (see troubleshooting). apm install --target agent-skills generates a vendor-neutral output directory for IDE-agnostic tool support instead of a harness-specific one.

Compile

apm compile

Generates per-target output (Claude, Copilot, etc.) from the vendor-neutral .apm/ primitive source tree, per the compilation: block in apm.yml.

Pack

apm pack --dry-run              # resolve and print; do not write
apm pack --offline              # cached refs only
apm pack --include-prerelease   # allow pre-release tags
apm pack -v                     # per-entry resolution detail
apm pack --marketplace=claude --json   # JSON output for CI pipelines

Bundles a producer package into a distributable artifact.

Publish

apm publish --package acme/my-skill --dry-run -v
apm publish --package acme/my-skill

Publishes a producer package (root containing apm.yml, .apm/, and optionally a registries: block) to a registry. Always dry-run with -v first to see resolution detail before publishing for real.

Runtime management

apm runtime setup copilot              # install with APM defaults
apm runtime setup codex --version 0.20.0   # pinned version
apm runtime setup llm --vanilla        # skip APM-managed config
apm runtime list                       # what's installed
apm runtime status                     # which runtime `apm run` will pick
apm runtime remove gemini -y           # uninstall without prompting

Run

apm run <script> [--param key=value]

Executes a named script defined under scripts: in apm.yml, with --param substituting values into the script's parameters (used, for example, when the script wraps a Gemini CLI invocation).

Audit (validation)

apm audit                  # local: scan deployed files for hidden Unicode
apm audit --ci             # CI gate: lockfile consistency + drift replay + policy
apm audit --file <path>    # standalone: scan an arbitrary file

See testing-and-validation.md for CI wiring and exit-code behavior.

Marketplace

apm marketplace init                          # add the marketplace: block to apm.yml
apm marketplace check                         # validate every listed package ref resolves
apm marketplace package add <path> --name <n> # register a local package into the marketplace
apm marketplace add <source> [--name <n>]     # register a marketplace as a consumer (see marketplace-and-registries.md for source forms)

Plugin scaffolding

apm plugin init <name> --yes

Scaffolds a new package's apm.yml + .apm/ skeleton in the current directory.

Config

apm config set <key> <value>
apm config get <key>
apm config unset <key>
apm experimental enable registries   # required before registry.* config takes effect

Used for workstation-level settings such as private registry URLs/tokens (see marketplace-and-registries.md).