api-doc-generation
БесплатноБез исполняемых скриптовНе проверенGenerate and update API documentation from NestJS controllers. Use when modifying controllers, adding endpoints, or when the user asks about API documentation.
от diegosouzapw★ 68 звёзд на GitHubОб этом скилле
API Documentation Generation Skill
Purpose: Generate and update API documentation from NestJS controllers. Keeps API docs in sync with implementation.
Trigger
When: Controller files (*.controller.ts) are modified
Context Needed: Controller code, DTOs, existing API docs
MCP Tools: grep_search, read_file, mcp_payment-syste_query_docs_by_type
Controller → Doc Mapping
Parse NestJS decorators to extract:
@Controller('products') // Base path: /api/v1/products
@Get(':id') // GET /api/v1/products/:id
@Post() // POST /api/v1/products
@UseGuards(JwtAuthGuard) // Auth required
@ApiOperation({ summary: '...'}) // Description
Extraction Rules
| Decorator | Extracted Info |
|---|---|
@Controller(path) |
Base path |
@Get/@Post/@Put/@Delete |
HTTP method |
@Param/@Query/@Body |
Parameters |
@UseGuards |
Authentication |
@ApiOperation |
Description |
@ApiResponse |
Response codes |
API Doc Format
### GET /api/v1/products/:id
**Description:** Get product by ID
**Authentication:** Required (JWT)
**Parameters:**
| Name | In | Type | Required | Description |
| :--- | :--- | :----- | :------- | :---------- |
| id | path | string | Yes | Product ID |
**Responses:**
| Code | Description | Schema |
| :--- | :---------- | :----------------- |
| 200 | Success | ProductResponseDto |
| 404 | Not found | ErrorDto |
**Example Request:**
```bash
curl -X GET /api/v1/products/abc123 \
-H "Authorization: Bearer {token}"
```
## Frontmatter Template
```yaml
---
document_type: "api-design"
module: "[module]"
status: "approved"
version: "1.0.0"
last_updated: "YYYY-MM-DD"
author: "@Backend"
keywords:
- "api"
- "rest"
- "[module]"
api_metadata:
base_path: "/api/v1/[resource]"
auth_required: true
rate_limited: true
---
Workflow
- Detect changes - Which controllers changed?
- Parse decorators - Extract API metadata
- Load DTOs - Get request/response types
- Find existing doc - Match by module
- Update endpoints - Add/modify/remove
- Bump version - If endpoints changed
- Update date - Set last_updated
DTO Extraction
// From DTO class
export class CreateProductDto {
@IsString()
@MinLength(1)
name: string;
@IsOptional()
@IsNumber()
price?: number;
}
// Generate table
| Field | Type | Required | Validation |
| name | string | Yes | MinLength(1) |
| price | number | No | - |
Reference
Установить api-doc-generation в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл api-doc-generation?
Generate and update API documentation from NestJS controllers. Use when modifying controllers, adding endpoints, or when the user asks about API documentation.
Как установить скилл api-doc-generation?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл api-doc-generation запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic