docs_generate_openapi
Generate an OpenAPI 3.x specification directly from source code, routes, or endpoint definitions. Simplifies documenting APIs by converting existing code into a structured spec.
Instructions
Generate an OpenAPI 3.x specification from source code, routes, or endpoint definitions
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"source_code": "<source_code>"
},
"name": "docs_generate_openapi"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | API title for the spec | |
| api_key | No | API key for authentication | |
| version | No | API version string | |
| source_code | Yes | Source code or route definitions to generate OpenAPI spec from |