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.
git clone --depth 1 https://github.com/coddy-project/coddy-agentWrote 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/rules/coddy-project/coddy-agent/api-layer)<a href="https://agentmods.dev/rules/coddy-project/coddy-agent/api-layer"><img src="https://agentmods.dev/badge/rules/coddy-project/coddy-agent/api-layer/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/rules/coddy-project/coddy-agent/api-layer"><img src="https://agentmods.dev/badge/rules/coddy-project/coddy-agent/api-layer.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.00000 | $0.00813 |
| Opus 5.5 | $0.00000 | $0.00325 |
| Sonnet 5.5 | $0.00000 | $0.00163 |
| Haiku 4.5 | $0.00000 | $0.00081 |
Grade A, and why
api-layer 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 9d 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 — 21 lines — stays where its author put it; the contents beside it link to each section on GitHub.
HTTP API layer (external/httpserver)
- Built with
-tags http. SPA root/(go:embedfromexternal/ui) links only when you addtags=uiwithgo build -tags=http,ui(seemountEmbeddedSPARootsplits inspa_embed_ui.go/spa_no_ui.go). Handlers are registered inServer.Newinserver.go. openapi.gobuilds the served OpenAPI 3 document (openAPISpec). It is the programmatic spec; it must describe the same paths, methods, parameters, schemas, and response shapes as the live handlers.- After any change to routes or externally visible request or response behavior, update
openAPISpecand extendserver_test.go(or add tests) under the **httpbuild tag. - User-facing narrative lives in
docs/reference/http-api.md; keep it aligned when endpoints or semantics change. - Which workspace a request describes.
resolveSessionCWD(slash_commands.go) answers with the session inX-Coddy-Session-ID(a persisted one loaded on demand;400malformed,404unknown) or the server default cwd. The read-only listings the composer asks for while the user types -/coddy/slash-commands,GET /coddy/skills,/coddy/mentions,POST /coddy/mentions/check,/coddy/workspace/file- go throughresolveListingCWDinstead, which adds thecwdquery: the folder a new chat picked before its session exists, an absolute existing directory or400, used when the header is absent or names a session the server does not have yet, ignored next to one it has. A new listing of that kind usesresolveListingCWDand addslistingCWDParam()inopenapi.go.DELETE /coddy/skills/{name}resolves the same way, because a skill is deleted from the listGET /coddy/skillsshowed for that workspace:DeleteSkillremoves only a path inside a configured skills directory of it (a link into the directory is removed as the link, never what it points at), which is the reach a client already has by anchoring a session on the folder, and it approves or runs nothing. Routes that change a workspace (the MCP routes throughmcpWorkspace, trust and untrust,POST /coddy/workspace/folders) stay onresolveSessionCWDand never takecwd: an arbitrary folder must not get a declaration written or approved without a session in it. Held byTestListingCWDQueryEdgesandfeatures/skills_session_workspace.feature.GET /coddy/workspace/contextandPOST /coddy/workspace/fetchtake apathquery of their own instead (the new chat's preview and the refresh of its branch list, throughworkspaceContextCWD): the fetch moves only git's remote-tracking refs of that folder throughgitws.FetchRemotes, writes no declaration and approves nothing.
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.
- 9d ago Changed 964b45d41b59
- 13d ago Changed · +1 lines 82fddbd34c6e
- 1mo ago Changed 1ea1975523fd
- 1mo ago First seen · 20 lines · 0 tokens per session scan A c58064876cba
api-layer is a cursor rule published in the GitHub repository coddy-project/coddy-agent (176 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 813 tokens. 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.
Other cursor rules, from other repositories
proxy-auth-transport
Every CLI command or browser UI action that calls a crit-web API must work in both modes.
go-api-handlers
Use authorization functions for apps.
use-frontend-api-client
Generated API client usage.
mcp-server
MCP (Model Context Protocol) server architecture and implementation.
ponytail
Ponytail, lazy senior dev mode. Always pick the simplest solution that works.
angular-20
This rule provides comprehensive best practices and coding standards for Angular development, focusing on modern TypeScript, standalone components, signals, and performance optimizations.