5611 5611
5612- `model: optional "gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more or string`5612- `model: optional "gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more or string`
5613 5613
5614 Model ID used to generate the response, like `gpt-6-astra`. OpenAI5614 Model ID used to generate the response, like `gpt-6.2-astra`. OpenAI
5615 offers a wide range of models with different capabilities, performance5615 offers a wide range of models with different capabilities, performance
5616 characteristics, and price points. Refer to the [model guide](/api/docs/models)5616 characteristics, and price points. Refer to the [model guide](/api/docs/models)
5617 to browse and compare available models.5617 to browse and compare available models.
5618 5618
5619 - `"gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more`5619 - `"gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more`
5620 5620
5621 Model ID used to generate the response, like `gpt-6-astra`. OpenAI5621 Model ID used to generate the response, like `gpt-6.2-astra`. OpenAI
5622 offers a wide range of models with different capabilities, performance5622 offers a wide range of models with different capabilities, performance
5623 characteristics, and price points. Refer to the [model guide](/api/docs/models)5623 characteristics, and price points. Refer to the [model guide](/api/docs/models)
5624 to browse and compare available models.5624 to browse and compare available models.
13143 13143
13144 - `model: "gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more or string`13144 - `model: "gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more or string`
13145 13145
13146 Model ID used to generate the response, like `gpt-6-astra`. OpenAI13146 Model ID used to generate the response, like `gpt-6.2-astra`. OpenAI
13147 offers a wide range of models with different capabilities, performance13147 offers a wide range of models with different capabilities, performance
13148 characteristics, and price points. Refer to the [model guide](/api/docs/models)13148 characteristics, and price points. Refer to the [model guide](/api/docs/models)
13149 to browse and compare available models.13149 to browse and compare available models.
13150 13150
13151 - `"gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more`13151 - `"gpt-6-astra" or "gpt-6.2-astra" or "gpt-6.1-sol" or 112 more`
13152 13152
13153 Model ID used to generate the response, like `gpt-6-astra`. OpenAI13153 Model ID used to generate the response, like `gpt-6.2-astra`. OpenAI
13154 offers a wide range of models with different capabilities, performance13154 offers a wide range of models with different capabilities, performance
13155 characteristics, and price points. Refer to the [model guide](/api/docs/models)13155 characteristics, and price points. Refer to the [model guide](/api/docs/models)
13156 to browse and compare available models.13156 to browse and compare available models.
19698curl https://api.openai.com/v1/responses \19698curl https://api.openai.com/v1/responses \
19699 -H 'Content-Type: application/json' \19699 -H 'Content-Type: application/json' \
19700 -H "Authorization: Bearer $OPENAI_API_KEY" \19700 -H "Authorization: Bearer $OPENAI_API_KEY" \
19701 -d '"string"'19701 -d '{
19702 "model": "gpt-6.2-astra",
19703 "input": "Write a one-sentence bedtime story about a unicorn."
19704 }'
19702```19705```
19703 19706
19704#### 200 — Example19707#### 200 — Example
19715 "incomplete_details": null,19718 "incomplete_details": null,
19716 "instructions": null,19719 "instructions": null,
19717 "max_output_tokens": null,19720 "max_output_tokens": null,
19718 "model": "gpt-6-astra",19721 "model": "gpt-6.2-astra",
19719 "output": [19722 "output": [
19720 {19723 {
19721 "type": "message",19724 "type": "message",
19853 -H "Content-Type: application/json" \19856 -H "Content-Type: application/json" \
19854 -H "Authorization: Bearer $OPENAI_API_KEY" \19857 -H "Authorization: Bearer $OPENAI_API_KEY" \
19855 -d '{19858 -d '{
19856 "model": "gpt-6-astra",19859 "model": "gpt-6.2-astra",
19857 "input": [19860 "input": [
19858 {19861 {
19859 "role": "user",19862 "role": "user",
19886 "instructions": null,19889 "instructions": null,
19887 "max_output_tokens": null,19890 "max_output_tokens": null,
19888 "max_tool_calls": null,19891 "max_tool_calls": null,
19889 "model": "gpt-6-astra",19892 "model": "gpt-6.2-astra",
19890 "output": [19893 "output": [
19891 {19894 {
19892 "id": "msg_686eef60d3e081a29283bdcbc4322fd90e34c516d176ff86",19895 "id": "msg_686eef60d3e081a29283bdcbc4322fd90e34c516d176ff86",
19946 -H "Content-Type: application/json" \19949 -H "Content-Type: application/json" \
19947 -H "Authorization: Bearer $OPENAI_API_KEY" \19950 -H "Authorization: Bearer $OPENAI_API_KEY" \
19948 -d '{19951 -d '{
19949 "model": "gpt-6-astra",19952 "model": "gpt-6.2-astra",
19950 "tools": [{19953 "tools": [{
19951 "type": "file_search",19954 "type": "file_search",
19952 "vector_store_ids": ["vs_1234567890"],19955 "vector_store_ids": ["vs_1234567890"],
19970 "incomplete_details": null,19973 "incomplete_details": null,
19971 "instructions": null,19974 "instructions": null,
19972 "max_output_tokens": null,19975 "max_output_tokens": null,
19973 "model": "gpt-6-astra",19976 "model": "gpt-6.2-astra",
19974 "output": [19977 "output": [
19975 {19978 {
19976 "type": "file_search_call",19979 "type": "file_search_call",
20099 -H "Content-Type: application/json" \20102 -H "Content-Type: application/json" \
20100 -H "Authorization: Bearer $OPENAI_API_KEY" \20103 -H "Authorization: Bearer $OPENAI_API_KEY" \
20101 -d '{20104 -d '{
20102 "model": "gpt-6-astra",20105 "model": "gpt-6.2-astra",
20103 "input": "What is the weather like in Boston today?",20106 "input": "What is the weather like in Boston today?",
20104 "tools": [20107 "tools": [
20105 {20108 {
20140 "incomplete_details": null,20143 "incomplete_details": null,
20141 "instructions": null,20144 "instructions": null,
20142 "max_output_tokens": null,20145 "max_output_tokens": null,
20143 "model": "gpt-6-astra",20146 "model": "gpt-6.2-astra",
20144 "output": [20147 "output": [
20145 {20148 {
20146 "type": "function_call",20149 "type": "function_call",
20219 -H "Content-Type: application/json" \20222 -H "Content-Type: application/json" \
20220 -H "Authorization: Bearer $OPENAI_API_KEY" \20223 -H "Authorization: Bearer $OPENAI_API_KEY" \
20221 -d '{20224 -d '{
20222 "model": "gpt-6-astra",20225 "model": "gpt-6.2-astra",
20223 "input": [20226 "input": [
20224 {20227 {
20225 "role": "user",20228 "role": "user",
20249 "incomplete_details": null,20252 "incomplete_details": null,
20250 "instructions": null,20253 "instructions": null,
20251 "max_output_tokens": null,20254 "max_output_tokens": null,
20252 "model": "gpt-6-astra",20255 "model": "gpt-6.2-astra",
20253 "output": [20256 "output": [
20254 {20257 {
20255 "type": "message",20258 "type": "message",
20307 -H "Content-Type: application/json" \20310 -H "Content-Type: application/json" \
20308 -H "Authorization: Bearer $OPENAI_API_KEY" \20311 -H "Authorization: Bearer $OPENAI_API_KEY" \
20309 -d '{20312 -d '{
20310 "model": "gpt-6-astra",20313 "model": "gpt-6.2-astra",
20311 "input": "How much wood would a woodchuck chuck?",20314 "input": "How much wood would a woodchuck chuck?",
20312 "reasoning": {20315 "reasoning": {
20313 "effort": "high"20316 "effort": "high"
20329 "incomplete_details": null,20332 "incomplete_details": null,
20330 "instructions": null,20333 "instructions": null,
20331 "max_output_tokens": null,20334 "max_output_tokens": null,
20332 "model": "gpt-6-astra",20335 "model": "gpt-6.2-astra",
20333 "output": [20336 "output": [
20334 {20337 {
20335 "type": "message",20338 "type": "message",
20387 -H "Content-Type: application/json" \20390 -H "Content-Type: application/json" \
20388 -H "Authorization: Bearer $OPENAI_API_KEY" \20391 -H "Authorization: Bearer $OPENAI_API_KEY" \
20389 -d '{20392 -d '{
20390 "model": "gpt-6-astra",20393 "model": "gpt-6.2-astra",
20391 "instructions": "You are a helpful assistant.",20394 "instructions": "You are a helpful assistant.",
20392 "input": "Hello!",20395 "input": "Hello!",
20393 "stream": true20396 "stream": true
20398 20401
20399```json20402```json
20400event: response.created20403event: response.created
20401data: {"type":"response.created","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","access_programs":null,"created_at":1741290958,"status":"in_progress","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-6-astra","output":[],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":null,"user":null,"metadata":{}},"sequence_number":0}20404data: {"type":"response.created","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","access_programs":null,"created_at":1741290958,"status":"in_progress","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-6.2-astra","output":[],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":null,"user":null,"metadata":{}},"sequence_number":0}
20402 20405
20403event: response.in_progress20406event: response.in_progress
20404data: {"type":"response.in_progress","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","access_programs":null,"created_at":1741290958,"status":"in_progress","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-6-astra","output":[],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":null,"user":null,"metadata":{}},"sequence_number":1}20407data: {"type":"response.in_progress","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","access_programs":null,"created_at":1741290958,"status":"in_progress","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-6.2-astra","output":[],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":null,"user":null,"metadata":{}},"sequence_number":1}
20405 20408
20406event: response.output_item.added20409event: response.output_item.added
20407data: {"type":"response.output_item.added","output_index":0,"item":{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"in_progress","role":"assistant","content":[]},"sequence_number":2}20410data: {"type":"response.output_item.added","output_index":0,"item":{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"in_progress","role":"assistant","content":[]},"sequence_number":2}
20424data: {"type":"response.output_item.done","output_index":0,"item":{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"completed","role":"assistant","content":[{"type":"output_text","text":"Hi there! How can I assist you today?","annotations":[],"logprobs":[]}]},"sequence_number":12}20427data: {"type":"response.output_item.done","output_index":0,"item":{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"completed","role":"assistant","content":[{"type":"output_text","text":"Hi there! How can I assist you today?","annotations":[],"logprobs":[]}]},"sequence_number":12}
20425 20428
20426event: response.completed20429event: response.completed
20427data: {"type":"response.completed","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","access_programs":null,"created_at":1741290958,"status":"completed","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-6-astra","output":[{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"completed","role":"assistant","content":[{"type":"output_text","text":"Hi there! How can I assist you today?","annotations":[],"logprobs":[]}]}],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":{"input_tokens":37,"output_tokens":11,"output_tokens_details":{"reasoning_tokens":0},"total_tokens":48,"input_tokens_details":{"cached_tokens":0,"cache_write_tokens":0}},"user":null,"metadata":{}},"sequence_number":13}20430data: {"type":"response.completed","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","access_programs":null,"created_at":1741290958,"status":"completed","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-6.2-astra","output":[{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"completed","role":"assistant","content":[{"type":"output_text","text":"Hi there! How can I assist you today?","annotations":[],"logprobs":[]}]}],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":{"input_tokens":37,"output_tokens":11,"output_tokens_details":{"reasoning_tokens":0},"total_tokens":48,"input_tokens_details":{"cached_tokens":0,"cache_write_tokens":0}},"user":null,"metadata":{}},"sequence_number":13}
20428 20431
20429```20432```
20430 20433
20435 -H "Content-Type: application/json" \20438 -H "Content-Type: application/json" \
20436 -H "Authorization: Bearer $OPENAI_API_KEY" \20439 -H "Authorization: Bearer $OPENAI_API_KEY" \
20437 -d '{20440 -d '{
20438 "model": "gpt-6-astra",20441 "model": "gpt-6.2-astra",
20439 "input": "Tell me a three sentence bedtime story about a unicorn."20442 "input": "Tell me a three sentence bedtime story about a unicorn."
20440 }'20443 }'
20441```20444```
20454 "incomplete_details": null,20457 "incomplete_details": null,
20455 "instructions": null,20458 "instructions": null,
20456 "max_output_tokens": null,20459 "max_output_tokens": null,
20457 "model": "gpt-6-astra",20460 "model": "gpt-6.2-astra",
20458 "output": [20461 "output": [
20459 {20462 {
20460 "type": "message",20463 "type": "message",
20512 -H "Content-Type: application/json" \20515 -H "Content-Type: application/json" \
20513 -H "Authorization: Bearer $OPENAI_API_KEY" \20516 -H "Authorization: Bearer $OPENAI_API_KEY" \
20514 -d '{20517 -d '{
20515 "model": "gpt-6-astra",20518 "model": "gpt-6.2-astra",
20516 "tools": [{ "type": "web_search_preview" }],20519 "tools": [{ "type": "web_search_preview" }],
20517 "input": "What was a positive news story from today?"20520 "input": "What was a positive news story from today?"
20518 }'20521 }'
20532 "incomplete_details": null,20535 "incomplete_details": null,
20533 "instructions": null,20536 "instructions": null,
20534 "max_output_tokens": null,20537 "max_output_tokens": null,
20535 "model": "gpt-6-astra",20538 "model": "gpt-6.2-astra",
20536 "output": [20539 "output": [
20537 {20540 {
20538 "type": "web_search_call",20541 "type": "web_search_call",