docs_generate_openapi
Analyze PHP project routes and automatically generate OpenAPI 3.0 specification with middleware, parameters, and security schemes. Converts controller routes into API documentation.
Instructions
Generate OpenAPI 3.0 specification from analyzed PHP routes with middleware, parameters, and security schemes. Automatically converts controller routes to API documentation.
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": {
"projectPath": "<projectPath>"
},
"name": "docs_generate_openapi"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | API title (default: 'API Documentation') | |
| format | No | Output format | json |
| version | No | API version (default: '1.0.0') | |
| serverUrl | No | API server URL (e.g., 'https://api.example.com') | |
| outputPath | No | Output path for OpenAPI spec file (default: ./openapi.json) | |
| projectPath | Yes | Path to the PHP project directory to analyze |