Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add atretyak1985/swarmery --skill api-contractgit clone --depth 1 https://github.com/atretyak1985/swarmeryWrote 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.
[](https://agentmods.dev/skills/atretyak1985/swarmery/api-contract)<a href="https://agentmods.dev/skills/atretyak1985/swarmery/api-contract"><img src="https://agentmods.dev/badge/skills/atretyak1985/swarmery/api-contract/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.
<a href="https://agentmods.dev/skills/atretyak1985/swarmery/api-contract"><img src="https://agentmods.dev/badge/skills/atretyak1985/swarmery/api-contract.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00049 | $0.00855 |
| Opus 5.5 | $0.00020 | $0.00342 |
| Sonnet 5.5 | $0.00010 | $0.00171 |
| Haiku 4.5 | $0.00005 | $0.00085 |
Grade A, and why
api-contract 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 3mo 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.
How it starts
The opening of the file, as written. The whole thing — 66 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Purpose
Detects field-name, type, and nullable/optional mismatches across the layers defining an API entity: the ORM schema (apps/<mainApp>/src/lib/db/schema.ts), the Zod schema, the route handler's JSON response, and the SQL migrations in the infrastructure repo. Examples use Drizzle and Flyway-style migrations — adapt to the project's stack (project.json -> stack.db). Read-only: fixes go to @implementation-agent or a developer.
Rules (never violate)
- Read-only skill (Read, Grep, Glob) — never auto-fix a mismatch; refuse if asked.
- Every finding cites
file:lineand carries a severity; findings below 80% confidence are marked[LOW-CONFIDENCE]. - The report contains zero placeholder text and ends with
CONTRACT-ISSUES: {entity} | CRITICAL: {n} | HIGH: {n} | MEDIUM: {n} | LOW: {n}. - A field name that differs between layers is this skill's job; a naming convention preference belongs to
code-standards. - Do not flag Zod
.optional()vs ORM.default(), migration-tool bookkeeping tables, or vendored/generated files; wire-protocol fields keep UPPER_SNAKE_CASE. - Stop and ask on an ORM type with no Zod equivalent, or >10 Critical findings in one entity.
Resources
- Read
resources/verification-procedure.mdwhen running a check — the 7-step procedure, output template, severity criteria, self-check, escalation, and failure modes. - Read
resources/worked-example-device.mdwhen you need a full end-to-end example with real code across all four layers.
How to use
What it does
Checks that one API entity means the same thing in every layer: it reads the ORM table, the Zod schema, the route handler's JSON response, and the SQL migration, then compares them field by field and reports every mismatch with a file:line citation, a severity, and a suggested fix. It never edits code.
When to use it
- You added, renamed, or retyped an ORM column and want to know what drifted.
- You changed a route handler's response shape or wrote a new Zod schema.
- A SQL migration landed and the ORM table definition needs verification.
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 3mo ago First seen · 66 lines · 49 tokens per session scan A b5e57b9e5e09
api-contract is a skill published in the GitHub repository atretyak1985/swarmery (9 stars, last pushed today), licensed Apache-2.0. It adds 49 tokens to every session and 855 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-09-03.
api-contract compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| api-contractatretyak1985/swarmery | Skill | 9 | today | Apache-2.0 | A | 49 | Claude Code |
| azure-postgres-tsmicrosoft/skills | Skill | 3.3k | today | MIT | A | 94 | Claude Code |
| k2cloudflare/skills | Skill | 3.6k | 2d ago | Apache-2.0 | A | 38 | Claude Code |
| database-patternsyonatangross/orchestkit | Skill | 315 | today | MIT | A | 32 | Claude Code |
| clickhouse-js-node-codingClickHouse/agent-skills | Skill | 582 | 10d ago | Apache-2.0 | A | 89 | Claude Code |
| drizzle-orm-d1secondsky/claude-skills | Skill | 257 | 4d ago | MIT | A | 76 | Claude Code |
| cloudflare-hyperdrivesecondsky/claude-skills | Skill | 257 | 4d ago | MIT | A | 45 | Claude Code |