OpenParable
Skip to content
← Back to skills

Documenting APIS

Documents
documenting-apis

Documenting APIS is an Agent Skill for documents published in the majiayu000/claude-skill-registry repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Generate API specification documentation from codebase analysis. Detects REST endpoints, function signatures, type definitions, and schemas. Triggers: API specification, endpoints, REST API, type definitions, OpenAPI, Swagger, API documentation.

View on GitHub ↗
QUICK START

How to use this skill

Bring this guide into your coding agent with a prompt tailored to the tool you use.

  1. Open your project in Codex.
  2. Copy and paste the prompt below.
  3. Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/majiayu000/claude-skill-registry/blob/HEAD/skills/documents/documenting-apis-thkt-claude-config/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/documenting-apis, but wait for my approval before writing files or running scripts.

Copying this prompt does not install or run the skill. Review third-party files before use.

docs:api - API Specification Generation

Auto-generate API documentation from codebase analysis.

Detection Items

CategoryTargets
REST EndpointsExpress, Fastify, Hono, Next.js, Flask, FastAPI, Django REST
Functionstree-sitter extraction, TypeScript types, JSDoc, docstrings
Typesinterface, type, Zod, Yup, dataclass, Pydantic
OpenAPIopenapi.yaml/json, swagger.yaml/json

Framework Detection Patterns

FrameworkPattern
Express/Fastify/Honoapp.get(), router.post()
Next.jsapp/api/**/route.ts, pages/api/**/*.ts
Flask@app.route()
FastAPI@app.get(), @app.post()
Django REST@api_view

Analysis Scripts

ScriptPurpose
scripts/detect-endpoints.shHTTP method, path, handler, file location
scripts/extract-types.shType name, fields, related types

Generated Structure

# API Specification

## Endpoint List
### GET /api/users
**Request**: params table
**Response**: JSON example

## Type Definitions
### User
| Field | Type | Description |

Usage

/docs:api                    # Generate API docs
"Generate API specification" # Natural language

Markdown Validation

After generation, validate output with:

~/.claude/skills/scripts/validate-markdown.sh {output-file}

Non-blocking (warnings only) - style issues don't block document creation.

References

  • Related: documenting-architecture, setting-up-docs, documenting-domains