Skip to main content
POST
Create a response (OpenAI Responses API)

Authorizations

Authorization
string
header
required

Gateway API key (imp-rt-...) from POST /v1/accounts or /v1/keys.

Body

application/json
model
string
required
Example:

"anthropic/claude-sonnet-4-5"

input
required
instructions
string
stream
boolean
default:false
temperature
number
top_p
number
max_output_tokens
integer
reasoning
object

Stateless reasoning control. summary and stateful response chaining are not supported.

tools
object[]

Function tools the model may call (relay mode). Function fields are flattened onto the tool.

tool_choice

auto, none, required, or { type: function, name }.

Available options:
auto,
none,
required

Response

A response object. When stream: true, the body is instead an SSE stream of response.* semantic events ending with response.completed.

Responses API object (response).

id
string
Example:

"resp_..."

object
string
Allowed value: "response"
created_at
integer
status
enum<string>
Available options:
in_progress,
completed,
failed
model
string
output_text
string

Convenience aggregation of the assistant text.

output
object[]

Output items — assistant message items and, on tool calls, function_call items.

usage
object