API Reference
Exact public endpoints, request contracts, and response behavior for the model gateway.
All inference APIs use the gateway Base URL configured for this deployment: http://127.0.0.1:11113
The gateway normalizes authentication, public model IDs, routing, billing, and request tracing while preserving the response dialect of the endpoint you call.
Use public model IDs
Send the complete model ID shown on the Models page, for example
openai/gpt-5.2. Internal providers and upstream model IDs are never part of
the public contract.
Start with a protocol
OpenAI-compatible APIs
Chat Completions, Responses, embeddings, images, and model discovery.
Anthropic Messages
Use the Anthropic request, response, and streaming event shapes.
Gemini APIs
Generate Content, Interactions, image output, and long-running video tasks.
Video APIs
Native xAI, Gemini, and Seedance creation endpoints with platform task IDs.
Endpoint catalog
| Method | Path | Mode | Reference |
|---|---|---|---|
GET | /v1/models | Synchronous | List models |
POST | /v1/chat/completions | Synchronous or SSE | Chat Completions |
POST | /v1/responses | Synchronous or SSE | Responses |
POST | /v1/embeddings | Synchronous | Embeddings |
POST | /v1/images/generations | Synchronous or SSE | Image generation |
POST | /v1/images/edits | Synchronous or SSE | Image editing |
POST | /v1/messages | Synchronous or SSE | Anthropic Messages |
POST | /v1/models/{model}:generateContent | Synchronous | Gemini Generate Content |
POST | /v1beta/models/{model}:generateContent | Synchronous | Gemini Generate Content |
POST | /v1/models/{model}:streamGenerateContent | SSE | Gemini Generate Content |
POST | /v1beta/models/{model}:streamGenerateContent | SSE | Gemini Generate Content |
POST | /v1beta/interactions | Synchronous, SSE, or asynchronous video | Gemini Interactions |
POST | /v1/videos/generations | Asynchronous | xAI video |
POST | /v1/videos/edits | Asynchronous | xAI video |
POST | /v1/videos/extensions | Asynchronous | xAI video |
POST | /v1/models/{model}:predictLongRunning | Asynchronous | Gemini video |
POST | /v1beta/models/{model}:predictLongRunning | Asynchronous | Gemini video |
POST | /v1/contents/generations/tasks | Asynchronous | Seedance video |
GET | /v1/tasks/{taskId} | Task lookup | Tasks and callbacks |
GET | /v1/contents/generations/tasks/{taskId} | Seedance task lookup | Tasks and callbacks |
DELETE | /v1/contents/generations/tasks/{taskId} | Seedance cancel or delete | Tasks and callbacks |
/v1 and /v1beta Gemini model methods use the same gateway behavior. The version segment only matches client SDK conventions; it does not select a different gateway feature set.
Compatibility contract
When the incoming protocol matches an available upstream endpoint, the gateway uses a pass-through path: it rewrites the model ID, applies platform limits, and preserves protocol-specific and newly introduced fields. When protocols differ, the gateway converts the shared text, multimodal input, tool-calling, generation, streaming, and usage fields through a canonical representation.
Fields that have no safe cross-protocol equivalent are omitted and named in the x-dropped-params response header. Use the model's native public protocol when a provider-specific feature must be preserved exactly.
Platform-managed behavior
The platform selects providers, routes, failover candidates, and paid service tiers. Client-supplied provider, routing, or route fields are rejected. Model-call POST requests also reject Idempotency-Key; see Authentication and errors and Tasks and callbacks for safe retry rules.
Help us improve this page
Found something unclear, outdated, or incorrect?
Last updated on