api

api is a skill for Codex from kreek/consult. It costs 26 tokens per session (1,255 once invoked), scanned A, original, MIT.

Guidance for designing REST API contracts: the agreed URLs, request and response fields, status codes, errors, and rules for change. A REST API is an interface that lets software communicate over web requests.

In plain words
What is it for?
Use it when adding or reviewing endpoints, fields, webhooks, authentication, pagination, rate limits, idempotency, OpenAPI, or JSON Schema.
Why use it?
It helps prevent clients from breaking when an API changes. It also makes empty results, errors, pagination, authentication failures, and repeated requests predictable.

Skill for Codex

Written for Codex: agents/openai.yaml present. Also seen: installed under .agents/ (shared by several agents).

Good fit Use it when adding or reviewing endpoints, fields, webhooks, authentication, pagination, rate limits, idempotency, OpenAPI, or JSON Schema.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/kreek/consult/api
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 kreek/consult --skill api
Clone the repo
git clone --depth 1 https://github.com/kreek/consult

Made for: 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

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

Your own site · 80×15
<a href="https://agentmods.dev/skills/kreek/consult/api"><img src="https://agentmods.dev/badge/skills/kreek/consult/api.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,255 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.00026 $0.01255
Opus 5.5 $0.00010 $0.00502
Sonnet 5.5 $0.00005 $0.00251
Haiku 4.5 $0.00003 $0.00126

Measured 16d ago against content hash 924afdf3bec5, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

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 16d 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.

agents/.agents/skills/api/SKILL.md · 104 lines

How it starts

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

API

Iron Law

DEFINE THE CONTRACT FIRST. PRESERVE SHIPPED CALLERS. PICK STATUS BY FAILURE.

When to Use

  • Adding, removing, renaming, or reviewing REST endpoints, fields, status codes, webhooks, auth, pagination, rate limits, or idempotency.
  • Writing or changing OpenAPI, JSON Schema, public SDK boundaries, or integration contracts external callers depend on.

When NOT to Use

  • Internal function signatures with no caller contract; use domain-modeling.
  • Auth, secrets, or trust-boundary review beyond API shape; use security.
  • Database schema; use database.
  • gRPC, GraphQL, or message-queue APIs: use architecture for the style decision and that ecosystem's conventions for shape.

Rules

  1. Sketch new or changed caller-visible behavior in OpenAPI or the repo's contract source before controller code, then implement from it. For a fix that restores existing behavior, use the current contract as the source of truth. Make every response shape explicit, including errors, empty states, pagination, and auth failures. Durable API interfaces route through contract-first. Additive changes old callers cannot notice (a new optional field, param, or endpoint) proceed without a stop; state the shape in the close-out.
  2. Preserve shipped contracts with independent callers. Optional fields, params, headers, methods, and endpoints evolve in place when old callers can ignore them. When they alter a shipped contract, renames, removals, required additions, status-code changes, and semantic changes need a successor contract or a deprecation path with an overlap window. An explicitly unstable contract, or one whose change no running caller can observe, may change in place. Open browser tabs and installed apps are independent running callers. Use one versioning strategy per service; compatible additions never re-version.
  3. Use 4xx for caller-side conditions such as invalid input, missing resources, authorization, or rate limits; use 5xx when this service or a dependency cannot fulfill a valid request. Never mix origins in one response or leak raw upstream or internal errors.
  4. Preserve an existing service's representation and error contract. For a new REST resource API with no established format, default to JSON:API unless a domain standard or client interoperability need favors another documented choice. New APIs use the chosen model's native error shape; document deviations.
  5. Non-idempotent mutations define idempotency key scope, replay window, duplicate response, and conflict semantics, or are documented as unsafe to retry.
  6. Lists have bounded pagination, stable ordering, and explicit invalid-token behavior. A bad token never silently restarts, rewinds, or skips position.
  7. External webhooks are signed, timestamped, replay-protected, versioned, and deduplicable.
  8. Middleware is for transport-wide concerns (logging, tracing, rate limits). Endpoint-specific validation, ownership checks, privileged authorization, and domain invariants stay at the route or domain boundary.
  9. Tests exercise the public boundary. Source-of-truth docs are updated, not generated output by hand.

Read the full file on GitHub · 104 lines

Files

What ships with it

8 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.

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. 16d ago Changed · +1 tokens per session 924afdf3bec5
  2. 23d ago Changed · +8 lines f116de92b9f9
  3. 1mo ago Changed · -58 lines b7041d4a1baa
  4. 1mo ago First seen · 154 lines · 25 tokens per session scan A 35cf670c8610

Subscribe to this mod's changes

api is a skill published in the GitHub repository kreek/consult (1 stars, last pushed 17d ago), licensed MIT. It adds 26 tokens to every session and 1,255 once invoked, about $0.0001 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-31.

Related

Other skills, from other repositories

contracts

Team baseline for external-interface contract artifacts: OpenAPI, JSON Schema, AsyncAPI, .proto, and GraphQL SDL, with spectral, ajv, buf, and graphql-inspector validation. Nudges devs toward contract-first artifacts; never writes them and never scaffolds a contracts/ directory. Auto-triggers for what contract should…

ramboz/jig · 163 tokens

build-falco-web-app

Build or modify a Falco web application in idiomatic F#, using functional routing, request and response helpers, explicit ASP.NET Core integration, security boundaries, and focused tests.

gaelic-ghost/socket · 42 tokens

build-giraffe-web-app

Build or modify a Giraffe web application in idiomatic F#, using composable HttpHandler functions, explicit ASP.NET Core integration, configuration, authentication, and focused endpoint tests.

gaelic-ghost/socket · 43 tokens

build-oxpecker-web-app

Build or modify an Oxpecker web application in idiomatic F#, using endpoint routing, functional EndpointHandler and EndpointMiddleware composition, ASP.NET Core metadata, and focused endpoint tests.

gaelic-ghost/socket · 44 tokens

swift-openapi-client-workflow

Build, integrate, test, and diagnose Swift OpenAPI Generator clients in Apple-platform apps and Swift packages using OpenAPIURLSession, OpenAPIRuntime, URLSessionTransport, SwiftPM plugins, Apple docs, Dash docsets, and clear handoffs to server-side Swift OpenAPI workflows when the API contract or server transport…

gaelic-ghost/socket · 73 tokens

build-acp-agent

Design, implement, test, and package an ACP agent/server. Use for protocol negotiation, sessions, streaming updates, tool rendering, permissions, authentication, SDK choice, and registry submission.

gaelic-ghost/socket · 42 tokens