Vercel · Schema
Vercel AI Gateway Chat Completion Request
Schema for a chat completion request to the Vercel AI Gateway (OpenAI-compatible format).
AI GatewaysGatewaysObservabilityWebhook
Properties
| Name | Type | Description |
|---|---|---|
| model | string | Model identifier in provider/model-name format (e.g., 'anthropic/claude-opus-4.6') |
| messages | array | Conversation messages |
| stream | boolean | Whether to stream the response via SSE |
| temperature | number | Sampling temperature |
| max_tokens | integer | Maximum tokens to generate |
| providerOptions | object | Gateway provider routing options |
| provider | object | Provider shorthand options |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://raw.githubusercontent.com/api-evangelist/vercel/main/json-schema/vercel-chat-completion-schema.json",
"title": "Vercel AI Gateway Chat Completion Request",
"description": "Schema for a chat completion request to the Vercel AI Gateway (OpenAI-compatible format).",
"type": "object",
"required": ["model", "messages"],
"properties": {
"model": {
"type": "string",
"description": "Model identifier in provider/model-name format (e.g., 'anthropic/claude-opus-4.6')",
"examples": ["anthropic/claude-opus-4.6", "openai/gpt-4o", "google/gemini-2.0-flash"]
},
"messages": {
"type": "array",
"description": "Conversation messages",
"items": {
"type": "object",
"required": ["role", "content"],
"properties": {
"role": {
"type": "string",
"enum": ["system", "user", "assistant", "tool"],
"description": "Message role"
},
"content": {
"oneOf": [
{ "type": "string" },
{
"type": "array",
"items": {
"type": "object",
"properties": {
"type": { "type": "string", "enum": ["text", "image_url"] },
"text": { "type": "string" },
"image_url": {
"type": "object",
"properties": {
"url": { "type": "string" },
"detail": { "type": "string", "enum": ["auto", "low", "high"] }
}
}
}
}
}
]
}
}
}
},
"stream": {
"type": "boolean",
"default": false,
"description": "Whether to stream the response via SSE"
},
"temperature": {
"type": "number",
"minimum": 0,
"maximum": 2,
"description": "Sampling temperature"
},
"max_tokens": {
"type": "integer",
"description": "Maximum tokens to generate"
},
"providerOptions": {
"type": "object",
"description": "Gateway provider routing options",
"properties": {
"gateway": {
"type": "object",
"properties": {
"order": {
"type": "array",
"items": { "type": "string" },
"description": "Ordered provider fallback chain"
},
"sort": {
"type": "string",
"enum": ["cost", "ttft", "tps"]
}
}
}
}
},
"provider": {
"type": "object",
"description": "Provider shorthand options",
"properties": {
"sort": {
"type": "string",
"enum": ["cost", "ttft", "tps"],
"description": "Sort providers by cost, time-to-first-token, or tokens-per-second"
}
}
}
}
}
Work with this as data
Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.
MCP server
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
Tools for schemas
4 MCP tools reach this
find_json_schemasBrowse and filter every JSON Schema in the catalog.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.
Call it yourself
curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/vercel-chat-completion"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
Get an API key
Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.