Skip to main content

Responses Format

Create a model response using the official OpenAI Responses API format.

This endpoint only supports models that officially support the OpenAI Responses API. Do not use Claude, DeepSeek, or other models that only support Chat Completions or Messages format on this endpoint.

Try It

POST/v1/responseshttps://api-platform.ope.ai

Authentication

Use Bearer token authentication.

  • Header: Authorization: Bearer <api-key>
  • Example: Authorization: Bearer sk-xxxxxx

Request Body(application/json)

FieldTypeRequiredDescription
modelstringYesModel ID
inputstring | arrayYesInput content; pass a string or an official Responses input item array
instructionsstringNoSystem or developer instructions inserted into the model context
max_output_tokensintegerNoMaximum tokens the response can generate
previous_response_idstringNoPrevious response ID for continuing context
streambooleanNoWhether to use SSE streaming
temperaturenumberNoSampling temperature
top_pnumberNoNucleus sampling parameter
toolsarrayNoOfficial Responses tools array
tool_choicestring | objectNoTool selection strategy
parallel_tool_callsbooleanNoWhether to allow parallel tool calls
reasoningobjectNoReasoning model options, such as effort and summary
textobjectNoText output configuration
truncationstringNoContext truncation strategy
metadataobjectNoMetadata
includearrayNoOfficial extra fields to include in the response
storebooleanNoWhether to store the response
userstringNoEnd-user identifier
max_tool_callsintegerNoMaximum total tool calls for this response

Request Examples

curl -X POST "https://api-platform.ope.ai/v1/responses" \
-H "Authorization: Bearer $OPEAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-5",
"input": "Introduce OPEAI Platform in one sentence."
}'

Input Array Example

{
"model": "gpt-5",
"input": [
{
"role": "user",
"content": [
{
"type": "input_text",
"text": "Introduce OPEAI Platform in one sentence."
}
]
}
]
}

Response Example

{
"id": "resp_abc123",
"object": "response",
"created_at": 1762499410,
"status": "completed",
"model": "gpt-5",
"output": [
{
"type": "message",
"id": "msg_abc123",
"status": "completed",
"role": "assistant",
"content": [
{
"type": "output_text",
"text": "OPEAI Platform is a unified API platform for accessing multiple AI model capabilities.",
"annotations": []
}
]
}
],
"usage": {
"input_tokens": 18,
"output_tokens": 22,
"total_tokens": 40
}
}

Official reference: OpenAI Responses API