Create Response

Create an LLM response.

Supports both streaming and non-streaming modes via the stream parameter.

Request

This endpoint expects an object.
inputlist of objectsRequired
Conversation history
modelstring or nullOptional

Model ID in format ‘provider/model-name’. Optional if a routing policy is configured.

toolslist of objects or nullOptional
Available tools
tool_choicestring or map from strings to any or nullOptional

Tool choice policy: ‘auto’, ‘none’, ‘required’, or {‘type’: ‘function’, ‘function’: {‘name’: ’…’}}

max_tokensinteger or nullOptional
Maximum tokens to generate
temperaturedouble or nullOptional0-2
Sampling temperature
top_pdouble or nullOptional0-1
Nucleus sampling parameter
stoplist of strings or nullOptional
Stop sequences
response_formatobject or nullOptional
Response format
streambooleanOptionalDefaults to false
Whether to stream the response
tagslist of objects or nullOptional

Tags to attach to this request for categorization (key-value pairs)

project_idstring or nullOptional

Optional project ID (UUID) to associate with this request

routing_policy_idstring or nullOptional

Override the default routing policy (for testing)

include_routing_metadatabooleanOptionalDefaults to false
Include detailed routing metadata in response

Response

Successful Response
idstring
created_atdatetime
modelstring

The model that generated the response, in ‘provider/model-name’ format

outputlist of objects
usageobject
Token usage statistics.
object"response"
provider_request_idstring or null
The upstream provider's request ID
routingobject or null

Routing metadata (only present when include_routing_metadata=true)

Errors

422
Unprocessable Entity Error