TypeScript types of an endpoint
api_typesGenerate TypeScript types for request, response, and parameters of any OpenAPI endpoint. Paste them directly into your project.
Instructions
Ready-to-paste TypeScript types for the request, response and parameters of an endpoint, generated from the spec with @hey-api/openapi-ts.
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": {
"endpoint": "<endpoint>"
},
"name": "api_types"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| include | No | ||
| endpoint | Yes | "METHOD /path", a path with a single operation, or a unique operationId | |
| name_prefix | No | Prefix for generated type names |