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
cache_control
object

Request-level breakpoint; same contract as on ChatCompletionRequest. A per-part cache_control anywhere takes precedence and this is ignored.

Response

A response object. When stream: true, the body is instead an SSE stream of response.* semantic events ending with response.completed, or response.incomplete when generation stopped short (see status).

Responses API object (response).

id
string
Example:

"resp_..."

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

Why generation stopped short. Present only when status is incomplete.

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