curl https://router.requesty.ai/v1/responses \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_REQUESTY_API_KEY" \ -d '{ "model": "openai-responses/gpt-5", "input": "Tell me a three sentence bedtime story about a unicorn." }'
from openai import OpenAIclient = OpenAI( api_key="YOUR_REQUESTY_API_KEY", base_url="https://router.requesty.ai/v1",)response = client.responses.create( model="openai-responses/gpt-5", input="Tell me a three sentence bedtime story about a unicorn.",)print(response.output_text)
import OpenAI from "openai";const client = new OpenAI({ apiKey: process.env.REQUESTY_API_KEY, baseURL: "https://router.requesty.ai/v1",});const response = await client.responses.create({ model: "openai-responses/gpt-5", input: "Tell me a three sentence bedtime story about a unicorn.",});console.log(response.output_text);
{ "id": "resp_abc123", "object": "response", "created_at": 1748200000, "model": "openai-responses/gpt-5", "output": [ { "type": "message", "role": "assistant", "content": [ { "type": "output_text", "text": "Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come." } ] } ], "usage": { "input_tokens": 15, "output_tokens": 58, "total_tokens": 73 }}
Create Response
Send input to an OpenAI-compatible model using the Responses API format and receive a response.
POST
/
v1
/
responses
curl https://router.requesty.ai/v1/responses \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_REQUESTY_API_KEY" \ -d '{ "model": "openai-responses/gpt-5", "input": "Tell me a three sentence bedtime story about a unicorn." }'
from openai import OpenAIclient = OpenAI( api_key="YOUR_REQUESTY_API_KEY", base_url="https://router.requesty.ai/v1",)response = client.responses.create( model="openai-responses/gpt-5", input="Tell me a three sentence bedtime story about a unicorn.",)print(response.output_text)
import OpenAI from "openai";const client = new OpenAI({ apiKey: process.env.REQUESTY_API_KEY, baseURL: "https://router.requesty.ai/v1",});const response = await client.responses.create({ model: "openai-responses/gpt-5", input: "Tell me a three sentence bedtime story about a unicorn.",});console.log(response.output_text);
{ "id": "resp_abc123", "object": "response", "created_at": 1748200000, "model": "openai-responses/gpt-5", "output": [ { "type": "message", "role": "assistant", "content": [ { "type": "output_text", "text": "Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come." } ] } ], "usage": { "input_tokens": 15, "output_tokens": 58, "total_tokens": 73 }}
curl https://router.requesty.ai/v1/responses \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_REQUESTY_API_KEY" \ -d '{ "model": "openai-responses/gpt-5", "input": "Tell me a three sentence bedtime story about a unicorn." }'
from openai import OpenAIclient = OpenAI( api_key="YOUR_REQUESTY_API_KEY", base_url="https://router.requesty.ai/v1",)response = client.responses.create( model="openai-responses/gpt-5", input="Tell me a three sentence bedtime story about a unicorn.",)print(response.output_text)
import OpenAI from "openai";const client = new OpenAI({ apiKey: process.env.REQUESTY_API_KEY, baseURL: "https://router.requesty.ai/v1",});const response = await client.responses.create({ model: "openai-responses/gpt-5", input: "Tell me a three sentence bedtime story about a unicorn.",});console.log(response.output_text);
{ "id": "resp_abc123", "object": "response", "created_at": 1748200000, "model": "openai-responses/gpt-5", "output": [ { "type": "message", "role": "assistant", "content": [ { "type": "output_text", "text": "Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come." } ] } ], "usage": { "input_tokens": 15, "output_tokens": 58, "total_tokens": 73 }}
Send input to an OpenAI-compatible model and receive a response. This endpoint follows the OpenAI Responses API format and supports all OpenAI models that expose the Responses API natively, as well as compatible models from other providers through Requesty’s routing.
curl https://router.requesty.ai/v1/responses \ -H "Content-Type: application/json" \ -H "Authorization: Bearer YOUR_REQUESTY_API_KEY" \ -d '{ "model": "openai-responses/gpt-5", "input": "Tell me a three sentence bedtime story about a unicorn." }'
The Responses endpoint is fully compatible with the official OpenAI SDK. Just point base_url at Requesty:
from openai import OpenAIclient = OpenAI( api_key="YOUR_REQUESTY_API_KEY", base_url="https://router.requesty.ai/v1",)response = client.responses.create( model="openai-responses/gpt-5", input="Tell me a three sentence bedtime story about a unicorn.",)print(response.output_text)
Google Models:google/gemini-2.5-pro, google/gemini-2.5-flash
Other Providers:mistral/mistral-large-2411, meta/llama-3.3-70b-instruct
To route OpenAI models through their native Responses API (required for full feature parity, including file inputs and the response.* event stream), use the openai-responses/ prefix. The standard openai/ prefix routes through Chat Completions under the hood.
While this endpoint uses the OpenAI Responses format, Requesty automatically handles format conversion for non-OpenAI providers, so you can
use any supported model with this endpoint.
The input field accepts either a plain string or an array of input items. Use the array form for multi-turn conversations, tool results, and rich content.
Use the instructions parameter to set a system-level prompt that applies to the entire request. It is equivalent to a system or developer message at the start of the conversation.
{ "model": "openai-responses/gpt-5", "instructions": "You are a helpful assistant that always responds in JSON.", "input": "Summarize the weather in Paris today."}
Enable streaming by setting stream: true. The response is delivered as Server-Sent Events using the OpenAI Responses event format (response.created, response.output_text.delta, response.completed, etc.).
{ "model": "openai-responses/gpt-5", "input": "Write a short story.", "stream": true}
To receive a final usage block with cost on streaming requests, no additional parameter is required. The response.completed event includes the full usage object.
Enable real-time web search by adding { "type": "web_search" } to the tools array. The response includes web_search_call output items and url_citation annotations on text content.
{ "model": "openai-responses/gpt-4.1", "input": "What are the latest developments in artificial intelligence?", "tools": [{ "type": "web_search" }], "stream": true}
Works with OpenAI, Anthropic, Vertex/Gemini, xAI, and Perplexity models. See the Web Search guide for response format details and provider-specific behavior.
Define tools the model may call. The Responses API uses a flatter shape than Chat Completions: name, description, and parameters live at the top level of each tool entry.
{ "model": "openai-responses/gpt-5", "input": "What is the weather like in New York?", "tools": [ { "type": "function", "name": "get_weather", "description": "Get the current weather in a given location", "parameters": { "type": "object", "properties": { "location": { "type": "string", "description": "The city and state, e.g. San Francisco, CA" } }, "required": ["location"] }, "strict": true } ]}
To return a tool result on the next turn, send a function_call_output item in input:
The cost field inside usage is a Requesty extension and reports the USD cost of the request. It is returned by default on non-streaming responses, and on the final response.completed event when streaming. See Cost Tracking.
input instead of messages: Accepts a string or a list of typed items (messages, tool calls, tool results, reasoning).
instructions instead of system messages: System prompts are passed via the top-level instructions field.
Flat tool shape: Tools declare name, description, and parameters directly, without the nested function wrapper.
Content types are prefixed:input_text, input_image, input_file for user inputs; output_text and output_refusal for model outputs.
Event-typed streaming: Streaming uses named events (response.created, response.output_text.delta, response.completed) rather than choice deltas.
max_output_tokens instead of max_tokens: Caps the total of visible and reasoning tokens.
For seamless compatibility with the OpenAI Python and Node SDKs’ responses.create(...) interface, use this endpoint. For broader
portability across providers, consider the Chat Completions endpoint instead.
The model to use for the response. To route OpenAI models through their native Responses API, use the openai-responses/ prefix (e.g. openai-responses/gpt-5).
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Requesty Docs","description":"Documentation for Requesty, a unified LLM gateway and OpenAI-compatible API for 600+ AI models.","colors":{"primary":"#C8956A","light":"#D4A574","dark":"#E0B88A"},"logo":{"light":"https://mintcdn.com/requesty/o8v2COiz3OtlSbqG/logo/light.svg?fit=max\u0026auto=format\u0026n=o8v2COiz3OtlSbqG\u0026q=85\u0026s=33d22576c8ec4d1e68f24969181684df","dark":"https://mintcdn.com/requesty/o8v2COiz3OtlSbqG/logo/dark.svg?fit=max\u0026auto=format\u0026n=o8v2COiz3OtlSbqG\u0026q=85\u0026s=c21a835e0692187f8c47df7ab6528af9","href":"https://docs.requesty.ai"},"favicon":"https://mintcdn.com/requesty/MM5cSf0NbVkrpoDF/favicon.svg?fit=max\u0026auto=format\u0026n=MM5cSf0NbVkrpoDF\u0026q=85\u0026s=706185ad27099920b149c4ad2f15a5ca","api":{"openapi":["api-reference/requesty_inference-openapi.json","api-reference/requesty_management-openapi.json"],"playground":{}},"appearance":{"default":"dark"},"navbar":{"links":[{"href":"https://docs.requesty.ai/changelog","label":"Changelog"},{"href":"https://docs.requesty.ai/api-reference/requesty_openapi.json","label":"OpenAPI"},{"href":"https://discord.com/invite/Td3rwAHgt4","label":"Discord"}],"primary":{"type":"button","label":"Get Started","href":"https://app.requesty.ai/sign-up"}},"footer":{"socials":{"x":"https://x.com/requestyAI","linkedin":"https://linkedin.com/company/requesty"}},"search":{"prompt":"Search..."},"seo":{"metatags":{"og:site_name":"Requesty Docs"},"indexing":"navigable"},"fonts":{"heading":{"family":"Inter","weight":600},"body":{"family":"Inter"}},"styling":{"eyebrows":"breadcrumbs","codeblocks":"dark","latex":true},"integrations":{"amplitude":{"apiKey":"ce02ec2dce31d2745bd8a3ffaedd53cc"}},"contextual":{"options":["copy","chatgpt","claude","perplexity"],"display":"header"},"metadata":{"timestamp":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"requesty","hasAudioNarration":false,"actualSubdomain":"requesty","customDomains":["docs.requesty.ai"],"gitSource":{"type":"github","owner":"requestyai","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"feedback":{"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6af491eda903f08c5db4c59e","clientVersion":"0.0.4111","searchFilterCounts":[{"language":"default","tag":"Gateway","count":58},{"language":"default","tag":"Management API","count":37},{"language":"default","tag":"Integrations","count":27},{"language":"default","tag":"Inference API","count":21},{"language":"default","tag":"Inference APIs","count":21},{"language":"default","tag":"Organization","count":15},{"language":"default","tag":"LLM Gateway","count":14},{"language":"default","tag":"Analytics \u0026 Monitoring","count":12},{"language":"default","tag":"Coding Assistants","count":11},{"language":"default","tag":"API Keys","count":9}]},"assistantConfig":{"enableStarterQuestions":false,"deflection":{"enabled":true,"email":"[email protected]","showHelpButton":true}},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[],"googleFontsInlined":false},"customCss":[{"filePath":"styles/custom.css","content":":root{--requesty-gold: #C8956A;--requesty-gold-light: #E0B88A;--requesty-gold-muted: rgba(200, 149, 106, 0.15)}::-webkit-scrollbar{width:5px;height:5px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:rgba(128, 128, 128, 0.15);border-radius:3px}::-webkit-scrollbar-thumb:hover{background:rgba(128, 128, 128, 0.3)}#navbar{backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px)}img.nav-logo{height:2.25rem!important;max-width:18rem!important;max-height:2.25rem!important}#sidebar{font-size:13.5px!important}#sidebar-content{padding-top:0.5rem}sidebar-group-header{font-weight:600!important;letter-spacing:0.01em;text-transform:none!important}#content-area{max-width:100%}#page-title{font-size:2rem!important;font-weight:600!important;letter-spacing:-0.025em!important;line-height:1.2!important}mdx-content{font-size:15px!important;line-height:1.65!important}mdx-content h2{font-size:1.35rem!important;font-weight:600!important;letter-spacing:-0.015em!important;margin-top:2rem!important;margin-bottom:0.75rem!important}mdx-content h3{font-size:1.1rem!important;font-weight:600!important;margin-top:1.5rem!important;margin-bottom:0.4rem!important}mdx-content p{margin-top:0.6em!important;margin-bottom:0.6em!important}mdx-content li{margin-top:0.2rem!important;margin-bottom:0.2rem!important}code-block{border-radius:12px!important;overflow:hidden}mdx-content code:not(pre code){border:none!important;border-radius:5px!important;padding:2px 6px!important;font-size:0.9em!important}:root:not(.dark) mdx-content code:not(pre code){background:rgba(0, 0, 0, 0.05)!important}:root.dark mdx-content code:not(pre code){background:rgba(255, 255, 255, 0.08)!important}card{border-radius:12px!important;transition:border-color 0.2s ease, background-color 0.2s ease}:root:not(.dark) card{border:1px solid rgba(0, 0, 0, 0.08)!important}:root:not(.dark) card:hover{border-color:rgba(0, 0, 0, 0.15)!important;background:rgba(0, 0, 0, 0.01)!important}:root.dark card{border:1px solid rgba(255, 255, 255, 0.06)!important}:root.dark card:hover{border-color:rgba(255, 255, 255, 0.12)!important;background:rgba(255, 255, 255, 0.02)!important}callout{border-radius:10px!important;border-left-width:3px!important}mdx-content table{border-radius:10px!important;overflow:hidden}mdx-content table th{font-weight:600!important;font-size:0.85rem!important;letter-spacing:0.02em;text-transform:uppercase}mdx-content img{border-radius:10px!important}#request-example,#response-example{border-radius:12px!important;overflow:hidden}api-section{padding-bottom:2rem}:root:not(.dark) api-section{border-bottom:1px solid rgba(0, 0, 0, 0.06)}:root.dark api-section{border-bottom:1px solid rgba(255, 255, 255, 0.05)}api-section-heading-title{font-size:1.75rem!important;font-weight:600!important;letter-spacing:-0.02em!important}#table-of-contents{font-size:13px!important}toc-item{transition:color 0.15s ease}breadcrumb-list{font-size:13px!important;opacity:0.7}nav-tabs-item{font-weight:500!important;letter-spacing:0.01em}#pagination{margin-top:2rem!important;padding-top:1rem!important}:root:not(.dark) #pagination{border-top:1px solid rgba(0, 0, 0, 0.06)!important}:root.dark #pagination{border-top:1px solid rgba(255, 255, 255, 0.05)!important}accordion{border-radius:10px!important}steps{border-left-color:rgba(200, 149, 106, 0.3)!important}step-content{padding-bottom:0.75rem!important}expandable{border-radius:8px!important}#search-bar-entry{border-radius:8px!important}nav-tag-pill{font-size:11px!important;font-weight:600!important;letter-spacing:0.03em;border-radius:4px!important}[data-component-part=\"update-tag\"]{padding:2px 8px!important;border-radius:6px!important;font-size:12px!important}:root:not(.dark) [data-component-part=\"update-tag\"]{background:rgba(0, 0, 0, 0.06)!important;color:rgb(55, 65, 81)!important}:root.dark [data-component-part=\"update-tag\"]{background:rgba(255, 255, 255, 0.1)!important;color:rgb(209, 213, 219)!important}:root:not(.dark) #footer{border-top:1px solid rgba(0, 0, 0, 0.06)!important}:root.dark #footer{border-top:1px solid rgba(255, 255, 255, 0.05)!important}"}],"page":{"pagePath":"api-reference/endpoint/responses-create","slug":"/api-reference/endpoint/responses-create","pageMetadata":{"title":"Create Response","openapi":"POST /v1/responses","description":"Send input to an OpenAI-compatible model using the Responses API format and receive a response.","href":"/api-reference/endpoint/responses-create"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Send input to an OpenAI-compatible model using the Responses API format and receive a response.\"\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,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Info,Table,Tip}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Tip)_missingMdxReference(`Tip`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Send input to an OpenAI-compatible model and receive a response. This endpoint follows the OpenAI Responses API format and supports all OpenAI models that expose the Responses API natively, as well as compatible models from other providers through Requesty’s routing.`}),`\n`,_jsx(Heading,{level:`2`,id:`base-url`,children:`Base URL`}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://router.requesty.ai/v1/responses`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(Heading,{level:`2`,id:`authentication`,children:`Authentication`}),`\n`,_jsxs(_components.p,{children:[`The Responses endpoint accepts either OpenAI-style bearer auth or Anthropic-style `,_jsx(_components.code,{children:`x-api-key`}),` auth. Use whichever your client library expects.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`Authorization: Bearer YOUR_REQUESTY_API_KEY`})}),`\n`]})})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`x-api-key: YOUR_REQUESTY_API_KEY`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`headers`,children:`Headers`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Header`}),_jsx(_components.th,{children:`Required`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Authorization`})}),_jsx(_components.td,{children:`✅ *`}),_jsx(_components.td,{children:`Bearer token with your Requesty key`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`x-api-key`})}),_jsx(_components.td,{children:`✅ *`}),_jsx(_components.td,{children:`Your Requesty API key (alternative)`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Content-Type`})}),_jsx(_components.td,{children:`✅`}),_jsxs(_components.td,{children:[`Must be `,_jsx(_components.code,{children:`application/json`})]})]})]})]}),`\n`,_jsxs(_components.p,{children:[`* Provide one of `,_jsx(_components.code,{children:`Authorization`}),` or `,_jsx(_components.code,{children:`x-api-key`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`example-request`,children:`Example Request`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#DCDCAA`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` https://router.requesty.ai/v1/responses \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Authorization: Bearer YOUR_REQUESTY_API_KEY\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -d `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`'{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"model\": \"openai-responses/gpt-5\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"input\": \"Tell me a three sentence bedtime story about a unicorn.\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`using-the-openai-sdk`,children:`Using the OpenAI SDK`}),`\n`,_jsxs(_components.p,{children:[`The Responses endpoint is fully compatible with the official OpenAI SDK. Just point `,_jsx(_components.code,{children:`base_url`}),` at Requesty:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`13`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` openai `}),_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` OpenAI`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`client = OpenAI(`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` api_key=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_REQUESTY_API_KEY\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` base_url=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"https://router.requesty.ai/v1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`response = client.responses.create(`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` model=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` input=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Tell me a three sentence bedtime story about a unicorn.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`print(response.output_text)`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`model-selection`,children:`Model Selection`}),`\n`,_jsxs(_components.p,{children:[`You can use any model available in the `,_jsx(_components.a,{href:`https://app.requesty.ai/model-list`,children:`Model Library`}),`. Requesty translates the request shape for non-OpenAI providers automatically.`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`OpenAI Models:`}),` `,_jsx(_components.code,{children:`openai-responses/gpt-5`}),`, `,_jsx(_components.code,{children:`openai-responses/gpt-5-mini`}),`, `,_jsx(_components.code,{children:`openai-responses/gpt-4.1`}),`, `,_jsx(_components.code,{children:`openai-responses/gpt-4o`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Anthropic Models:`}),` `,_jsx(_components.code,{children:`anthropic/claude-sonnet-4-5`}),`, `,_jsx(_components.code,{children:`anthropic/claude-opus-4`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Google Models:`}),` `,_jsx(_components.code,{children:`google/gemini-2.5-pro`}),`, `,_jsx(_components.code,{children:`google/gemini-2.5-flash`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Other Providers:`}),` `,_jsx(_components.code,{children:`mistral/mistral-large-2411`}),`, `,_jsx(_components.code,{children:`meta/llama-3.3-70b-instruct`})]}),`\n`]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`To route OpenAI models through their native Responses API (required for full feature parity, including file inputs and the `,_jsx(_components.code,{children:`response.*`}),` event stream), use the `,_jsx(_components.code,{children:`openai-responses/`}),` prefix. The standard `,_jsx(_components.code,{children:`openai/`}),` prefix routes through Chat Completions under the hood.`]})}),`\n`,_jsx(Info,{children:_jsx(_components.p,{children:`While this endpoint uses the OpenAI Responses format, Requesty automatically handles format conversion for non-OpenAI providers, so you can\nuse any supported model with this endpoint.`})}),`\n`,_jsx(Heading,{level:`2`,id:`input-formats`,children:`Input Formats`}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`input`}),` field accepts either a plain string or an array of input items. Use the array form for multi-turn conversations, tool results, and rich content.`]}),`\n`,_jsx(Heading,{level:`3`,id:`string-input`,children:`String input`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Write a haiku about routers.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`multi-turn-input`,children:`Multi-turn input`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Hi, my name is John.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"assistant\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Hello John, nice to meet you.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What is my name?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`instructions`,children:`Instructions`}),`\n`,_jsxs(_components.p,{children:[`Use the `,_jsx(_components.code,{children:`instructions`}),` parameter to set a system-level prompt that applies to the entire request. It is equivalent to a system or developer message at the start of the conversation.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"instructions\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"You are a helpful assistant that always responds in JSON.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Summarize the weather in Paris today.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`streaming`,children:`Streaming`}),`\n`,_jsxs(_components.p,{children:[`Enable streaming by setting `,_jsx(_components.code,{children:`stream: true`}),`. The response is delivered as Server-Sent Events using the OpenAI Responses event format (`,_jsx(_components.code,{children:`response.created`}),`, `,_jsx(_components.code,{children:`response.output_text.delta`}),`, `,_jsx(_components.code,{children:`response.completed`}),`, etc.).`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Write a short story.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"stream\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`To receive a final `,_jsx(_components.code,{children:`usage`}),` block with cost on streaming requests, no additional parameter is required. The `,_jsx(_components.code,{children:`response.completed`}),` event includes the full `,_jsx(_components.code,{children:`usage`}),` object.`]}),`\n`,_jsx(Heading,{level:`2`,id:`vision-support`,children:`Vision Support`}),`\n`,_jsxs(_components.p,{children:[`Send images using the `,_jsx(_components.code,{children:`input_image`}),` content type. You can pass an image URL or a base64 data URL.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`15`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`15`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What is in this image?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_image\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"image_url\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"https://example.com/image.jpg\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`pdf-support`,children:`PDF Support`}),`\n`,_jsxs(_components.p,{children:[`Send PDFs using the `,_jsx(_components.code,{children:`input_file`}),` content type. You can provide the PDF as either a base64 data URL or a remote URL.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`16`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Summarize this PDF.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_file\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"filename\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"document.pdf\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"file_data\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"data:application/pdf;base64,\u003cbase64-encoded-pdf-data>\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`/features/pdf-support`,children:`PDF Support`}),` guide for the full list of supported providers.`]}),`\n`,_jsx(Heading,{level:`2`,id:`web-search`,children:`Web Search`}),`\n`,_jsxs(_components.p,{children:[`Enable real-time web search by adding `,_jsx(_components.code,{children:`{ \"type\": \"web_search\" }`}),` to the `,_jsx(_components.code,{children:`tools`}),` array. The response includes `,_jsx(_components.code,{children:`web_search_call`}),` output items and `,_jsx(_components.code,{children:`url_citation`}),` annotations on text content.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`6`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-4.1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What are the latest developments in artificial intelligence?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"tools\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"web_search\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"stream\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Works with OpenAI, Anthropic, Vertex/Gemini, xAI, and Perplexity models. See the `,_jsx(_components.a,{href:`/features/web-search`,children:`Web Search guide`}),` for response format details and provider-specific behavior.`]}),`\n`,_jsx(Heading,{level:`2`,id:`tool-use`,children:`Tool Use`}),`\n`,_jsxs(_components.p,{children:[`Define tools the model may call. The Responses API uses a flatter shape than Chat Completions: `,_jsx(_components.code,{children:`name`}),`, `,_jsx(_components.code,{children:`description`}),`, and `,_jsx(_components.code,{children:`parameters`}),` live at the top level of each tool entry.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`22`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`22`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What is the weather like in New York?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"tools\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"function\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"name\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"get_weather\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"description\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Get the current weather in a given location\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"parameters\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"properties\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"location\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\t\"description\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"The city and state, e.g. San Francisco, CA\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t},`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"required\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"location\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t},`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"strict\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`To return a tool result on the next turn, send a `,_jsx(_components.code,{children:`function_call_output`}),` item in `,_jsx(_components.code,{children:`input`}),`:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`16`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"function_call\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"name\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"get_weather\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"call_id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"call_abc123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"arguments\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"{`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`location`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`: `}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`New York, NY`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`}\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t},`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"function_call_output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"call_id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"call_abc123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"{`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`temperature`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`: 68, `}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`conditions`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`: `}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`sunny`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`}\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`reasoning`,children:`Reasoning`}),`\n`,_jsxs(_components.p,{children:[`For reasoning-capable models (e.g. `,_jsx(_components.code,{children:`openai-responses/gpt-5`}),`, `,_jsx(_components.code,{children:`openai-responses/o3`}),`), configure reasoning effort and the optional summary:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Plan a three day trip to Tokyo.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"reasoning\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"effort\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"medium\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"summary\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"auto\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`effort`}),`: `,_jsx(_components.code,{children:`low`}),`, `,_jsx(_components.code,{children:`medium`}),`, or `,_jsx(_components.code,{children:`high`}),`. Lower effort produces faster responses with fewer reasoning tokens.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`summary`}),`: `,_jsx(_components.code,{children:`auto`}),`, `,_jsx(_components.code,{children:`concise`}),`, or `,_jsx(_components.code,{children:`detailed`}),`. Controls whether the model returns a reasoning summary alongside the final answer.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`structured-outputs`,children:`Structured Outputs`}),`\n`,_jsxs(_components.p,{children:[`Set `,_jsx(_components.code,{children:`text.format`}),` to enforce JSON-mode or a strict JSON Schema on the output.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`18`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`18`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Extract entities from: The quick brown fox jumps over the lazy dog.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"format\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"json_schema\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"name\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Entities\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"strict\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"schema\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"properties\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"animals\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"array\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"items\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` } }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t},`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"required\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"animals\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`/features/structured-outputs`,children:`Structured Outputs`}),` guide for full examples.`]}),`\n`,_jsx(Heading,{level:`2`,id:`response-format`,children:`Response Format`}),`\n`,_jsx(_components.p,{children:`A successful response follows the OpenAI Responses format:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`29`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`29`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"resp_01ABC123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"response\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"created_at\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`1730000000`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"status\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"completed\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"msg_01ABC123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"message\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"assistant\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"status\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"completed\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"output_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Once upon a time, a unicorn...\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t],`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"usage\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"input_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`12`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"input_tokens_details\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"cached_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"output_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`27`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"output_tokens_details\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"reasoning_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"total_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`39`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"cost\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`0.000234`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`cost`}),` field inside `,_jsx(_components.code,{children:`usage`}),` is a Requesty extension and reports the USD cost of the request. It is returned by default on non-streaming responses, and on the final `,_jsx(_components.code,{children:`response.completed`}),` event when streaming. See `,_jsx(_components.a,{href:`/features/cost-tracking#per-request-cost-in-the-api-response`,children:`Cost Tracking`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`error-handling`,children:`Error Handling`}),`\n`,_jsx(_components.p,{children:`The API returns standard HTTP status codes:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`200`}),` - Success`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`400`}),` - Bad Request (invalid parameters)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`401`}),` - Unauthorized (invalid API key)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`403`}),` - Forbidden (insufficient permissions)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`413`}),` - Payload Too Large (request body exceeds 50 MB)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`429`}),` - Rate Limited`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`500`}),` - Internal Server Error`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`key-differences-from-openai-chat-completions`,children:`Key Differences from OpenAI Chat Completions`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[_jsx(_components.code,{children:`input`}),` instead of `,_jsx(_components.code,{children:`messages`}),`:`]}),` Accepts a string or a list of typed items (messages, tool calls, tool results, reasoning).`]}),`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[_jsx(_components.code,{children:`instructions`}),` instead of system messages:`]}),` System prompts are passed via the top-level `,_jsx(_components.code,{children:`instructions`}),` field.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Flat tool shape:`}),` Tools declare `,_jsx(_components.code,{children:`name`}),`, `,_jsx(_components.code,{children:`description`}),`, and `,_jsx(_components.code,{children:`parameters`}),` directly, without the nested `,_jsx(_components.code,{children:`function`}),` wrapper.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Content types are prefixed:`}),` `,_jsx(_components.code,{children:`input_text`}),`, `,_jsx(_components.code,{children:`input_image`}),`, `,_jsx(_components.code,{children:`input_file`}),` for user inputs; `,_jsx(_components.code,{children:`output_text`}),` and `,_jsx(_components.code,{children:`output_refusal`}),` for model outputs.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Event-typed streaming:`}),` Streaming uses named events (`,_jsx(_components.code,{children:`response.created`}),`, `,_jsx(_components.code,{children:`response.output_text.delta`}),`, `,_jsx(_components.code,{children:`response.completed`}),`) rather than choice deltas.`]}),`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[_jsx(_components.code,{children:`max_output_tokens`}),` instead of `,_jsx(_components.code,{children:`max_tokens`}),`:`]}),` Caps the total of visible and reasoning tokens.`]}),`\n`]}),`\n`,_jsx(Tip,{children:_jsxs(_components.p,{children:[`For seamless compatibility with the OpenAI Python and Node SDKs’ `,_jsx(_components.code,{children:`responses.create(...)`}),` interface, use this endpoint. For broader\nportability across providers, consider the `,_jsx(_components.a,{href:`/api-reference/endpoint/chat-completions-create`,children:`Chat Completions endpoint`}),` instead.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"dark","config":{},"pageMetadata":{"title":"Create Response","openapi":"POST /v1/responses","description":"Send input to an OpenAI-compatible model using the Responses API format and receive a response.","href":"/api-reference/endpoint/responses-create"}}},"mdxSourceWithNoJs":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Info,RequestExample,ResponseExample,Table,Tip}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!RequestExample)_missingMdxReference(`RequestExample`,true);if(!ResponseExample)_missingMdxReference(`ResponseExample`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Tip)_missingMdxReference(`Tip`,true);return _jsxs(_Fragment,{children:[_jsxs(RequestExample,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#DCDCAA`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` https://router.requesty.ai/v1/responses \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Authorization: Bearer YOUR_REQUESTY_API_KEY\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -d `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`'{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"model\": \"openai-responses/gpt-5\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"input\": \"Tell me a three sentence bedtime story about a unicorn.\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`Python`,numberOfLines:`13`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` openai `}),_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` OpenAI`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`client = OpenAI(`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` api_key=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_REQUESTY_API_KEY\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` base_url=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"https://router.requesty.ai/v1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`response = client.responses.create(`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` model=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` input=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Tell me a three sentence bedtime story about a unicorn.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`print(response.output_text)`})}),`\n`]})})}),_jsx(CodeBlock,{filename:`TypeScript`,numberOfLines:`13`,language:`typescript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`typescript`,children:_jsxs(_components.code,{language:`typescript`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` OpenAI `}),_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"openai\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`;`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`const`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` client = `}),_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`new`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` OpenAI({`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` apiKey: process.env.REQUESTY_API_KEY,`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` baseURL: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"https://router.requesty.ai/v1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`const`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` response = `}),_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`await`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` client.responses.create({`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` model: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` input: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Tell me a three sentence bedtime story about a unicorn.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`console.log(response.output_text);`})}),`\n`]})})})]}),`\n`,_jsx(ResponseExample,{children:_jsx(CodeBlock,{filename:`Response 200`,numberOfLines:`23`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`23`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"resp_abc123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"response\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"created_at\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`1748200000`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"message\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"assistant\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` {`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"output_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` ]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` ],`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"usage\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"input_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`15`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"output_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`58`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"total_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`73`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})})}),`\n`,_jsx(_components.p,{children:`Send input to an OpenAI-compatible model and receive a response. This endpoint follows the OpenAI Responses API format and supports all OpenAI models that expose the Responses API natively, as well as compatible models from other providers through Requesty’s routing.`}),`\n`,_jsx(Heading,{level:`2`,id:`base-url`,children:`Base URL`}),`\n`,_jsx(CodeBlock,{numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://router.requesty.ai/v1/responses`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(Heading,{level:`2`,id:`authentication`,children:`Authentication`}),`\n`,_jsxs(_components.p,{children:[`The Responses endpoint accepts either OpenAI-style bearer auth or Anthropic-style `,_jsx(_components.code,{children:`x-api-key`}),` auth. Use whichever your client library expects.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`Authorization: Bearer YOUR_REQUESTY_API_KEY`})}),`\n`]})})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`x-api-key: YOUR_REQUESTY_API_KEY`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`headers`,children:`Headers`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Header`}),_jsx(_components.th,{children:`Required`}),_jsx(_components.th,{children:`Description`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Authorization`})}),_jsx(_components.td,{children:`✅ *`}),_jsx(_components.td,{children:`Bearer token with your Requesty key`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`x-api-key`})}),_jsx(_components.td,{children:`✅ *`}),_jsx(_components.td,{children:`Your Requesty API key (alternative)`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`Content-Type`})}),_jsx(_components.td,{children:`✅`}),_jsxs(_components.td,{children:[`Must be `,_jsx(_components.code,{children:`application/json`})]})]})]})]}),`\n`,_jsxs(_components.p,{children:[`* Provide one of `,_jsx(_components.code,{children:`Authorization`}),` or `,_jsx(_components.code,{children:`x-api-key`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`example-request`,children:`Example Request`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#DCDCAA`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` https://router.requesty.ai/v1/responses \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -H `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Authorization: Bearer YOUR_REQUESTY_API_KEY\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` -d `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`'{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"model\": \"openai-responses/gpt-5\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` \"input\": \"Tell me a three sentence bedtime story about a unicorn.\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`using-the-openai-sdk`,children:`Using the OpenAI SDK`}),`\n`,_jsxs(_components.p,{children:[`The Responses endpoint is fully compatible with the official OpenAI SDK. Just point `,_jsx(_components.code,{children:`base_url`}),` at Requesty:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`13`,language:`python`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`python`,children:_jsxs(_components.code,{language:`python`,numberOfLines:`13`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`from`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` openai `}),_jsx(_components.span,{style:{color:`#C586C0`,\"--shiki-dark\":`#C586C0`},children:`import`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` OpenAI`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`client = OpenAI(`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` api_key=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"YOUR_REQUESTY_API_KEY\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` base_url=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"https://router.requesty.ai/v1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`response = client.responses.create(`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` model=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` input=`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Tell me a three sentence bedtime story about a unicorn.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`)`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`print(response.output_text)`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`model-selection`,children:`Model Selection`}),`\n`,_jsxs(_components.p,{children:[`You can use any model available in the `,_jsx(_components.a,{href:`https://app.requesty.ai/model-list`,children:`Model Library`}),`. Requesty translates the request shape for non-OpenAI providers automatically.`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`OpenAI Models:`}),` `,_jsx(_components.code,{children:`openai-responses/gpt-5`}),`, `,_jsx(_components.code,{children:`openai-responses/gpt-5-mini`}),`, `,_jsx(_components.code,{children:`openai-responses/gpt-4.1`}),`, `,_jsx(_components.code,{children:`openai-responses/gpt-4o`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Anthropic Models:`}),` `,_jsx(_components.code,{children:`anthropic/claude-sonnet-4-5`}),`, `,_jsx(_components.code,{children:`anthropic/claude-opus-4`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Google Models:`}),` `,_jsx(_components.code,{children:`google/gemini-2.5-pro`}),`, `,_jsx(_components.code,{children:`google/gemini-2.5-flash`})]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Other Providers:`}),` `,_jsx(_components.code,{children:`mistral/mistral-large-2411`}),`, `,_jsx(_components.code,{children:`meta/llama-3.3-70b-instruct`})]}),`\n`]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`To route OpenAI models through their native Responses API (required for full feature parity, including file inputs and the `,_jsx(_components.code,{children:`response.*`}),` event stream), use the `,_jsx(_components.code,{children:`openai-responses/`}),` prefix. The standard `,_jsx(_components.code,{children:`openai/`}),` prefix routes through Chat Completions under the hood.`]})}),`\n`,_jsx(Info,{children:_jsx(_components.p,{children:`While this endpoint uses the OpenAI Responses format, Requesty automatically handles format conversion for non-OpenAI providers, so you can\nuse any supported model with this endpoint.`})}),`\n`,_jsx(Heading,{level:`2`,id:`input-formats`,children:`Input Formats`}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`input`}),` field accepts either a plain string or an array of input items. Use the array form for multi-turn conversations, tool results, and rich content.`]}),`\n`,_jsx(Heading,{level:`3`,id:`string-input`,children:`String input`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`4`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`4`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Write a haiku about routers.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`multi-turn-input`,children:`Multi-turn input`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Hi, my name is John.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"assistant\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Hello John, nice to meet you.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What is my name?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`instructions`,children:`Instructions`}),`\n`,_jsxs(_components.p,{children:[`Use the `,_jsx(_components.code,{children:`instructions`}),` parameter to set a system-level prompt that applies to the entire request. It is equivalent to a system or developer message at the start of the conversation.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"instructions\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"You are a helpful assistant that always responds in JSON.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Summarize the weather in Paris today.\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`streaming`,children:`Streaming`}),`\n`,_jsxs(_components.p,{children:[`Enable streaming by setting `,_jsx(_components.code,{children:`stream: true`}),`. The response is delivered as Server-Sent Events using the OpenAI Responses event format (`,_jsx(_components.code,{children:`response.created`}),`, `,_jsx(_components.code,{children:`response.output_text.delta`}),`, `,_jsx(_components.code,{children:`response.completed`}),`, etc.).`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`5`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Write a short story.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"stream\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`To receive a final `,_jsx(_components.code,{children:`usage`}),` block with cost on streaming requests, no additional parameter is required. The `,_jsx(_components.code,{children:`response.completed`}),` event includes the full `,_jsx(_components.code,{children:`usage`}),` object.`]}),`\n`,_jsx(Heading,{level:`2`,id:`vision-support`,children:`Vision Support`}),`\n`,_jsxs(_components.p,{children:[`Send images using the `,_jsx(_components.code,{children:`input_image`}),` content type. You can pass an image URL or a base64 data URL.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`15`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`15`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What is in this image?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_image\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"image_url\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"https://example.com/image.jpg\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`pdf-support`,children:`PDF Support`}),`\n`,_jsxs(_components.p,{children:[`Send PDFs using the `,_jsx(_components.code,{children:`input_file`}),` content type. You can provide the PDF as either a base64 data URL or a remote URL.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`16`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"user\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Summarize this PDF.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"input_file\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"filename\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"document.pdf\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"file_data\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"data:application/pdf;base64,\u003cbase64-encoded-pdf-data>\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`/features/pdf-support`,children:`PDF Support`}),` guide for the full list of supported providers.`]}),`\n`,_jsx(Heading,{level:`2`,id:`web-search`,children:`Web Search`}),`\n`,_jsxs(_components.p,{children:[`Enable real-time web search by adding `,_jsx(_components.code,{children:`{ \"type\": \"web_search\" }`}),` to the `,_jsx(_components.code,{children:`tools`}),` array. The response includes `,_jsx(_components.code,{children:`web_search_call`}),` output items and `,_jsx(_components.code,{children:`url_citation`}),` annotations on text content.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`6`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-4.1\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What are the latest developments in artificial intelligence?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"tools\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [{ `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"web_search\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` }],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:` \"stream\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Works with OpenAI, Anthropic, Vertex/Gemini, xAI, and Perplexity models. See the `,_jsx(_components.a,{href:`/features/web-search`,children:`Web Search guide`}),` for response format details and provider-specific behavior.`]}),`\n`,_jsx(Heading,{level:`2`,id:`tool-use`,children:`Tool Use`}),`\n`,_jsxs(_components.p,{children:[`Define tools the model may call. The Responses API uses a flatter shape than Chat Completions: `,_jsx(_components.code,{children:`name`}),`, `,_jsx(_components.code,{children:`description`}),`, and `,_jsx(_components.code,{children:`parameters`}),` live at the top level of each tool entry.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`22`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`22`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"What is the weather like in New York?\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"tools\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"function\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"name\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"get_weather\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"description\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Get the current weather in a given location\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"parameters\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"properties\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"location\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\t\"description\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"The city and state, e.g. San Francisco, CA\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t},`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"required\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"location\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t},`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"strict\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`To return a tool result on the next turn, send a `,_jsx(_components.code,{children:`function_call_output`}),` item in `,_jsx(_components.code,{children:`input`}),`:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`16`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"function_call\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"name\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"get_weather\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"call_id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"call_abc123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"arguments\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"{`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`location`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`: `}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`New York, NY`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`}\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t},`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"function_call_output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"call_id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"call_abc123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"{`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`temperature`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`: 68, `}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`conditions`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`: `}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`sunny`}),_jsx(_components.span,{style:{color:`#D7BA7D`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\\"`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`}\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`reasoning`,children:`Reasoning`}),`\n`,_jsxs(_components.p,{children:[`For reasoning-capable models (e.g. `,_jsx(_components.code,{children:`openai-responses/gpt-5`}),`, `,_jsx(_components.code,{children:`openai-responses/o3`}),`), configure reasoning effort and the optional summary:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Plan a three day trip to Tokyo.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"reasoning\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"effort\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"medium\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"summary\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"auto\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`effort`}),`: `,_jsx(_components.code,{children:`low`}),`, `,_jsx(_components.code,{children:`medium`}),`, or `,_jsx(_components.code,{children:`high`}),`. Lower effort produces faster responses with fewer reasoning tokens.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`summary`}),`: `,_jsx(_components.code,{children:`auto`}),`, `,_jsx(_components.code,{children:`concise`}),`, or `,_jsx(_components.code,{children:`detailed`}),`. Controls whether the model returns a reasoning summary alongside the final answer.`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`structured-outputs`,children:`Structured Outputs`}),`\n`,_jsxs(_components.p,{children:[`Set `,_jsx(_components.code,{children:`text.format`}),` to enforce JSON-mode or a strict JSON Schema on the output.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`18`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`18`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"input\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Extract entities from: The quick brown fox jumps over the lazy dog.\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"format\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"json_schema\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"name\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Entities\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"strict\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#569CD6`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"schema\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"properties\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"animals\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"array\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"items\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"string\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` } }`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t},`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\"required\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"animals\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`]`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`/features/structured-outputs`,children:`Structured Outputs`}),` guide for full examples.`]}),`\n`,_jsx(Heading,{level:`2`,id:`response-format`,children:`Response Format`}),`\n`,_jsx(_components.p,{children:`A successful response follows the OpenAI Responses format:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`29`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes dark-plus dark-plus`,style:{backgroundColor:`#0B0C0E`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`29`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"resp_01ABC123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"object\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"response\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"created_at\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`1730000000`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"model\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"openai-responses/gpt-5\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"status\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"completed\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"output\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"id\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"msg_01ABC123\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"message\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"role\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"assistant\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"status\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"completed\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\"content\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: [`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"type\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"output_text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\t\t\t\"text\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#CE9178`,\"--shiki-dark\":`#CE9178`},children:`\"Once upon a time, a unicorn...\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t\t]`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t],`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\"usage\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"input_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`12`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"input_tokens_details\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"cached_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"output_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`27`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"output_tokens_details\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: { `}),_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\"reasoning_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:` },`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"total_tokens\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`39`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#9CDCFE`,\"--shiki-dark\":`#9CDCFE`},children:`\t\t\"cost\"`}),_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#B5CEA8`,\"--shiki-dark\":`#B5CEA8`},children:`0.000234`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`\t}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#D4D4D4`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The `,_jsx(_components.code,{children:`cost`}),` field inside `,_jsx(_components.code,{children:`usage`}),` is a Requesty extension and reports the USD cost of the request. It is returned by default on non-streaming responses, and on the final `,_jsx(_components.code,{children:`response.completed`}),` event when streaming. See `,_jsx(_components.a,{href:`/features/cost-tracking#per-request-cost-in-the-api-response`,children:`Cost Tracking`}),`.`]}),`\n`,_jsx(Heading,{level:`2`,id:`error-handling`,children:`Error Handling`}),`\n`,_jsx(_components.p,{children:`The API returns standard HTTP status codes:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`200`}),` - Success`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`400`}),` - Bad Request (invalid parameters)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`401`}),` - Unauthorized (invalid API key)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`403`}),` - Forbidden (insufficient permissions)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`413`}),` - Payload Too Large (request body exceeds 50 MB)`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`429`}),` - Rate Limited`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`500`}),` - Internal Server Error`]}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`key-differences-from-openai-chat-completions`,children:`Key Differences from OpenAI Chat Completions`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[_jsx(_components.code,{children:`input`}),` instead of `,_jsx(_components.code,{children:`messages`}),`:`]}),` Accepts a string or a list of typed items (messages, tool calls, tool results, reasoning).`]}),`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[_jsx(_components.code,{children:`instructions`}),` instead of system messages:`]}),` System prompts are passed via the top-level `,_jsx(_components.code,{children:`instructions`}),` field.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Flat tool shape:`}),` Tools declare `,_jsx(_components.code,{children:`name`}),`, `,_jsx(_components.code,{children:`description`}),`, and `,_jsx(_components.code,{children:`parameters`}),` directly, without the nested `,_jsx(_components.code,{children:`function`}),` wrapper.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Content types are prefixed:`}),` `,_jsx(_components.code,{children:`input_text`}),`, `,_jsx(_components.code,{children:`input_image`}),`, `,_jsx(_components.code,{children:`input_file`}),` for user inputs; `,_jsx(_components.code,{children:`output_text`}),` and `,_jsx(_components.code,{children:`output_refusal`}),` for model outputs.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Event-typed streaming:`}),` Streaming uses named events (`,_jsx(_components.code,{children:`response.created`}),`, `,_jsx(_components.code,{children:`response.output_text.delta`}),`, `,_jsx(_components.code,{children:`response.completed`}),`) rather than choice deltas.`]}),`\n`,_jsxs(_components.li,{children:[_jsxs(_components.strong,{children:[_jsx(_components.code,{children:`max_output_tokens`}),` instead of `,_jsx(_components.code,{children:`max_tokens`}),`:`]}),` Caps the total of visible and reasoning tokens.`]}),`\n`]}),`\n`,_jsx(Tip,{children:_jsxs(_components.p,{children:[`For seamless compatibility with the OpenAI Python and Node SDKs’ `,_jsx(_components.code,{children:`responses.create(...)`}),` interface, use this endpoint. For broader\nportability across providers, consider the `,_jsx(_components.a,{href:`/api-reference/endpoint/chat-completions-create`,children:`Chat Completions endpoint`}),` instead.`]})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"codeStyling":"dark","config":{},"pageMetadata":{"title":"Create Response","openapi":"POST /v1/responses","description":"Send input to an OpenAI-compatible model using the Responses API format and receive a response.","href":"/api-reference/endpoint/responses-create"}}}},"mdxExtracts":{"tableOfContents":[{"title":"Base URL","slug":"base-url","depth":2,"children":[]},{"title":"Authentication","slug":"authentication","depth":2,"children":[]},{"title":"Headers","slug":"headers","depth":2,"children":[]},{"title":"Example Request","slug":"example-request","depth":2,"children":[]},{"title":"Using the OpenAI SDK","slug":"using-the-openai-sdk","depth":2,"children":[]},{"title":"Model Selection","slug":"model-selection","depth":2,"children":[]},{"title":"Input Formats","slug":"input-formats","depth":2,"children":[{"title":"String input","slug":"string-input","depth":3,"children":[]},{"title":"Multi-turn input","slug":"multi-turn-input","depth":3,"children":[]}]},{"title":"Instructions","slug":"instructions","depth":2,"children":[]},{"title":"Streaming","slug":"streaming","depth":2,"children":[]},{"title":"Vision Support","slug":"vision-support","depth":2,"children":[]},{"title":"PDF Support","slug":"pdf-support","depth":2,"children":[]},{"title":"Web Search","slug":"web-search","depth":2,"children":[]},{"title":"Tool Use","slug":"tool-use","depth":2,"children":[]},{"title":"Reasoning","slug":"reasoning","depth":2,"children":[]},{"title":"Structured Outputs","slug":"structured-outputs","depth":2,"children":[]},{"title":"Response Format","slug":"response-format","depth":2,"children":[]},{"title":"Error Handling","slug":"error-handling","depth":2,"children":[]},{"title":"Key Differences from OpenAI Chat Completions","slug":"key-differences-from-openai-chat-completions","depth":2,"children":[]}],"codeExamples":{"request":{"type":"RequestExample","children":[{"filename":"cURL","html":"\u003cpre class=\"shiki shiki-themes dark-plus dark-plus\" style=\"background-color:#0B0C0E;--shiki-dark-bg:#0B0C0E;color:#D4D4D4;--shiki-dark:#D4D4D4\" language=\"shellscript\">\u003ccode language=\"shellscript\" numberOfLines=\"7\">\u003cspan class=\"line\">\u003cspan style=\"color:#DCDCAA;--shiki-dark:#DCDCAA\">curl\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> https://router.requesty.ai/v1/responses \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> -H \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"Content-Type: application/json\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> -H \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"Authorization: Bearer YOUR_REQUESTY_API_KEY\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> -d \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">'{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\"> \"model\": \"openai-responses/gpt-5\",\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\"> \"input\": \"Tell me a three sentence bedtime story about a unicorn.\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\"> }'\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"Python","html":"\u003cpre class=\"shiki shiki-themes dark-plus dark-plus\" style=\"background-color:#0B0C0E;--shiki-dark-bg:#0B0C0E;color:#D4D4D4;--shiki-dark:#D4D4D4\" language=\"python\">\u003ccode language=\"python\" numberOfLines=\"13\">\u003cspan class=\"line\">\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">from\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> openai \u003c/span>\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">import\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> OpenAI\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">client = OpenAI(\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> api_key=\u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"YOUR_REQUESTY_API_KEY\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> base_url=\u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"https://router.requesty.ai/v1\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">)\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">response = client.responses.create(\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> model=\u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"openai-responses/gpt-5\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> input=\u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"Tell me a three sentence bedtime story about a unicorn.\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">)\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">print(response.output_text)\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"TypeScript","html":"\u003cpre class=\"shiki shiki-themes dark-plus dark-plus\" style=\"background-color:#0B0C0E;--shiki-dark-bg:#0B0C0E;color:#D4D4D4;--shiki-dark:#D4D4D4\" language=\"typescript\">\u003ccode language=\"typescript\" numberOfLines=\"13\">\u003cspan class=\"line\">\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">import\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> OpenAI \u003c/span>\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">from\u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\"> \"openai\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">;\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">const\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> client = \u003c/span>\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">new\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> OpenAI({\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> apiKey: process.env.REQUESTY_API_KEY,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> baseURL: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"https://router.requesty.ai/v1\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">});\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">const\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> response = \u003c/span>\u003cspan style=\"color:#C586C0;--shiki-dark:#C586C0\">await\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> client.responses.create({\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> model: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"openai-responses/gpt-5\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> input: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"Tell me a three sentence bedtime story about a unicorn.\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">});\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">console.log(response.output_text);\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]},"response":{"type":"ResponseExample","children":[{"filename":"Response 200","html":"\u003cpre class=\"shiki shiki-themes dark-plus dark-plus\" style=\"background-color:#0B0C0E;--shiki-dark-bg:#0B0C0E;color:#D4D4D4;--shiki-dark:#D4D4D4\" language=\"json\">\u003ccode language=\"json\" numberOfLines=\"23\">\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">{\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"id\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"resp_abc123\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"object\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"response\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"created_at\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#B5CEA8;--shiki-dark:#B5CEA8\">1748200000\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"model\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"openai-responses/gpt-5\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"output\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"type\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"message\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"role\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"assistant\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"content\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: [\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"type\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"output_text\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"text\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#CE9178;--shiki-dark:#CE9178\">\"Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come.\"\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> ]\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> ],\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"usage\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"input_tokens\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#B5CEA8;--shiki-dark:#B5CEA8\">15\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"output_tokens\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#B5CEA8;--shiki-dark:#B5CEA8\">58\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">,\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#9CDCFE;--shiki-dark:#9CDCFE\"> \"total_tokens\"\u003c/span>\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">: \u003c/span>\u003cspan style=\"color:#B5CEA8;--shiki-dark:#B5CEA8\">73\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\"> }\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#D4D4D4;--shiki-dark:#D4D4D4\">}\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]}}},"jsLinks":[],"openApiReferenceData":{"operation":{"summary":"Create response","description":"Send input to an OpenAI-compatible model using the Responses API format and receive a response.","security":["43ba1bff-3889-47a2-b9eb-cf1531e712a8"],"parameters":["98f6584c-c2e7-468d-8f13-e0aabb4b57fe"],"requestBody":"d64a7383-f080-4884-b4a1-646f8bce790c","responses":{"200":"df5dae81-05be-416d-a9fc-f10aa7cd8a7e","400":"ca643bde-b35c-44f0-b23b-32835a23baa2","401":"558b709c-c8da-4363-bb34-622f690a9143","402":"ad0f312a-68c2-4a00-ad16-bb264e0a7c82","403":"38b3c728-8cc3-4114-84d7-1adb3532cb50","404":"7ed95926-c136-40f5-8638-8987dfc71c4c","413":"759e3642-22df-4417-b2a8-46d22d64d386","429":"baeb613c-5834-43f1-ab73-7a8332309bd5","500":"4505370b-1425-4b13-8091-913effc201c5","502":"acdee571-6daa-4f96-99af-588887546b6e"},"operationId":"createResponse","method":"post","type":"path","servers":["aea184ed-f26b-42a1-bc5b-ad73fe837c9b"],"path":"/v1/responses","baseUrlOptions":["https://router.requesty.ai"],"title":"Create response","codeSamples":[],"requiredOnlyExamples":false,"requestExamples":[{"dropdown":false,"language":"shellscript","code":{"type":"pre","key":null,"ref":null,"props":{"className":"shiki shiki-themes dark-plus dark-plus","style":{"backgroundColor":"#0B0C0E","--shiki-dark-bg":"#0B0C0E","color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"language":"shellscript","children":{"type":"code","key":null,"ref":null,"props":{"language":"shellscript","numberOfLines":"7","children":[{"type":"span","key":"0","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#DCDCAA","--shiki-dark":"#DCDCAA"},"children":"curl"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" https://router.requesty.ai/v1/responses \\"}}]}},"\n",{"type":"span","key":"2","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" -H "}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"Content-Type: application/json\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" \\"}}]}},"\n",{"type":"span","key":"4","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" -H "}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"Authorization: Bearer YOUR_REQUESTY_API_KEY\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" \\"}}]}},"\n",{"type":"span","key":"6","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" -d "}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"'{"}}]}},"\n",{"type":"span","key":"8","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":" \"model\": \"openai-responses/gpt-5\","}}}},"\n",{"type":"span","key":"10","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":" \"input\": \"Tell me a three sentence bedtime story about a unicorn.\""}}}},"\n",{"type":"span","key":"12","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":" }'"}}}},"\n"]}}}},"filename":"cURL"},{"dropdown":false,"language":"python","code":{"type":"pre","key":null,"ref":null,"props":{"className":"shiki shiki-themes dark-plus dark-plus","style":{"backgroundColor":"#0B0C0E","--shiki-dark-bg":"#0B0C0E","color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"language":"python","children":{"type":"code","key":null,"ref":null,"props":{"language":"python","numberOfLines":"13","children":[{"type":"span","key":"0","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"from"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" openai "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"import"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" OpenAI"}}]}},"\n",{"type":"span","key":"2","ref":null,"props":{"className":"line","children":null}},"\n",{"type":"span","key":"4","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"client = OpenAI("}}}},"\n",{"type":"span","key":"6","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" api_key="}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"YOUR_REQUESTY_API_KEY\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"8","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" base_url="}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"https://router.requesty.ai/v1\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"10","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":")"}}}},"\n",{"type":"span","key":"12","ref":null,"props":{"className":"line","children":null}},"\n",{"type":"span","key":"14","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"response = client.responses.create("}}}},"\n",{"type":"span","key":"16","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" model="}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"openai-responses/gpt-5\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"18","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" input="}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"Tell me a three sentence bedtime story about a unicorn.\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"20","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":")"}}}},"\n",{"type":"span","key":"22","ref":null,"props":{"className":"line","children":null}},"\n",{"type":"span","key":"24","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"print(response.output_text)"}}}},"\n"]}}}},"filename":"Python"},{"dropdown":false,"language":"typescript","code":{"type":"pre","key":null,"ref":null,"props":{"className":"shiki shiki-themes dark-plus dark-plus","style":{"backgroundColor":"#0B0C0E","--shiki-dark-bg":"#0B0C0E","color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"language":"typescript","children":{"type":"code","key":null,"ref":null,"props":{"language":"typescript","numberOfLines":"13","children":[{"type":"span","key":"0","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"import"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" OpenAI "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"from"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":" \"openai\""}},{"type":"span","key":"4","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":";"}}]}},"\n",{"type":"span","key":"2","ref":null,"props":{"className":"line","children":null}},"\n",{"type":"span","key":"4","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"const"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" client = "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"new"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" OpenAI({"}}]}},"\n",{"type":"span","key":"6","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" apiKey: process.env.REQUESTY_API_KEY,"}}}},"\n",{"type":"span","key":"8","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" baseURL: "}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"https://router.requesty.ai/v1\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"10","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"});"}}}},"\n",{"type":"span","key":"12","ref":null,"props":{"className":"line","children":null}},"\n",{"type":"span","key":"14","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"const"}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" response = "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#C586C0","--shiki-dark":"#C586C0"},"children":"await"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" client.responses.create({"}}]}},"\n",{"type":"span","key":"16","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" model: "}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"openai-responses/gpt-5\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"18","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" input: "}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"Tell me a three sentence bedtime story about a unicorn.\""}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"20","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"});"}}}},"\n",{"type":"span","key":"22","ref":null,"props":{"className":"line","children":null}},"\n",{"type":"span","key":"24","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"console.log(response.output_text);"}}}},"\n"]}}}},"filename":"TypeScript"}],"requestExampleType":"mdx","responseExamples":[{"dropdown":false,"language":"json","code":{"type":"pre","key":null,"ref":null,"props":{"className":"shiki shiki-themes dark-plus dark-plus","style":{"backgroundColor":"#0B0C0E","--shiki-dark-bg":"#0B0C0E","color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"language":"json","children":{"type":"code","key":null,"ref":null,"props":{"language":"json","numberOfLines":"23","children":[{"type":"span","key":"0","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"{"}}}},"\n",{"type":"span","key":"2","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"id\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"resp_abc123\""}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"4","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"object\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"response\""}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"6","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"created_at\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#B5CEA8","--shiki-dark":"#B5CEA8"},"children":"1748200000"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"8","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"model\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"openai-responses/gpt-5\""}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"10","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"output\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": ["}}]}},"\n",{"type":"span","key":"12","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" {"}}}},"\n",{"type":"span","key":"14","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"type\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"message\""}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"16","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"role\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"assistant\""}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"18","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"content\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": ["}}]}},"\n",{"type":"span","key":"20","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" {"}}}},"\n",{"type":"span","key":"22","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"type\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"output_text\""}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"24","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"text\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#CE9178","--shiki-dark":"#CE9178"},"children":"\"Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come.\""}}]}},"\n",{"type":"span","key":"26","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" }"}}}},"\n",{"type":"span","key":"28","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" ]"}}}},"\n",{"type":"span","key":"30","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" }"}}}},"\n",{"type":"span","key":"32","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" ],"}}}},"\n",{"type":"span","key":"34","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"usage\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": {"}}]}},"\n",{"type":"span","key":"36","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"input_tokens\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#B5CEA8","--shiki-dark":"#B5CEA8"},"children":"15"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"38","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"output_tokens\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#B5CEA8","--shiki-dark":"#B5CEA8"},"children":"58"}},{"type":"span","key":"3","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":","}}]}},"\n",{"type":"span","key":"40","ref":null,"props":{"className":"line","children":[{"type":"span","key":"0","ref":null,"props":{"style":{"color":"#9CDCFE","--shiki-dark":"#9CDCFE"},"children":" \"total_tokens\""}},{"type":"span","key":"1","ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":": "}},{"type":"span","key":"2","ref":null,"props":{"style":{"color":"#B5CEA8","--shiki-dark":"#B5CEA8"},"children":"73"}}]}},"\n",{"type":"span","key":"42","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":" }"}}}},"\n",{"type":"span","key":"44","ref":null,"props":{"className":"line","children":{"type":"span","key":null,"ref":null,"props":{"style":{"color":"#D4D4D4","--shiki-dark":"#D4D4D4"},"children":"}"}}}},"\n"]}}}},"filename":"Response 200"}],"responseExampleType":"mdx"},"dependencies":{"parameters":{"98f6584c-c2e7-468d-8f13-e0aabb4b57fe":{"name":"x-api-key","in":"header","required":false,"schema":{"type":"string","isRequired":false,"description":"Your Requesty API key. Alternative to the standard `Authorization: Bearer` header.","uniqueKey":"","typeLabel":"string"},"description":"Your Requesty API key. Alternative to the standard `Authorization: Bearer` header."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["model","input"],"properties":{"model":{"type":"string","description":"The model to use for the response. To route OpenAI models through their native Responses API, use the `openai-responses/` prefix (e.g. `openai-responses/gpt-5`).","default":"openai-responses/gpt-5","example":"openai-responses/gpt-5","isRequired":true,"uniqueKey":"model","typeLabel":"string"},"input":{"oneOf":[{"type":"string","description":"Text, image, or file inputs to the model. Either a plain string or an array of typed input items.","example":"Tell me a three sentence bedtime story about a unicorn.","isRequired":true,"uniqueKey":"input.oneOf.0","typeLabel":"string"},{"type":"array","items":{"type":"object","description":"Typed input item. Use `type=message` for chat turns, `function_call` to replay a tool call, and `function_call_output` to provide a tool result.","properties":{"type":{"type":"string","enum":["message","reasoning","function_call","function_call_output"],"uniqueKey":"input.oneOf.1.items.[INDEX].type","typeLabel":"enum\u003cstring>"},"role":{"type":"string","enum":["user","assistant","system","developer"],"description":"For `type=message`: the role of the message author.","uniqueKey":"input.oneOf.1.items.[INDEX].role","typeLabel":"enum\u003cstring>"},"content":{"oneOf":[{"type":"string","description":"For `type=message`: a string or an array of typed content objects.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.0","typeLabel":"string"},{"type":"array","items":{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["input_text","input_image","input_file"],"isRequired":true,"uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].type","typeLabel":"enum\u003cstring>"},"text":{"type":"string","description":"For `type=input_text`: the text content.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].text","typeLabel":"string"},"image_url":{"type":"string","description":"For `type=input_image`: an https:// URL or `data:` URL.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].image_url","typeLabel":"string"},"detail":{"type":"string","enum":["low","high","auto"],"description":"For `type=input_image`: image fidelity.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].detail","typeLabel":"enum\u003cstring>"},"filename":{"type":"string","description":"For `type=input_file`: name of the file.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].filename","typeLabel":"string"},"file_data":{"type":"string","description":"For `type=input_file`: base64 data URL, e.g. `data:application/pdf;base64,...`.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].file_data","typeLabel":"string"},"file_url":{"type":"string","description":"For `type=input_file`: remote URL of the file.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].file_url","typeLabel":"string"},"mime_type":{"type":"string","description":"For `type=input_file`: optional MIME type override.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX].mime_type","typeLabel":"string"}},"uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1.items.[INDEX]","typeLabel":"object"},"description":"For `type=message`: a string or an array of typed content objects.","uniqueKey":"input.oneOf.1.items.[INDEX].content.oneOf.1","typeLabel":"object[]"}],"uniqueKey":"input.oneOf.1.items.[INDEX].content","typeLabel":"string | object[]"},"name":{"type":"string","description":"For `type=function_call`: the function name.","uniqueKey":"input.oneOf.1.items.[INDEX].name","typeLabel":"string"},"arguments":{"type":"string","description":"For `type=function_call`: JSON-encoded arguments string.","uniqueKey":"input.oneOf.1.items.[INDEX].arguments","typeLabel":"string"},"call_id":{"type":"string","description":"For `type=function_call` and `function_call_output`: identifier linking call and result.","uniqueKey":"input.oneOf.1.items.[INDEX].call_id","typeLabel":"string"},"output":{"type":"string","description":"For `type=function_call_output`: the result returned to the model.","uniqueKey":"input.oneOf.1.items.[INDEX].output","typeLabel":"string"}},"uniqueKey":"input.oneOf.1.items.[INDEX]","typeLabel":"object"},"description":"Text, image, or file inputs to the model. Either a plain string or an array of typed input items.","isRequired":true,"uniqueKey":"input.oneOf.1","typeLabel":"object[]"}],"isRequired":true,"uniqueKey":"input","typeLabel":"string | object[]"},"instructions":{"type":"string","description":"Inserts a system (or developer) message as the first item in the model's context.","uniqueKey":"instructions","typeLabel":"string"},"max_output_tokens":{"type":"integer","minimum":1,"description":"Upper bound for the number of tokens that can be generated, including visible output tokens and reasoning tokens.","uniqueKey":"max_output_tokens","typeLabel":"integer"},"stream":{"type":"boolean","description":"If true, the response is streamed to the client as it is generated using server-sent events.","uniqueKey":"stream","typeLabel":"boolean"},"temperature":{"type":"number","minimum":0,"maximum":2,"description":"Sampling temperature between 0 and 2. Higher values produce more random output.","uniqueKey":"temperature","typeLabel":"number"},"top_p":{"type":"number","minimum":0,"maximum":1,"description":"Nucleus sampling: consider tokens with cumulative probability mass up to top_p.","uniqueKey":"top_p","typeLabel":"number"},"parallel_tool_calls":{"type":"boolean","description":"Whether to allow the model to run tool calls in parallel.","uniqueKey":"parallel_tool_calls","typeLabel":"boolean"},"tool_choice":{"oneOf":[{"type":"string","description":"Controls which (if any) tool is called by the model.","enum":["auto","none","required"],"uniqueKey":"tool_choice.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"object","description":"Controls which (if any) tool is called by the model.","uniqueKey":"tool_choice.oneOf.1","typeLabel":"object"}],"uniqueKey":"tool_choice","typeLabel":"enum\u003cstring> | object"},"tools":{"type":"array","items":{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["function","web_search"],"isRequired":true,"uniqueKey":"tools.items.[INDEX].type","typeLabel":"enum\u003cstring>"},"name":{"type":"string","description":"For `type=function`: the function name.","uniqueKey":"tools.items.[INDEX].name","typeLabel":"string"},"description":{"type":"string","description":"For `type=function`: a description of when to call the function.","uniqueKey":"tools.items.[INDEX].description","typeLabel":"string"},"parameters":{"type":"object","description":"For `type=function`: JSON Schema describing the arguments.","uniqueKey":"tools.items.[INDEX].parameters","typeLabel":"object"},"strict":{"type":"boolean","description":"For `type=function`: when true, the model must produce arguments that exactly match the schema.","uniqueKey":"tools.items.[INDEX].strict","typeLabel":"boolean"}},"uniqueKey":"tools.items.[INDEX]","typeLabel":"object"},"description":"Tools the model may call.","uniqueKey":"tools","typeLabel":"object[]"},"reasoning":{"type":"object","description":"Reasoning configuration for reasoning-capable models.","properties":{"effort":{"type":"string","enum":["low","medium","high"],"description":"How much effort the model should spend on reasoning. Defaults to medium.","uniqueKey":"reasoning.effort","typeLabel":"enum\u003cstring>"},"summary":{"type":"string","enum":["auto","concise","detailed"],"description":"Whether and how to summarize the reasoning trace.","uniqueKey":"reasoning.summary","typeLabel":"enum\u003cstring>"}},"uniqueKey":"reasoning","typeLabel":"object"},"text":{"type":"object","description":"Output text configuration, including structured output format.","properties":{"format":{"type":"object","description":"Configure the format that the model must output. Set `{ \"type\": \"json_schema\" }` for strict structured outputs, or `{ \"type\": \"text\" }` (default) for plain text.","properties":{"type":{"type":"string","enum":["text","json_object","json_schema"],"uniqueKey":"text.format.type","typeLabel":"enum\u003cstring>"},"name":{"type":"string","description":"For `type=json_schema`: schema name.","uniqueKey":"text.format.name","typeLabel":"string"},"strict":{"type":"boolean","description":"For `type=json_schema`: enforce strict schema validation.","uniqueKey":"text.format.strict","typeLabel":"boolean"},"schema":{"type":"object","description":"For `type=json_schema`: the JSON Schema document.","uniqueKey":"text.format.schema","typeLabel":"object"}},"uniqueKey":"text.format","typeLabel":"object"}},"uniqueKey":"text","typeLabel":"object"},"include":{"type":"array","items":{"type":"string","uniqueKey":"include.items.[INDEX]","typeLabel":"string"},"description":"Specify additional output data to include in the model response.","uniqueKey":"include","typeLabel":"string[]"},"metadata":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"metadata.additionalProperties","typeLabel":"string"},"description":"Set of key-value pairs that can be attached to the request.","uniqueKey":"metadata","typeLabel":"object"},"store":{"type":"boolean","description":"Whether to store the generated model response for later retrieval via API.","uniqueKey":"store","typeLabel":"boolean"},"truncation":{"type":"string","description":"The truncation strategy to use for the model response.","uniqueKey":"truncation","typeLabel":"string"},"user":{"type":"string","description":"A unique identifier representing your end-user.","uniqueKey":"user","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"model":"openai-responses/gpt-5","input":"Tell me a three sentence bedtime story about a unicorn."},"examples":{"Example":{"title":"Example","value":{"model":"openai-responses/gpt-5","input":"Tell me a three sentence bedtime story about a unicorn."}}},"exampleType":"examples"}},"exampleType":"examples"},"responses":{"df5dae81-05be-416d-a9fc-f10aa7cd8a7e":{"description":"Response","content":{"application/json":{"schema":{"type":"object","required":["id","object","created_at","model","status","output"],"properties":{"id":{"type":"string","description":"Unique identifier for this response.","isRequired":true,"uniqueKey":"id","typeLabel":"string"},"object":{"type":"string","enum":["response"],"description":"Object type.","isRequired":true,"uniqueKey":"object","typeLabel":"enum\u003cstring>"},"created_at":{"type":"integer","description":"Unix timestamp (in seconds) of when the response was created.","isRequired":true,"uniqueKey":"created_at","typeLabel":"integer"},"model":{"type":"string","description":"Model ID used to generate the response.","isRequired":true,"uniqueKey":"model","typeLabel":"string"},"status":{"type":"string","enum":["completed","failed","in_progress","incomplete"],"description":"Status of the response generation.","isRequired":true,"uniqueKey":"status","typeLabel":"enum\u003cstring>"},"output":{"type":"array","items":{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["message","reasoning","function_call","web_search_call"],"isRequired":true,"uniqueKey":"output.items.[INDEX].type","typeLabel":"enum\u003cstring>"},"id":{"type":"string","uniqueKey":"output.items.[INDEX].id","typeLabel":"string"},"status":{"type":"string","enum":["in_progress","completed"],"uniqueKey":"output.items.[INDEX].status","typeLabel":"enum\u003cstring>"},"role":{"type":"string","enum":["assistant"],"description":"For `type=message`.","uniqueKey":"output.items.[INDEX].role","typeLabel":"enum\u003cstring>"},"content":{"type":"array","items":{"type":"object","required":["type"],"properties":{"type":{"type":"string","enum":["output_text","output_refusal"],"isRequired":true,"uniqueKey":"output.items.[INDEX].content.items.[INDEX].type","typeLabel":"enum\u003cstring>"},"text":{"type":"string","description":"For `type=output_text`: the generated text.","uniqueKey":"output.items.[INDEX].content.items.[INDEX].text","typeLabel":"string"},"refusal":{"type":"string","description":"For `type=output_refusal`: the refusal message.","uniqueKey":"output.items.[INDEX].content.items.[INDEX].refusal","typeLabel":"string"}},"uniqueKey":"output.items.[INDEX].content.items.[INDEX]","typeLabel":"object"},"description":"For `type=message`: model-generated content blocks.","uniqueKey":"output.items.[INDEX].content","typeLabel":"object[]"},"summary":{"type":"array","description":"For `type=reasoning`: optional summary of the reasoning trace.","uniqueKey":"output.items.[INDEX].summary","typeLabel":"array"},"encrypted_content":{"type":"string","description":"For `type=reasoning`: opaque token that can be replayed on subsequent turns.","uniqueKey":"output.items.[INDEX].encrypted_content","typeLabel":"string"},"name":{"type":"string","description":"For `type=function_call`: the function name.","uniqueKey":"output.items.[INDEX].name","typeLabel":"string"},"arguments":{"type":"string","description":"For `type=function_call`: JSON-encoded arguments string.","uniqueKey":"output.items.[INDEX].arguments","typeLabel":"string"},"call_id":{"type":"string","description":"For `type=function_call`: identifier to pair with a `function_call_output`.","uniqueKey":"output.items.[INDEX].call_id","typeLabel":"string"}},"uniqueKey":"output.items.[INDEX]","typeLabel":"object"},"description":"Output items from the model. Typically one or more `message`, `function_call`, or `reasoning` items.","isRequired":true,"uniqueKey":"output","typeLabel":"object[]"},"incomplete_details":{"type":"object","properties":{"reason":{"type":"string","description":"Why the response is incomplete.","uniqueKey":"incomplete_details.reason","typeLabel":"string"}},"uniqueKey":"incomplete_details","typeLabel":"object"},"error":{"type":"object","properties":{"code":{"type":"string","uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","uniqueKey":"error.message","typeLabel":"string"}},"uniqueKey":"error","typeLabel":"object"},"usage":{"type":"object","required":["input_tokens","output_tokens","total_tokens"],"properties":{"input_tokens":{"type":"integer","isRequired":true,"uniqueKey":"usage.input_tokens","typeLabel":"integer"},"output_tokens":{"type":"integer","isRequired":true,"uniqueKey":"usage.output_tokens","typeLabel":"integer"},"total_tokens":{"type":"integer","isRequired":true,"uniqueKey":"usage.total_tokens","typeLabel":"integer"},"input_tokens_details":{"type":"object","properties":{"cached_tokens":{"type":"integer","uniqueKey":"usage.input_tokens_details.cached_tokens","typeLabel":"integer"}},"uniqueKey":"usage.input_tokens_details","typeLabel":"object"},"output_tokens_details":{"type":"object","properties":{"reasoning_tokens":{"type":"integer","uniqueKey":"usage.output_tokens_details.reasoning_tokens","typeLabel":"integer"}},"uniqueKey":"usage.output_tokens_details","typeLabel":"object"},"cost":{"type":"number","format":"float","description":"Requesty's USD cost for this request. Returned by default on non-streaming responses. For streaming, the final `response.completed` event includes `usage` with `cost`.","uniqueKey":"usage.cost","typeLabel":"number\u003cfloat>"}},"uniqueKey":"usage","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"example":{"id":"resp_abc123","object":"response","created_at":1748200000,"model":"openai-responses/gpt-5","output":[{"type":"message","role":"assistant","content":[{"type":"output_text","text":"Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come."}]}],"usage":{"input_tokens":15,"output_tokens":58,"total_tokens":73}},"examples":{"Example":{"title":"Example","value":{"id":"resp_abc123","object":"response","created_at":1748200000,"model":"openai-responses/gpt-5","output":[{"type":"message","role":"assistant","content":[{"type":"output_text","text":"Once upon a time, a tiny unicorn named Sparkle discovered a rainbow bridge leading to a hidden meadow. She danced under the stars with fireflies until the moon sang her a lullaby. And every night after, Sparkle dreamed of adventures yet to come."}]}],"usage":{"input_tokens":15,"output_tokens":58,"total_tokens":73}}}},"exampleType":"examples"}},"exampleType":"examples"},"ca643bde-b35c-44f0-b23b-32835a23baa2":{"description":"Bad request - malformed payload or invalid parameters.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"558b709c-c8da-4363-bb34-622f690a9143":{"description":"Unauthorized - missing or empty Authorization header.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"ad0f312a-68c2-4a00-ad16-bb264e0a7c82":{"description":"Payment required - organization balance exhausted.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"38b3c728-8cc3-4114-84d7-1adb3532cb50":{"description":"Forbidden - invalid token or model not in access list.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"7ed95926-c136-40f5-8638-8987dfc71c4c":{"description":"Not found - provider/model not supported.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"759e3642-22df-4417-b2a8-46d22d64d386":{"description":"Payload too large - the request body exceeds the 50 MB limit. Send fewer or smaller images and files, or compact the conversation history.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"baeb613c-5834-43f1-ab73-7a8332309bd5":{"description":"Rate limit exceeded. Retry after the Retry-After header value.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"4505370b-1425-4b13-8091-913effc201c5":{"description":"Internal server error.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"},"acdee571-6daa-4f96-99af-588887546b6e":{"description":"Bad gateway - upstream provider returned an invalid response.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["origin","message"],"properties":{"origin":{"type":"string","enum":["router","provider"],"description":"Whether the error originated from Requesty's router or an upstream provider.","isRequired":true,"uniqueKey":"error.origin","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error description.","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":{"origin":"router","message":"\u003cstring>"}}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"43ba1bff-3889-47a2-b9eb-cf1531e712a8":{"bearerAuth":{"$ref":"7ad52b8e-f139-48a2-9141-f40c452eb034","scopes":[]}}},"servers":{"aea184ed-f26b-42a1-bc5b-ad73fe837c9b":{"url":"https://router.requesty.ai","description":"Inference router endpoint"}}},"originalFileLocation":"api-reference/openapi.json"},"subdomain":"requesty","siteName":"Requesty Docs","title":"Create Response - Requesty Docs","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-03T18:07:59.964Z","gitLastModified":"2026-11-03T18:06:45.000Z","originalFileLocation":"api-reference/endpoint/responses-create.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=\"dark\"}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=\"Send input to an OpenAI-compatible model using the Responses API format and receive a response.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Requesty Docs\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_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/requesty/bWQG6e3TK2khNMP8/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Create Response - Requesty Docs\">\u003cmeta data-mint-head property=\"og:description\" content=\"Send input to an OpenAI-compatible model using the Responses API format and receive a response.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Requesty Docs\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.requesty.ai/api-reference/endpoint/responses-create\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://requesty.mintlify.site/_mintlify/api/og/v2?division=Inference+APIs\u0026amp;title=Create+Response\u0026amp;description=Send+input+to+an+OpenAI-compatible+model+using+the+Responses+API+format+and+receive+a+response.\u0026amp;theme=a48e85110015de94690ebb47\u0026amp;signature=5c5d31492ef8305d6cd08c838a56c8d24302a2ea24df88212f232daf38e28a0c\">\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 Response - Requesty Docs\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Send input to an OpenAI-compatible model using the Responses API format and receive a response.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://requesty.mintlify.site/_mintlify/api/og/v2?division=Inference+APIs\u0026amp;title=Create+Response\u0026amp;description=Send+input+to+an+OpenAI-compatible+model+using+the+Responses+API+format+and+receive+a+response.\u0026amp;theme=a48e85110015de94690ebb47\u0026amp;signature=5c5d31492ef8305d6cd08c838a56c8d24302a2ea24df88212f232daf38e28a0c\">\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/requesty/bWQG6e3TK2khNMP8/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Requesty Docs\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#C8956A\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.requesty.ai/api-reference/endpoint/responses-create\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/endpoint/responses-create.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.requesty.ai/#organization\",\"name\":\"Requesty Docs\",\"url\":\"https://docs.requesty.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/requesty/o8v2COiz3OtlSbqG/logo/light.svg?fit=max\u0026auto=format\u0026n=o8v2COiz3OtlSbqG\u0026q=85\u0026s=33d22576c8ec4d1e68f24969181684df\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.requesty.ai#website\",\"name\":\"Requesty Docs\",\"url\":\"https://docs.requesty.ai\",\"publisher\":{\"@id\":\"https://docs.requesty.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create#webpage\",\"url\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create\",\"name\":\"Create Response\",\"description\":\"Send input to an OpenAI-compatible model using the Responses API format and receive a response.\",\"dateModified\":\"2026-11-03T18:06:45.000Z\",\"isPartOf\":{\"@id\":\"https://docs.requesty.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Inference APIs\",\"item\":\"https://docs.requesty.ai/api-reference/inference-apis\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create Response\",\"item\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create#apireference\",\"headline\":\"Create Response\",\"name\":\"Create Response\",\"description\":\"Send input to an OpenAI-compatible model using the Responses API format and receive a response.\",\"url\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create\",\"mainEntityOfPage\":{\"@id\":\"https://docs.requesty.ai/api-reference/endpoint/responses-create#webpage\"},\"dateModified\":\"2026-11-03T18:06:45.000Z\",\"publisher\":{\"@id\":\"https://docs.requesty.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.requesty.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Requesty Docs\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"Requesty Docs\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/endpoint/responses-create.md","siteName":"Requesty Docs","nav":{"global":null,"tabs":[{"tab":"Gateway","pages":[{"title":"Gateway","href":"/quickstart"}]},{"tab":"Integrations","pages":[{"title":"Integrations","href":"/integrations/requesty-cli"}]},{"tab":"Inference API","groups":[{"group":"Inference APIs","pages":[{"title":"Overview","href":"/api-reference/inference-apis"},{"title":"Create Chat Completion","openapi":"POST /v1/chat/completions","href":"/api-reference/endpoint/chat-completions-create"},{"title":"Create Message","openapi":"POST /v1/messages","description":"Send a message to an Anthropic-compatible model and receive a response","href":"/api-reference/endpoint/messages-create"},{"title":"Create Response","openapi":"POST /v1/responses","href":"/api-reference/endpoint/responses-create"},{"title":"Create Embedding","openapi":"POST /v1/embeddings","description":"Create vector embeddings for text input using embedding models.","href":"/api-reference/endpoint/embeddings-create"},{"title":"Create Speech","openapi":"POST /v1/audio/speech","href":"/api-reference/endpoint/audio-speech-create"},{"title":"Create Transcription","openapi":"POST /v1/audio/transcriptions","href":"/api-reference/endpoint/audio-transcriptions-create"},{"title":"Create Image","openapi":"POST /v1/images/generations","href":"/api-reference/endpoint/images-generations-create"},{"title":"Edit Image","openapi":"POST /v1/images/edits","href":"/api-reference/endpoint/images-edits-create"},{"title":"Create Decision","openapi":"POST /v1/decisions","href":"/api-reference/endpoint/decisions-create"},{"title":"Create System One Decision","openapi":"POST /v1/systemone","href":"/api-reference/endpoint/systemone-create"},{"title":"List All Models","openapi":"GET /v1/models/all","href":"/api-reference/endpoint/models-all-list"},{"title":"List Models","openapi":"GET /v1/models","href":"/api-reference/endpoint/models-list"},{"title":"List Chat Models","openapi":"GET /v1/models/chat","href":"/api-reference/endpoint/models-chat-list"},{"title":"List Embedding Models","openapi":"GET /v1/models/embedding","href":"/api-reference/endpoint/models-embedding-list"},{"title":"List Image Models","openapi":"GET /v1/models/image","href":"/api-reference/endpoint/models-image-list"},{"title":"List Transcription Models","openapi":"GET /v1/models/transcription","href":"/api-reference/endpoint/models-transcription-list"},{"title":"List Speech Models","openapi":"GET /v1/models/speech","href":"/api-reference/endpoint/models-speech-list"},{"title":"List Decision Models","openapi":"GET /v1/models/decision","href":"/api-reference/endpoint/models-decision-list"},{"title":"List Managed Policies","openapi":"GET /v1/models/managed","href":"/api-reference/endpoint/models-managed-list"},{"title":"OpenAPI Spec","icon":"download","href":"/api-reference/openapi-inference-spec"}]}]},{"tab":"Management API","pages":[{"title":"Management API","href":"/api-reference/management-apis"}]}]},"basePath":"","title":"Create Response - Requesty Docs","buildId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","deploymentId":"dpl_DqYu5MPb49gWBBbUGgpHQUmCHY3P","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-CybtLBIt.js","utils-BMLj2fvV.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-B6In562Y.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-Dr8Mfhp9.js","snippetPresets-2rmQvMVl.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-WMqJYdZj.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CJ-MlPHu.js","shallow-dY3TMRCk.js","getApiPlaygroundDisplay-v-1B2bKm.js","CodeSnippet-BDhiTB7U.js","CodeSnippets-D9hnzQcS.js","Page-C4GwDT3_.js","getPastedJson-Th2V45jI.js","icon-BQXch1W9.js","MethodPill-BCqUneP3.js","DuplicateIcon-Q_-bhurZ.js","createIcon-DUjLHRqp.js","DynamicMarkdown-B-f2cqXQ.js","SectionHeading-Da5NsV4v.js","axios-vUo_bRtp.js","Markdown-D13FWkIM.js","clsx-D3Isdib3.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-C-XZBk9h.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink--qIqmmVG.js"]}