Create Model Response
Authentication
Basic Request
Response Format
Multi-Turn Conversation
Use theinput array to pass conversation history:
Python
Streaming Request
Streaming Event Types
| Event Type | Description |
|---|---|
response.created | Response created |
response.in_progress | Response processing |
response.output_item.added | New output item added |
response.content_part.added | New content block added |
response.output_text.delta | Text increment |
response.output_text.done | Text complete |
response.content_part.done | Content block complete |
response.output_item.done | Output item complete |
response.completed | Response complete |
Thinking Control
Use thereasoning parameter to control reasoning depth:
Python
reasoning Parameter
| Field | Type | Description |
|---|---|---|
effort | string | Reasoning depth: low, medium, high |
summary | string | Thinking summary mode: auto, concise, detailed |
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Model name |
input | string|array | Yes | Input content or message list |
stream | boolean | No | Whether to stream output |
temperature | number | No | Sampling temperature |
max_output_tokens | integer | No | Maximum output tokens |
tools | array | No | Available tools list |
reasoning | object | No | Reasoning control |
instructions | string | No | System instructions (similar to system message) |
The Responses API’s
input parameter can be either a simple string or a message array, providing more flexibility.