Skip to content

Responses

/v1/responses is the OpenAI Responses API compatible entrypoint for Codex CLI and Responses protocol clients.

Interface

ItemValue
MethodPOST
Path/v1/responses, /v1/responses/*
Content-Typeapplication/json
AuthenticationAuthorization: Bearer YOUR_API_KEY

Request Parameters

ParameterTypeRequiredDescription
modelstringYesRequested model.
inputstring or arrayYesResponses API input.
streambooleanNoWhether to stream the response.
instructionsstringNoSystem-level instructions.
reasoningobjectNoReasoning configuration, applied by model capability.
toolsarrayNoTool definitions. Availability depends on the selected model and API mode.

Request Example

bash
curl https://api.llmapi.site/v1/responses \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{
    "model": "gpt-5.1",
    "input": "Write a concise release note.",
    "stream": false
  }'

Response Example

json
{
  "id": "resp_123",
  "object": "response",
  "status": "completed",
  "model": "gpt-5.1",
  "output": []
}
FieldDescription
idResponse ID returned by the upstream-compatible API.
statusResponse lifecycle status, commonly completed for non-streaming requests.
modelModel used for the response.
outputResponses API output items.

When stream is true, the response uses OpenAI Responses-compatible server-sent events.

WebSocket Entry

GET /v1/responses is available for clients that use the Responses WebSocket flow.

Errors

StatusCause
400Request body, model, input, tools, or reasoning parameters are invalid.
401API key is missing or invalid.
403Balance, quota, group, or subscription check failed.
404Requested model or Responses-compatible route is unavailable.
429Rate limit or concurrency limit was reached.
500 / 502 / 503Gateway or upstream provider failed.