scaffold

scaffold is a command for Claude Code from iwritec0de/app-dev. It costs 12 tokens per session (691 once invoked), scanned A, original, MIT.

A command that creates API route handlers from an API description or specification. API routes are the parts of an application that receive web requests, validate them, and return responses.

In plain words
What is it for?
Use it to scaffold endpoints for resources such as users, posts, or orders, choosing the HTTP methods and whether authentication is required.
Why use it?
It reduces the repeated work of setting up endpoints, request validation, data types, and optional login checks.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Part of the app-dev plugin — 17 skills, 11 commands, 4 agents, 3 hooks shipped together

Good fit Use it to scaffold endpoints for resources such as users, posts, or orders, choosing the HTTP methods and whether authentication is required.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/iwritec0de/app-dev/scaffold
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.

Clone the repo
git clone --depth 1 https://github.com/iwritec0de/app-dev

Made for: Claude Code.

Or install app-dev, the plugin that ships this one along with the rest of its 17 skills, 11 commands, 4 agents, 3 hooks.

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 scaffold

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

Your own site · 80×15
<a href="https://agentmods.dev/commands/iwritec0de/app-dev/scaffold"><img src="https://agentmods.dev/badge/commands/iwritec0de/app-dev/scaffold.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 12 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 691 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.00012 $0.00691
Opus 5.5 $0.00005 $0.00276
Sonnet 5.5 $0.00002 $0.00138
Haiku 4.5 $0.00001 $0.00069

Measured 1mo ago against content hash 3ade4dbfa80e, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

scaffold 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 1mo 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.

commands/scaffold.md · 87 lines

How it starts

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

API Scaffold

Generate route handlers, validation, and types for API endpoints.

Load the nextjs-typescript-engineer and api-design skills for conventions and API patterns.

Usage

/scaffold <resource> [--methods GET,POST,PUT,DELETE] [--auth]

Arguments

Parse $ARGUMENTS to extract:

  • resource (required) — Resource name (e.g., users, posts, orders)
  • --methods (optional, default: GET,POST,PUT,DELETE) — HTTP methods to generate
  • --auth — Add authentication middleware/guards to all endpoints

Instructions

1. Detect Framework

Search the project for:

grep -l "express\|fastify\|koa\|hono" package.json 2>/dev/null       # Node.js
ls app/api/ 2>/dev/null                                                # Next.js App Router
ls pages/api/ 2>/dev/null                                              # Next.js Pages Router
grep -l "flask\|fastapi\|django" requirements.txt 2>/dev/null          # Python
grep -l "gin\|echo\|fiber\|chi" go.mod 2>/dev/null                     # Go
grep -l "laravel\|slim" composer.json 2>/dev/null                      # PHP

2. Detect Existing Patterns

Read 1-2 existing route files to understand:

  • File organization (routes/, controllers/, handlers/)
  • Naming conventions
  • Error handling pattern
  • Validation approach (zod, joi, class-validator, etc.)
  • Response format (envelope pattern, direct, etc.)
  • Database layer (ORM, raw SQL, repository pattern)

3. Generate Route Handlers

For each method, generate appropriate handlers following the project's existing patterns.

Standard REST endpoints:

Method Route Handler Description
GET /<resource> list List all with pagination
GET /<resource>/:id get Get single by ID
POST /<resource> create Create new
PUT /<resource>/:id update Update existing
DELETE /<resource>/:id delete Delete by ID

Each handler should include:

  • Input validation (request body, query params, path params)
  • Error handling (404, 400, 500)
  • Response typing
  • Authentication check (if --auth)

Read the full file on GitHub · 87 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. 1mo ago First seen · 87 lines · 12 tokens per session scan A 3ade4dbfa80e

Subscribe to this mod's changes

scaffold is a command published in the GitHub repository iwritec0de/app-dev (3 stars, last pushed 6mo ago), licensed MIT. It adds 12 tokens to every session and 691 once invoked, about $0.0000 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.