responses

Create a response.

Generate a model response from text or image inputs. The response can include text, reasoning, and function calls. Set stream to true to receive Server-Sent Events.

For multi-turn conversations, send the full history in input, including prior output items and function results. Responses are not stored. Only client-executed function tools are supported.

post/v1/responses

Request

Request body

modelstring required
instructionsstring nullable
parallel_tool_callsboolean
previous_response_idunknown
truncation'disabled'
conversationunknown
promptunknown
backgroundfalse
streamboolean
storefalse nullable
max_output_tokensinteger nullable
temperaturenumber nullable
top_pnumber nullable
metadataobject nullable
prompt_cache_keystring nullable
max_tool_callsinteger nullable
moderationunknown
top_logprobs0 nullable

Response

Successful Response

idstring required
created_atnumber required
instructionsstring nullable
metadataobject nullable
modelstring required
object'response' required
parallel_tool_callsboolean required
temperaturenumber nullable
top_pnumber nullable
backgroundboolean nullable
completed_atnumber nullable
max_output_tokensinteger nullable
max_tool_callsinteger nullable
previous_response_idstring nullable
prompt_cache_keystring nullable
prompt_cache_retention'in_memory' | '24h' nullable
safety_identifierstring nullable
service_tier'auto' | 'default' | 'flex' | 'scale' | 'priority' nullable
status'completed' | 'failed' | 'in_progress' | 'cancelled' | 'queued' | 'incomplete' nullable
top_logprobsinteger nullable
truncation'auto' | 'disabled' nullable
userstring nullable

Changes