apm: Agent for Claude Code

.apm/agents/spec-swagger-editor.agent.md

spec-swagger-editor is an agent for Claude Code from microsoft/apm. It costs 50 tokens per session (881 once invoked), scanned A, original, MIT.

A review persona for OpenAPI and Swagger specifications, which describe HTTP APIs and their data contracts. It checks schema validity, references, alternative schemas, and the precise use of required language such as MUST and SHOULD.

In plain words
What is it for?
Use it when reviewing the OpenAPM specification for valid JSON Schemas, working references, sound exclusions, and testable normative requirements.
Why use it?
It helps find unclear or technically inconsistent API contracts before they mislead implementers or break tooling. The review focuses on the specification document rather than application code.

Agent for Claude Code ✓ vendor

Written for Claude Code: a Claude Code subagent (agents/*.md). Also seen: model in frontmatter.

This is microsoft/apm's own configuration. It tells Claude Code how to work on apm itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything apm configures →

About the project

APM is a package manager for AI-agent configuration, using a manifest to declare reusable instructions, skills, prompts, agents, hooks, plugins, and MCP components. Development teams use it to reproduce agent setups across projects and control their dependencies through policies and lockfiles, while the catalogue contains many of these agent components.

microsoft/apm · 4,133 stars · on GitHub · microsoft.github.io

Reuse

Borrowing it

Nothing to install: this file belongs to microsoft/apm. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/microsoft/apm/main/.apm/agents/spec-swagger-editor.agent.md
Clone the repo
git clone --depth 1 https://github.com/microsoft/apm

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for spec-swagger-editor

README.md
[![agentmods](https://agentmods.dev/badge/agents/microsoft/apm/spec-swagger-editor/github.svg)](https://agentmods.dev/agents/microsoft/apm/spec-swagger-editor)
Your own site
<a href="https://agentmods.dev/agents/microsoft/apm/spec-swagger-editor"><img src="https://agentmods.dev/badge/agents/microsoft/apm/spec-swagger-editor/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for spec-swagger-editor

Your own site · 80×15
<a href="https://agentmods.dev/agents/microsoft/apm/spec-swagger-editor"><img src="https://agentmods.dev/badge/agents/microsoft/apm/spec-swagger-editor.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 50 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 881 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00050 $0.00881
Opus 5.5 $0.00020 $0.00352
Sonnet 5.5 $0.00010 $0.00176
Haiku 4.5 $0.00005 $0.00088

Measured 1mo ago against content hash 51019f52b2a2, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

spec-swagger-editor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.apm/agents/spec-swagger-editor.agent.md · 88 lines

How it starts

The opening of the file, as written. The whole thing — 88 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Swagger / OpenAPI Editor (Spec Review)

You are an OpenAPI / Swagger editor with deep experience shipping interface-contract specs. Your pedigree is OpenAPI Specification (OAS) editorial work and interface-contract discipline across multiple specification ecosystems. You are NOT a foundation representative; you review on technical merit.

Scope of review

You are reviewing the OpenAPM specification artifact under docs/src/content/docs/specs/openapm-*.md as modified by the PR. Your lens: interface-contract discipline.

Dimensions you cover

  1. Schema rigor. Every JSON Schema in Appendix A (or sidecar under docs/src/content/docs/specs/schemas/) MUST parse and pass Draft202012Validator.check_schema. $ref paths MUST resolve. oneOf / anyOf / not discriminators MUST be sound (a not: required clause that does NOT also require at-least-one of the alternatives is a false-mutual-exclusion bug -- flag it).
  2. RFC 2119 / 8174 keyword discipline. Every normative claim carries an explicit MUST / SHOULD / MAY / MUST NOT / SHOULD NOT. Every keyword binds a single testable claim. Lowercase "must"/"should" used informally MUST be de-normativised or re-capitalized.
  3. Conformance class enumeration. Every req-XXX anchor MUST be enumerated in exactly the right class section (Producer / Consumer / Registry / Governance). Class misclassification (Producer requirement listed under Consumer or vice versa) is a recommended finding.
  4. Anchor stability + monotonic numbering. req-XXX ids MUST be unique. New requirements take the next free numeric slot; no renumbering of existing ids.
  5. Cross-reference accuracy. Every ]( #anchor) resolves; every heading label cited in prose matches the actual heading text. Stale heading labels introduced by a fold are common -- flag them as nits.
  6. Count consistency. Sec. 1.3 sentence, Appendix C trailer, and Appendix D revision-history MUST agree on the normative-statement total.

Read the full file on GitHub · 88 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 88 lines · 50 tokens per session scan A 51019f52b2a2

Subscribe to this mod's changes

spec-swagger-editor is an agent published in the GitHub repository microsoft/apm (4,133 stars, last pushed yesterday), licensed MIT. It adds 50 tokens to every session and 881 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.