{
"error": {
"message": "Insufficient balance. Please top up your wallet.",
"type": "insufficient_quota",
"code": "insufficient_balance"
}
}
{
"error": {
"message": "The model 'x' does not exist or is not available.",
"type": "invalid_request_error",
"code": "model_not_found"
}
}
Inference API
Create chat completion
Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (fallbacks) and, when the workspace has response caching enabled, serves identical repeat requests from cache at a discount (see the X-Errorbar-Cache response header).
Per-request cache control (only meaningful when the workspace has response caching enabled — it can reduce caching, never enable it). no-cache: skip the cache and force a fresh model run, refreshing the stored copy. no-store: fresh run AND keep this response out of cache storage entirely. Either way the response carries X-Errorbar-Cache: bypass.
Up to 2 backup model ids tried in order when the primary fails with a transient error (429/timeout/5xx). Billing uses the model that actually served; the X-Errorbar-Fallback-From response header names the model it fell back from. Gateway feature — never forwarded to the model.
Maximum array length: 2
Response
A chat completion. When streaming, a text/event-stream of chunks ending with data: [DONE].
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"errorbar","colors":{"primary":"#3f7d39","light":"#3bd495","dark":"#2f5e2a"},"logo":{"light":"https://mintcdn.com/omnia-9828cd09/dR-r1msnM4tGAtp4/logo/light.svg?fit=max\u0026auto=format\u0026n=dR-r1msnM4tGAtp4\u0026q=85\u0026s=0a8e72505cf8b9297d6df70ae03e61f1","dark":"https://mintcdn.com/omnia-9828cd09/dR-r1msnM4tGAtp4/logo/dark.svg?fit=max\u0026auto=format\u0026n=dR-r1msnM4tGAtp4\u0026q=85\u0026s=f68c0d824584773dfd066ad0a450f930"},"favicon":"https://mintcdn.com/omnia-9828cd09/dR-r1msnM4tGAtp4/favicon.svg?fit=max\u0026auto=format\u0026n=dR-r1msnM4tGAtp4\u0026q=85\u0026s=cb75d200c189cf8c0f5c83af1e8bb3b3","navbar":{"links":[{"href":"https://www.errorbar.ai/sign-up","label":"Sign up"}]},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"omnia-9828cd09","hasAudioNarration":false,"actualSubdomain":"omnia-9828cd09","customDomains":["docs.errorbar.ai"],"gitSource":{"type":"github","owner":"matiyas-h","repo":"omnia-docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"collectionId":"b1fec96f-b9e8-4f8d-8036-90b4f2784b52","liveDeploymentHistoryId":"6aa66951a2a95f72566e8b62","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6aa66951a2a95f72566e8b62"},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6aa66951a2a95f72566e8b62","clientVersion":"0.0.3965","searchFilterCounts":[{"language":"default","tag":"API Reference","count":99},{"language":"default","tag":"Documentation","count":53},{"language":"default","tag":"Judges (criteria) API","count":16},{"language":"default","tag":"Evals API","count":13},{"language":"default","tag":"Platform","count":12},{"language":"default","tag":"Run at scale","count":11},{"language":"default","tag":"Certified reward API","count":10},{"language":"default","tag":"Improve","count":9},{"language":"default","tag":"Reinforcement learning API","count":9},{"language":"default","tag":"Fine-tuning API","count":8}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/chat/create-chat-completion","slug":"/api-reference/chat/create-chat-completion","pageMetadata":{"title":"Create chat completion","description":"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (`fallbacks`) and, when the workspace has [response caching](/billing/caching) enabled, serves identical repeat requests from cache at a discount (see the `X-Errorbar-Cache` response header).","deprecated":null,"version":null,"openapi":"/openapi-inference.json post /chat/completions","href":"/api-reference/chat/create-chat-completion","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n a: \"a\",\n code: \"code\",\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_components.p, {\n children: [\"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (\", _jsx(_components.code, {\n children: \"fallbacks\"\n }), \") and, when the workspace has \", _jsx(_components.a, {\n href: \"/billing/caching\",\n children: \"response caching\"\n }), \" enabled, serves identical repeat requests from cache at a discount (see the \", _jsx(_components.code, {\n children: \"X-Errorbar-Cache\"\n }), \" response header).\"]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Create chat completion","description":"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (`fallbacks`) and, when the workspace has [response caching](/billing/caching) enabled, serves identical repeat requests from cache at a discount (see the `X-Errorbar-Cache` response header).","deprecated":null,"version":null,"openapi":"/openapi-inference.json post /chat/completions","href":"/api-reference/chat/create-chat-completion","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"tags":["Chat"],"summary":"Create chat completion","description":"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (`fallbacks`) and, when the workspace has [response caching](/billing/caching) enabled, serves identical repeat requests from cache at a discount (see the `X-Errorbar-Cache` response header).","operationId":"createChatCompletion","parameters":["ca6d36a6-1ad6-44cf-80dd-c06bae2a2ee9"],"requestBody":"1c281a3e-0529-4764-ae17-97a8370d5f34","responses":{"200":"c9ccbd1d-fb36-44ab-bc9c-84509af87546","400":"84e1acab-82a7-4b1d-97ce-aec729da33e3","401":"0ffcad91-8cd4-4b52-a1d2-51b03c1a2f82","402":"58a5bd3d-e2cc-49c2-93bf-cd9bd92ad7ed","404":"d1f1e30d-23b6-41b3-a1fb-d859b34d2760"},"method":"post","type":"path","servers":["a83779d2-b0d5-4792-aa10-836bfd6e1d87","de309b0d-267d-4f43-b146-1513f01acba3"],"security":["a26c5ef8-2af2-4413-8c1f-b826d402e0b4"],"path":"/chat/completions","baseUrlOptions":["https://gateway.errorbar.ai","https://www.errorbar.ai/api"],"title":"Create chat completion","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{"ca6d36a6-1ad6-44cf-80dd-c06bae2a2ee9":{"name":"X-Errorbar-Cache-Control","in":"header","required":false,"schema":{"type":"string","enum":["no-cache","no-store"],"isRequired":false,"description":"Per-request cache control (only meaningful when the workspace has response caching enabled — it can reduce caching, never enable it). `no-cache`: skip the cache and force a fresh model run, refreshing the stored copy. `no-store`: fresh run AND keep this response out of cache storage entirely. Either way the response carries `X-Errorbar-Cache: bypass`.","uniqueKey":"","typeLabel":"enum\u003cstring>"},"description":"Per-request cache control (only meaningful when the workspace has response caching enabled — it can reduce caching, never enable it). `no-cache`: skip the cache and force a fresh model run, refreshing the stored copy. `no-store`: fresh run AND keep this response out of cache storage entirely. Either way the response carries `X-Errorbar-Cache: bypass`."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["model","messages"],"properties":{"model":{"type":"string","description":"The model id, e.g. Qwen/Qwen3-32B. A dedicated endpoint is addressed as dedicated/\u003crouting-key>.","example":"Qwen/Qwen3-32B","isRequired":true,"uniqueKey":"model","typeLabel":"string"},"messages":{"type":"array","description":"The conversation so far.","items":{"type":"object","properties":{"role":{"type":"string","enum":["system","user","assistant","tool"],"uniqueKey":"messages.items.[INDEX].role","typeLabel":"enum\u003cstring>"},"content":{"description":"String, or an array of content parts (text/image) for vision.","uniqueKey":"messages.items.[INDEX].content","typeLabel":"any"}},"uniqueKey":"messages.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"messages","typeLabel":"object[]"},"stream":{"type":"boolean","default":false,"description":"Stream the response as server-sent events.","uniqueKey":"stream","typeLabel":"boolean"},"stream_options":{"oneOf":[{"type":"object","description":"Streaming options. Usage reporting is included automatically.","uniqueKey":"stream_options.oneOf.0","typeLabel":"object"},{"type":"null","description":"Streaming options. Usage reporting is included automatically.","uniqueKey":"stream_options.oneOf.1","typeLabel":"null"}],"uniqueKey":"stream_options","typeLabel":"object | null"},"temperature":{"type":"number","description":"Sampling temperature (0–2).","uniqueKey":"temperature","typeLabel":"number"},"top_p":{"type":"number","description":"Nucleus sampling probability mass.","uniqueKey":"top_p","typeLabel":"number"},"top_k":{"type":"integer","description":"Top-k sampling.","uniqueKey":"top_k","typeLabel":"integer"},"n":{"type":"integer","description":"Number of completions to generate.","uniqueKey":"n","typeLabel":"integer"},"max_tokens":{"type":"integer","description":"Maximum output tokens. Bounded by the model's context window.","uniqueKey":"max_tokens","typeLabel":"integer"},"max_completion_tokens":{"type":"integer","description":"Alias for max_tokens.","uniqueKey":"max_completion_tokens","typeLabel":"integer"},"stop":{"description":"Up to a few stop sequences (string or array of strings).","uniqueKey":"stop","typeLabel":"any"},"seed":{"type":"integer","description":"For more reproducible sampling.","uniqueKey":"seed","typeLabel":"integer"},"frequency_penalty":{"type":"number","description":"Penalize repeated tokens by frequency.","uniqueKey":"frequency_penalty","typeLabel":"number"},"presence_penalty":{"type":"number","description":"Penalize tokens that have appeared.","uniqueKey":"presence_penalty","typeLabel":"number"},"repetition_penalty":{"type":"number","description":"Penalize repetition.","uniqueKey":"repetition_penalty","typeLabel":"number"},"logit_bias":{"type":"object","description":"Bias specific tokens.","uniqueKey":"logit_bias","typeLabel":"object"},"logprobs":{"type":"boolean","description":"Return log probabilities.","uniqueKey":"logprobs","typeLabel":"boolean"},"top_logprobs":{"type":"integer","description":"How many top log probabilities to return per token.","uniqueKey":"top_logprobs","typeLabel":"integer"},"response_format":{"type":"object","description":"{ \"type\": \"json_object\" } or { \"type\": \"json_schema\", ... } for structured output.","uniqueKey":"response_format","typeLabel":"object"},"tools":{"type":"array","description":"Function definitions the model may call.","items":{"type":"object","uniqueKey":"tools.items.[INDEX]","typeLabel":"object"},"uniqueKey":"tools","typeLabel":"object[]"},"tool_choice":{"description":"auto, required, none, or a specific function.","uniqueKey":"tool_choice","typeLabel":"any"},"parallel_tool_calls":{"type":"boolean","description":"Allow the model to call multiple tools in parallel.","uniqueKey":"parallel_tool_calls","typeLabel":"boolean"},"reasoning_effort":{"type":"string","description":"Reasoning effort for reasoning-capable models.","uniqueKey":"reasoning_effort","typeLabel":"string"},"user":{"type":"string","description":"A stable identifier for the end user.","uniqueKey":"user","typeLabel":"string"},"fallbacks":{"type":"array","maxItems":2,"items":{"type":"string","uniqueKey":"fallbacks.items.[INDEX]","typeLabel":"string"},"description":"Up to 2 backup model ids tried in order when the primary fails with a transient error (429/timeout/5xx). Billing uses the model that actually served; the X-Errorbar-Fallback-From response header names the model it fell back from. Gateway feature — never forwarded to the model.","uniqueKey":"fallbacks","typeLabel":"string[]"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"model":"Qwen/Qwen3-32B","messages":[{"content":"\u003cunknown>"}],"stream":false,"stream_options":{},"temperature":123,"top_p":123,"top_k":123,"n":123,"max_tokens":123,"max_completion_tokens":123,"stop":"\u003cunknown>","seed":123,"frequency_penalty":123,"presence_penalty":123,"repetition_penalty":123,"logit_bias":{},"logprobs":true,"top_logprobs":123,"response_format":{},"tools":[{}],"tool_choice":"\u003cunknown>","parallel_tool_calls":true,"reasoning_effort":"\u003cstring>","user":"\u003cstring>","fallbacks":["\u003cstring>"]}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"c9ccbd1d-fb36-44ab-bc9c-84509af87546":{"description":"A chat completion. When streaming, a text/event-stream of chunks ending with data: [DONE].","headers":{"X-Errorbar-Cache":{"schema":{"type":"string","enum":["hit","miss","bypass"]},"description":"Present when the workspace has response caching enabled: `hit` means this response was served from cache (billed at the cache discount), `miss` means it was generated fresh and may be stored, `bypass` means the request's `X-Errorbar-Cache-Control` header forced a fresh run. Absent when caching is off."},"X-Errorbar-Fallback-From":{"schema":{"type":"string"},"description":"Present only when a fallback model served the request: the primary model id it fell back from. The body's `model` field names the model that actually answered."}},"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","example":"chatcmpl-...","uniqueKey":"id","typeLabel":"string"},"object":{"type":"string","example":"chat.completion","uniqueKey":"object","typeLabel":"string"},"model":{"type":"string","uniqueKey":"model","typeLabel":"string"},"choices":{"type":"array","items":{"type":"object","properties":{"index":{"type":"integer","uniqueKey":"choices.items.[INDEX].index","typeLabel":"integer"},"message":{"type":"object","properties":{"role":{"type":"string","example":"assistant","uniqueKey":"choices.items.[INDEX].message.role","typeLabel":"string"},"content":{"type":"string","uniqueKey":"choices.items.[INDEX].message.content","typeLabel":"string"},"tool_calls":{"type":"array","items":{"type":"object","uniqueKey":"choices.items.[INDEX].message.tool_calls.items.[INDEX]","typeLabel":"object"},"uniqueKey":"choices.items.[INDEX].message.tool_calls","typeLabel":"object[]"}},"uniqueKey":"choices.items.[INDEX].message","typeLabel":"object"},"finish_reason":{"type":"string","example":"stop","uniqueKey":"choices.items.[INDEX].finish_reason","typeLabel":"string"}},"uniqueKey":"choices.items.[INDEX]","typeLabel":"object"},"uniqueKey":"choices","typeLabel":"object[]"},"usage":{"type":"object","properties":{"prompt_tokens":{"type":"integer","uniqueKey":"usage.prompt_tokens","typeLabel":"integer"},"completion_tokens":{"type":"integer","uniqueKey":"usage.completion_tokens","typeLabel":"integer"},"total_tokens":{"type":"integer","uniqueKey":"usage.total_tokens","typeLabel":"integer"}},"uniqueKey":"usage","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"id":"chatcmpl-...","object":"chat.completion","model":"\u003cstring>","choices":[{"index":123,"message":{"role":"assistant","content":"\u003cstring>","tool_calls":[{}]},"finish_reason":"stop"}],"usage":{"prompt_tokens":123,"completion_tokens":123,"total_tokens":123}}}},"exampleType":"generated"}},"exampleType":"generated"},"84e1acab-82a7-4b1d-97ce-aec729da33e3":{"description":"Missing a required field (e.g. model, messages/input/query/documents).","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string","uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","uniqueKey":"error.type","typeLabel":"string"},"code":{"type":"string","uniqueKey":"error.code","typeLabel":"string"}},"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"message":"\u003cstring>","type":"\u003cstring>","code":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"0ffcad91-8cd4-4b52-a1d2-51b03c1a2f82":{"description":"Missing, malformed, or revoked API key.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string","uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","uniqueKey":"error.type","typeLabel":"string"},"code":{"type":"string","uniqueKey":"error.code","typeLabel":"string"}},"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"message":"Invalid API key","type":"invalid_request_error","code":"invalid_api_key"}},"examples":{"Example":{"title":"Example","value":{"error":{"message":"Invalid API key","type":"invalid_request_error","code":"invalid_api_key"}}}},"exampleType":"examples"}},"exampleType":"examples"},"58a5bd3d-e2cc-49c2-93bf-cd9bd92ad7ed":{"description":"Your wallet can't cover the request's worst-case cost.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string","uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","uniqueKey":"error.type","typeLabel":"string"},"code":{"type":"string","uniqueKey":"error.code","typeLabel":"string"}},"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"message":"Insufficient balance. Please top up your wallet.","type":"insufficient_quota","code":"insufficient_balance"}},"examples":{"Example":{"title":"Example","value":{"error":{"message":"Insufficient balance. Please top up your wallet.","type":"insufficient_quota","code":"insufficient_balance"}}}},"exampleType":"examples"}},"exampleType":"examples"},"d1f1e30d-23b6-41b3-a1fb-d859b34d2760":{"description":"The model is not offered (or the id is wrong).","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"object","properties":{"message":{"type":"string","uniqueKey":"error.message","typeLabel":"string"},"type":{"type":"string","uniqueKey":"error.type","typeLabel":"string"},"code":{"type":"string","uniqueKey":"error.code","typeLabel":"string"}},"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":{"message":"The model 'x' does not exist or is not available.","type":"invalid_request_error","code":"model_not_found"}},"examples":{"Example":{"title":"Example","value":{"error":{"message":"The model 'x' does not exist or is not available.","type":"invalid_request_error","code":"model_not_found"}}}},"exampleType":"examples"}},"exampleType":"examples"}},"security":{"a26c5ef8-2af2-4413-8c1f-b826d402e0b4":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Your workspace API key, e.g. sk_sovereign_..., sent as Authorization: Bearer \u003ckey>.","scopes":[]}}},"servers":{"a83779d2-b0d5-4792-aa10-836bfd6e1d87":{"url":"https://gateway.errorbar.ai","description":"Production"},"de309b0d-267d-4f43-b146-1513f01acba3":{"url":"https://www.errorbar.ai/api","description":"Control plane (also served at this base URL)"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","description":"Your workspace API key, e.g. sk_sovereign_..., sent as Authorization: Bearer \u003ckey>.","scopes":[]},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Your workspace API key, e.g. sk_sovereign_..., sent as Authorization: Bearer \u003ckey>.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"openapi-inference.json"},"subdomain":"omnia-9828cd09","siteName":"errorbar","title":"Create chat completion - errorbar","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-08-29T08:07:14.924Z","originalFileLocation":"api-reference/chat/create-chat-completion.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (fallbacks) and, when the workspace has response caching enabled, serves identical repeat requests from cache at a discount (see the X-Errorbar-Cache response header).\">\u003cmeta data-mint-head name=\"application-name\" content=\"errorbar\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create chat completion - errorbar\">\u003cmeta data-mint-head property=\"og:description\" content=\"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (fallbacks) and, when the workspace has response caching enabled, serves identical repeat requests from cache at a discount (see the X-Errorbar-Cache response header).\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"errorbar\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://omnia-9828cd09.mintlify.app/_mintlify/api/og/v2?division=Inference+API\u0026amp;title=Create+chat+completion\u0026amp;description=Generate+a+model+response+for+a+conversation.+OpenAI-compatible%3B+supports+streaming%2C+tool+calls%2C+and+structured+output.+Supports+gateway+fallback+models+%28%60fallb\u0026amp;theme=4890a253571116e8d6e1ff75\u0026amp;signature=b9ef876a82fdf1f869c05d8f7631e354535d24f2f5b546de2cef342162350ba9\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Create chat completion - errorbar\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (fallbacks) and, when the workspace has response caching enabled, serves identical repeat requests from cache at a discount (see the X-Errorbar-Cache response header).\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://omnia-9828cd09.mintlify.app/_mintlify/api/og/v2?division=Inference+API\u0026amp;title=Create+chat+completion\u0026amp;description=Generate+a+model+response+for+a+conversation.+OpenAI-compatible%3B+supports+streaming%2C+tool+calls%2C+and+structured+output.+Supports+gateway+fallback+models+%28%60fallb\u0026amp;theme=4890a253571116e8d6e1ff75\u0026amp;signature=b9ef876a82fdf1f869c05d8f7631e354535d24f2f5b546de2cef342162350ba9\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/omnia-9828cd09/ubKwIdVYRFtlXDaF/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"errorbar\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#3f7d39\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/chat/create-chat-completion.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.errorbar.ai/#organization\",\"name\":\"errorbar\",\"url\":\"https://docs.errorbar.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/omnia-9828cd09/dR-r1msnM4tGAtp4/logo/light.svg?fit=max\u0026auto=format\u0026n=dR-r1msnM4tGAtp4\u0026q=85\u0026s=0a8e72505cf8b9297d6df70ae03e61f1\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.errorbar.ai#website\",\"name\":\"errorbar\",\"url\":\"https://docs.errorbar.ai\",\"publisher\":{\"@id\":\"https://docs.errorbar.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion#webpage\",\"url\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion\",\"name\":\"Create chat completion\",\"description\":\"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (fallbacks) and, when the workspace has response caching enabled, serves identical repeat requests from cache at a discount (see the X-Errorbar-Cache response header).\",\"dateModified\":\"2026-08-29T08:07:14.924Z\",\"isPartOf\":{\"@id\":\"https://docs.errorbar.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"errorbar\",\"item\":\"https://docs.errorbar.ai\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create chat completion\",\"item\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion#apireference\",\"headline\":\"Create chat completion\",\"name\":\"Create chat completion\",\"description\":\"Generate a model response for a conversation. OpenAI-compatible; supports streaming, tool calls, and structured output. Supports gateway fallback models (fallbacks) and, when the workspace has response caching enabled, serves identical repeat requests from cache at a discount (see the X-Errorbar-Cache response header).\",\"url\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion\",\"mainEntityOfPage\":{\"@id\":\"https://docs.errorbar.ai/api-reference/chat/create-chat-completion#webpage\"},\"dateModified\":\"2026-08-29T08:07:14.924Z\",\"publisher\":{\"@id\":\"https://docs.errorbar.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.errorbar.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"errorbar\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"errorbar","nav":{"global":null,"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/introduction"}]},{"tab":"SDKs","pages":[{"title":"SDKs","href":"/sdks/overview"}]},{"tab":"API Reference","groups":[{"group":"Overview","pages":[{"title":"API overview","description":"Base URL, authentication, response dialect, and what the API covers.","href":"/api-reference/introduction"}]},{"group":"Inference API","pages":[{"title":"Create chat completion","deprecated":null,"version":null,"openapi":"/openapi-inference.json post /chat/completions","href":"/api-reference/chat/create-chat-completion"},{"title":"Create embeddings","description":"Create embedding vectors for input text. Billed on input tokens only. When the workspace has [response caching](/billing/caching) enabled, identical repeat requests are served from cache at a discount (see the `X-Errorbar-Cache` response header).","deprecated":null,"version":null,"openapi":"/openapi-inference.json post /embeddings","href":"/api-reference/embeddings/create-embeddings"},{"title":"Rerank documents","deprecated":null,"version":null,"openapi":"/openapi-inference.json post /rerank","href":"/api-reference/rerank/rerank-documents"},{"title":"Create a response","deprecated":null,"version":null,"openapi":"/openapi-inference.json post /responses","href":"/api-reference/responses/create-a-response"},{"title":"List models","deprecated":null,"version":null,"openapi":"/openapi-inference.json get /models","href":"/api-reference/models/list-models"}]},{"group":"Capture \u0026 setup API","pages":[{"title":"OTLP trace ingest","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/traces","href":"/api-reference/otlp-trace-ingest"},{"title":"Setup status","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/setup/status","href":"/api-reference/setup-status"}]},{"group":"Logs \u0026 datasets API","pages":[{"title":"List logged exchanges","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/logs","href":"/api-reference/logs/list-logged-exchanges"},{"title":"Export logged exchanges as JSONL","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/logs/export","href":"/api-reference/logs/export-logged-exchanges-as-jsonl"},{"title":"Import graded traffic","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/logs/import","href":"/api-reference/logs/import-graded-traffic"},{"title":"Get an agent run / grouped conversation","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/traces/{trace_id}","href":"/api-reference/get-an-agent-run-grouped-conversation"},{"title":"Create a dataset from logs","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/datasets/from_logs","href":"/api-reference/logs/create-a-dataset-from-logs"},{"title":"Check texts for benchmark contamination","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/datasets/decontaminate","href":"/api-reference/logs/check-texts-for-benchmark-contamination"}]},{"group":"Grades (labels) API","pages":[{"title":"List trace labels","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/labels","href":"/api-reference/labels/list-trace-labels"},{"title":"Label a trace","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/labels","href":"/api-reference/labels/label-a-trace"},{"title":"List label sets","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/label_sets","href":"/api-reference/labels/list-label-sets"},{"title":"Create a label set","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/label_sets","href":"/api-reference/labels/create-a-label-set"},{"title":"Attach a label set","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/label_sets/{id}/attach","href":"/api-reference/labels/attach-a-label-set"},{"title":"Freeze a label set","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/label_sets/{id}/freeze","href":"/api-reference/labels/freeze-a-label-set"}]},{"group":"Judges (criteria) API","pages":[{"title":"List criteria","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/criteria","href":"/api-reference/criteria/list-criteria"},{"title":"Create a criterion","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/criteria","href":"/api-reference/criteria/create-a-criterion"},{"title":"List criterion templates","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/criteria/templates","href":"/api-reference/list-criterion-templates"},{"title":"Get a criterion","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/criteria/{id}","href":"/api-reference/get-a-criterion"},{"title":"Update a criterion","deprecated":null,"version":null,"openapi":"/openapi.json patch /v1/criteria/{id}","href":"/api-reference/update-a-criterion"},{"title":"Delete a criterion","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/criteria/{id}","href":"/api-reference/delete-a-criterion"},{"title":"Align a criterion against your labels","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/criteria/{id}/align","href":"/api-reference/criteria/align-a-criterion-against-your-labels"},{"title":"Get the persistent alignment report","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/criteria/{id}/alignment","href":"/api-reference/get-the-persistent-alignment-report"},{"title":"Scan unlabeled traffic for suspected failures","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/criteria/{id}/scan","href":"/api-reference/criteria/scan-unlabeled-traffic-for-suspected-failures"},{"title":"Suggest judges from your failure critiques","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/criteria/suggest","href":"/api-reference/criteria/suggest-judges-from-your-failure-critiques"},{"title":"Run one auto-improve iteration on a judge","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/criteria/{id}/auto_improve","href":"/api-reference/criteria/run-one-auto-improve-iteration-on-a-judge"},{"title":"Get a calibration certificate","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/criteria/{id}/certificate","href":"/api-reference/criteria/get-a-calibration-certificate"},{"title":"The certificate before and after adjudication","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/criteria/{id}/adjudication","href":"/api-reference/judges/the-certificate-before-and-after-adjudication"},{"title":"Adjudicate a judge/human disagreement","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/labels/{id}/adjudicate","href":"/api-reference/judges/adjudicate-a-judgehuman-disagreement"},{"title":"Get judge settings","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/settings/judge","href":"/api-reference/criteria/get-judge-settings"},{"title":"Update judge settings","deprecated":null,"version":null,"openapi":"/openapi.json put /v1/settings/judge","href":"/api-reference/criteria/update-judge-settings"}]},{"group":"Evals API","pages":[{"title":"List eval runs","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals","href":"/api-reference/evals/list-eval-runs"},{"title":"Queue an eval run","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/evals","href":"/api-reference/evals/queue-an-eval-run"},{"title":"Get an eval run","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals/{id}","href":"/api-reference/evals/get-an-eval-run"},{"title":"Delete an eval run","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/evals/{id}","href":"/api-reference/evals/delete-an-eval-run"},{"title":"Cancel an eval run","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/evals/{id}/cancel","href":"/api-reference/evals/cancel-an-eval-run"},{"title":"Get an eval run's test cases","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals/{id}/samples","href":"/api-reference/evals/get-an-eval-runs-test-cases"},{"title":"Gate a deploy on an eval run","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals/{id}/gate","href":"/api-reference/evals/gate-a-deploy-on-an-eval-run"},{"title":"Compare two eval runs","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals/compare","href":"/api-reference/evals/compare-two-eval-runs"},{"title":"List failure clusters","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals/failure_clusters","href":"/api-reference/evals/list-failure-clusters"},{"title":"Get an evidence bundle","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/evals/{id}/evidence","href":"/api-reference/evals/get-an-evidence-bundle"},{"title":"List registered endpoints","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/endpoints","href":"/api-reference/evals/list-registered-endpoints"},{"title":"Register an endpoint","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/endpoints","href":"/api-reference/evals/register-an-endpoint"},{"title":"Remove an endpoint","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/endpoints/{id}","href":"/api-reference/evals/remove-an-endpoint"}]},{"group":"Alerts API","pages":[{"title":"List fired alerts","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/alerts","href":"/api-reference/alerts/list-fired-alerts"}]},{"group":"Fine-tuning API","pages":[{"title":"List training files","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/fine_tuning/files","href":"/api-reference/fine-tuning/list-training-files"},{"title":"Upload training file","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/fine_tuning/files","href":"/api-reference/fine-tuning/upload-training-file"},{"title":"List fine-tuning jobs","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/fine_tuning/jobs","href":"/api-reference/fine-tuning/list-fine-tuning-jobs"},{"title":"Create fine-tuning job","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/fine_tuning/jobs","href":"/api-reference/fine-tuning/create-fine-tuning-job"},{"title":"Get fine-tuning job","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/fine_tuning/jobs/{id}","href":"/api-reference/fine-tuning/get-fine-tuning-job"},{"title":"Cancel fine-tuning job","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/fine_tuning/jobs/{id}","href":"/api-reference/fine-tuning/cancel-fine-tuning-job"},{"title":"Start a bake-off","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/fine_tuning/jobs/{id}/bakeoff","href":"/api-reference/fine-tuning/start-a-bake-off"},{"title":"Get bake-off state","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/fine_tuning/jobs/{id}/bakeoff","href":"/api-reference/fine-tuning/get-bake-off-state"}]},{"group":"Certified reward API","pages":[{"title":"Create a reward session","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/reward/sessions","href":"/api-reference/certified-reward/create-a-reward-session"},{"title":"List reward sessions","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/reward/sessions","href":"/api-reference/certified-reward/list-reward-sessions"},{"title":"Get a reward session","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/reward/sessions/{id}","href":"/api-reference/certified-reward/get-a-reward-session"},{"title":"Stop a reward session","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/reward/sessions/{id}","href":"/api-reference/certified-reward/stop-a-reward-session"},{"title":"Score a rollout group","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/reward/score","href":"/api-reference/certified-reward/score-a-rollout-group"},{"title":"Mid-run anchor check","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/reward/sessions/{id}/anchor","href":"/api-reference/certified-reward/mid-run-anchor-check"},{"title":"The anchor report","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/reward/sessions/{id}/anchor","href":"/api-reference/certified-reward/the-anchor-report"},{"title":"Resume a held session","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/reward/sessions/{id}/resume","href":"/api-reference/certified-reward/resume-a-held-session"},{"title":"Export the graded trajectories","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/reward/sessions/{id}/export","href":"/api-reference/certified-reward/export-the-graded-trajectories"},{"title":"Export the environment bundle","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/reward/sessions/{id}/environment","href":"/api-reference/certified-reward/export-the-environment-bundle"}]},{"group":"Reinforcement learning API","pages":[{"title":"List GRPO runs","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/grpo/runs","href":"/api-reference/reinforcement-learning/list-grpo-runs"},{"title":"Start a GRPO run","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/grpo/runs","href":"/api-reference/reinforcement-learning/start-a-grpo-run"},{"title":"Get a GRPO run","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/grpo/runs/{id}","href":"/api-reference/reinforcement-learning/get-a-grpo-run"},{"title":"Stop a GRPO run","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/grpo/runs/{id}/stop","href":"/api-reference/reinforcement-learning/stop-a-grpo-run"},{"title":"Download trained adapter weights","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/grpo/runs/{id}/weights","href":"/api-reference/reinforcement-learning/download-trained-adapter-weights"},{"title":"List RAFT rounds","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/raft/rounds","href":"/api-reference/reinforcement-learning/list-raft-rounds"},{"title":"List declared agent tools","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/env/tools","href":"/api-reference/reinforcement-learning/list-declared-agent-tools"},{"title":"Register or update a tool","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/env/tools","href":"/api-reference/reinforcement-learning/register-or-update-a-tool"},{"title":"Revoke a tool registration","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/env/tools/{id}","href":"/api-reference/reinforcement-learning/revoke-a-tool-registration"}]},{"group":"Dedicated endpoints API","pages":[{"title":"List dedicated endpoints","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/dedicated","href":"/api-reference/dedicated-endpoints/list-dedicated-endpoints"},{"title":"List deploy templates","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/dedicated/templates","href":"/api-reference/dedicated-endpoints/list-deploy-templates"},{"title":"Create dedicated endpoint","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/dedicated","href":"/api-reference/dedicated-endpoints/create-dedicated-endpoint"},{"title":"Get dedicated endpoint","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/dedicated/{id}","href":"/api-reference/dedicated-endpoints/get-dedicated-endpoint"},{"title":"Update dedicated endpoint","deprecated":null,"version":null,"openapi":"/openapi.json patch /v1/dedicated/{id}","href":"/api-reference/dedicated-endpoints/update-dedicated-endpoint"},{"title":"Delete dedicated endpoint","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/dedicated/{id}","href":"/api-reference/dedicated-endpoints/delete-dedicated-endpoint"}]},{"group":"Batches API","pages":[{"title":"List batches","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/batches","href":"/api-reference/batches/list-batches"},{"title":"Create a batch","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/batches","href":"/api-reference/batches/create-a-batch"},{"title":"Retrieve a batch","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/batches/{id}","href":"/api-reference/batches/retrieve-a-batch"},{"title":"Cancel a batch","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/batches/{id}/cancel","href":"/api-reference/batches/cancel-a-batch"}]},{"group":"Model aliases API","pages":[{"title":"List aliases","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/aliases","href":"/api-reference/model-aliases/list-aliases"},{"title":"Create or repoint an alias","deprecated":null,"version":null,"openapi":"/openapi.json put /v1/aliases","href":"/api-reference/model-aliases/create-or-repoint-an-alias"},{"title":"Delete an alias","deprecated":null,"version":null,"openapi":"/openapi.json delete /v1/aliases/{id}","href":"/api-reference/model-aliases/delete-an-alias"}]},{"group":"Model versions API","pages":[{"title":"List model versions","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/model_versions","href":"/api-reference/list-model-versions"},{"title":"Get a model version","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/model_versions/{id}","href":"/api-reference/get-a-model-version"},{"title":"Adopt a model version (or roll back)","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/model_versions/{id}/adopt","href":"/api-reference/model-versions/adopt-a-model-version-or-roll-back"}]},{"group":"Audit \u0026 proving API","pages":[{"title":"Export the audit log","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/audit/export","href":"/api-reference/audit-\u0026-proving/export-the-audit-log"},{"title":"Verify the audit chain","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/audit/verify","href":"/api-reference/audit-\u0026-proving/verify-the-audit-chain"},{"title":"List deletion tombstones","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/audit/tombstones","href":"/api-reference/audit-\u0026-proving/list-deletion-tombstones"},{"title":"Record a deletion tombstone","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/audit/tombstones","href":"/api-reference/audit-\u0026-proving/record-a-deletion-tombstone"},{"title":"List enforcement refusals","deprecated":null,"version":null,"openapi":"/openapi.json get /v1/enforcement/refusals","href":"/api-reference/audit-\u0026-proving/list-enforcement-refusals"},{"title":"Verify a signed document","deprecated":null,"version":null,"openapi":"/openapi.json post /v1/verify","href":"/api-reference/audit-\u0026-proving/verify-a-signed-document"}]}]}]},"title":"Create chat completion - errorbar","buildId":"dpl_849ArpqvBiCczQiT1Y1stNGpbqHT","deploymentId":"dpl_849ArpqvBiCczQiT1Y1stNGpbqHT","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-Bbp7I60D.js","utils-C3RIvJha.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-DqD-vLt8.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-B31Loprg.js","snippetPresets-DKpk-b8t.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-Cj65AhOR.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-BXtn5gcC.js","shallow-RY2b03Cp.js","getApiPlaygroundDisplay-B0jeiPk3.js","CodeSnippet-CYgBjjwn.js","CodeSnippets-DOngDrYB.js","Page-n7I5XbKb.js","getPastedJson-DRQbJx-T.js","icon-CQiQCicY.js","MethodPill-BKTLdNtu.js","DuplicateIcon-B9jpAdat.js","createIcon-DCddRrXv.js","DynamicMarkdown-a8hUKrw6.js","SectionHeading-eECVV2eH.js","axios-vUo_bRtp.js","Markdown--GF7ZIpf.js","clsx-DZLdJUrt.js","lib--scc4DXi.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-2LoAhjKH.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-Zwc0ZncM.js"]}