api-conventions

api-conventions is a skill for Claude Code, Codex from willdady/platypus. It costs 60 tokens per session (1,082 once invoked), scanned A, original, MIT.

A set of rules for choosing consistent response fields and error handling in the Platypus backend API. It explains when an operation should return an error response and when it should throw a typed error.

In plain words
What is it for?
Use it when adding or changing backend routes, API responses, or related tests.
Why use it?
It prevents success and failure responses from using inconsistent formats. Shared error handling also keeps the same business rule consistent across API routes and agent tools.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

Good fit Use it when adding or changing backend routes, API responses, or related tests.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/willdady/platypus/api-conventions
Install

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.

Any agent
npx skills add willdady/platypus --skill api-conventions
Clone the repo
git clone --depth 1 https://github.com/willdady/platypus

Made for: Claude Code, Codex.

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 api-conventions

README.md
[![agentmods](https://agentmods.dev/badge/skills/willdady/platypus/api-conventions/github.svg)](https://agentmods.dev/skills/willdady/platypus/api-conventions)
Your own site
<a href="https://agentmods.dev/skills/willdady/platypus/api-conventions"><img src="https://agentmods.dev/badge/skills/willdady/platypus/api-conventions/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 api-conventions

Your own site · 80×15
<a href="https://agentmods.dev/skills/willdady/platypus/api-conventions"><img src="https://agentmods.dev/badge/skills/willdady/platypus/api-conventions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 60 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,082 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. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
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.00060 $0.01082
Opus 5.5 $0.00024 $0.00433
Sonnet 5.5 $0.00012 $0.00216
Haiku 4.5 $0.00006 $0.00108

Measured yesterday against content hash 7f312875571a, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

api-conventions 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 yesterday.

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.

.agents/skills/api-conventions/SKILL.md · 119 lines

How it starts

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

API Response Conventions

The two keys

error carries a failure. message carries a 2xx status line for an operation that has no resource to return.

return c.json({ error: "Workspace not found" }, 404);
return c.json({ message: "Board deleted" });

Never message on a 4xx/5xx — that is the one crossing the codebase does not make.

A delete or action with nothing to return answers 200 { message } — never a bodiless 204, and never { success: true }.

A failure body is { error } and nothing else: no success, no detail fields beside it. Three exceptions, each because a frontend client reads the extra shape:

Failure Body Why
Request validation 400 { error: Issue[] } the form maps each issue's path onto its field
Agent promote, blocked 422 { error, blockers } the promote dialog lists what to make Shared first
FileValidationError 400 { error, files } the write client parses the offending files

Validating a request

Validate with validate(target, schema) from src/validate.ts, never with sValidator directly — its default failure body adds success and echoes the submitted body back as data.

kanban.post(
  "/",
  requireAuth,
  requireOrgAccess(),
  requireWorkspaceAccess,
  validate("json", kanbanBoardCreateSchema),
  async (c) => {
    const data = c.req.valid("json");

Choosing the verb

PATCH applies a partial update: only the fields sent change. PUT replaces the resource whole. A resource has one address and one write verb per operation — never both PUT and PATCH for the same update.

Checking a response

A route whose response has an exported response schema sends it through respond(c, schema, value) from src/respond.ts instead of c.json. Under test it parses the value against the schema, so a dropped field fails the route's test rather than the frontend; production sends the value untouched. Adoption is partial: the Provider, MCP and Artifact routes are the reference, and many older routes still c.json a value that has a schema.

Read the full file on GitHub · 119 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. yesterday Changed · +11 lines 7f312875571a
  2. 1mo ago Changed · +13 lines 42b9c239ceae
  3. 1mo ago Changed · +2 lines 799f18c84e77
  4. 1mo ago Changed · +20 lines 5a77bb23d24b
  5. 2mo ago Changed · +7 lines 8a959ec75d69
  6. 2mo ago Changed · +2 lines 9c11eb1b3c5a
  7. 2mo ago Changed · +1 lines 5427c8e34d9f
  8. 3mo ago First seen · 63 lines · 60 tokens per session scan A f9e129ea7b5e

Subscribe to this mod's changes

api-conventions is a skill published in the GitHub repository willdady/platypus (133 stars, last pushed today), licensed MIT. It adds 60 tokens to every session and 1,082 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-01.

Related

api-conventions compared with skills from other repositories

api-conventions next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
api-conventionswilldady/platypusSkill133todayMITA60Claude Code, Codex
add-dial-toolnanocoai/nanoclawSkill31ktodayMITA118Claude Code
add-gchatnanocoai/nanoclawSkill31ktodayMITA13Claude Code
add-signalnanocoai/nanoclawSkill31ktodayMITA22Claude Code
add-matrixnanocoai/nanoclawSkill31ktodayMITA19Claude Code
add-slacknanocoai/nanoclawSkill31ktodayMITB12Claude Code
n8n-docs-assistantn8n-io/n8nSkill213ktodaynoneA71Claude Code, Codex