rest-api

rest-api is a skill for Claude Code from Dynokostya/just-works. It costs 69 tokens per session (3,792 once invoked), scanned A, original, Apache-2.0.

A set of framework-independent instructions for designing REST APIs. A REST API is a web interface where clients use HTTP requests to work with named resources such as users or orders.

In plain words
What is it for?
Use it when designing or implementing API routes, controllers, resource responses, versioning, uploads, health checks, or caching.
Why use it?
It helps keep routes, status codes, errors, pagination, authentication, and other API behavior consistent and easier for clients to use.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

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.

agentmods
npx agentmods add skills/dynokostya/just-works/rest-api
Any agent
npx skills add Dynokostya/just-works --skill rest-api
Clone the repo
git clone --depth 1 https://github.com/Dynokostya/just-works

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/dynokostya/just-works/rest-api.svg)](https://agentmods.dev/skills/dynokostya/just-works/rest-api)
Your own site
<a href="https://agentmods.dev/skills/dynokostya/just-works/rest-api"><img src="https://agentmods.dev/badge/skills/dynokostya/just-works/rest-api.svg" alt="Measured on agentmods" height="20"></a>
Per session 69 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,792 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00069 $0.03792
Opus 5 $0.00034 $0.01896
Sonnet 5 $0.00014 $0.00758
Haiku 4.5 $0.00007 $0.00379

Measured yesterday against content hash caedc6a981e2, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

rest-api 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.

.claude/skills/rest-api/SKILL.md · 261 lines

How it starts

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

REST API Design

Match the project's existing API conventions. When uncertain, read 2-3 existing endpoints to infer the local style. Check for OpenAPI specs, existing error response formats, and authentication patterns. These defaults apply only when the project has no established convention.

Generic HTTP reference — the methods/status-code table, versioning strategies, auth mechanisms, caching headers, async patterns, and file uploads — lives in references/http-reference.md. Load it when needed.

Never rules

These are unconditional. They prevent security vulnerabilities, broken contracts, and common API design mistakes regardless of project style.

  • Never use singular nouns for collection endpoints. Use /users, not /user. Mixing singular and plural creates ambiguity — clients have to guess whether the endpoint is /user/123 or /users/123. A consistent plural convention means the same base path serves both the collection (GET /users) and individual resources (GET /users/123).
  • Never nest resources deeper than 3 levels. /customers/123/orders/456/items is the limit. Deeper nesting increases coupling and URL complexity. If the child has a globally unique ID, expose it as a top-level resource.
  • Never use verbs in URL paths for CRUD operations. POST /users/123/delete duplicates what HTTP methods already express and makes the API unpredictable — clients can't know whether to use POST /users/delete or DELETE /users. Use DELETE /users/123. Verbs are acceptable only for non-CRUD actions as sub-resource endpoints (POST /charges/ch_123/capture) or colon syntax (POST /instances/my-vm:start).
  • Never return only the first validation error. Return all validation errors at once with field paths. Returning one at a time forces clients into frustrating fix-one-discover-another cycles.
  • Never use offset pagination on datasets exceeding 10K rows. Performance degrades linearly with offset depth — the database scans and discards every skipped row, so deep pages get drastically slower. Use cursor-based pagination.
  • Never omit Retry-After on 429 responses. Rate limit responses without Retry-After force clients to guess retry timing, causing thundering herds or aggressive polling.
  • Never verify webhook signatures against re-serialized JSON. Re-serialization changes key order or whitespace, invalidating the signature. Always verify against the raw request body bytes.
  • Never expose sequential integer IDs for resources accessible across trust boundaries. Sequential IDs enable enumeration attacks (BOLA/IDOR). Use UUIDs or other unpredictable identifiers for user-facing resources.
  • Never bind raw client input directly to internal models. This enables mass assignment — attackers adding is_admin: true to request bodies. Use explicit allowlists of writable fields via DTOs or schemas.
  • Never trust user-supplied resource IDs without server-side ownership verification. BOLA (Broken Object Level Authorization) is the #1 API vulnerability. Every endpoint receiving an object ID must verify the caller owns or has access to that resource.
  • Never use wildcard * for CORS Access-Control-Allow-Origin with credentials. Browsers reject Access-Control-Allow-Credentials: true with wildcard origin. Validate the Origin header against an allowlist and reflect the specific origin.
  • Never expose internal error details in production responses. Stack traces, SQL queries, file paths, and dependency versions give attackers a detailed map of your internals — database schema, framework versions with known CVEs, and directory structure for path traversal. Return generic messages externally; log details internally.
  • Never deploy an API without health check endpoints. Without health probes, orchestrators (Kubernetes, AWS ELB) can't distinguish a crashed pod from a healthy one — traffic routes to dead instances, and there's no automated recovery. A simple /livez returning 200 takes minutes to add and prevents hours of debugging silent outages.
  • Never support TLS versions below 1.2. TLS 1.0 and 1.1 have known vulnerabilities (BEAST, POODLE) and are deprecated by all major cloud providers and PCI DSS. Require TLS 1.2 minimum, prefer 1.3.
  • Never omit security headers from API responses. Missing Strict-Transport-Security allows SSL-stripping attacks on first visit. Missing X-Content-Type-Options: nosniff lets browsers reinterpret response content types, enabling XSS. Missing Cache-Control: no-store on authenticated endpoints means sensitive data persists in browser and proxy caches.

Read the full file on GitHub · 261 lines

Files

What ships with it

1 file 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.

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 First seen · 261 lines · 69 tokens per session scan A caedc6a981e2

Subscribe to this mod's changes

rest-api is a skill published in the GitHub repository Dynokostya/just-works (14 stars, last pushed yesterday), licensed Apache-2.0. It adds 69 tokens to every session and 3,792 once invoked, about $0.0003 per session on Opus 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-04.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens