Response interface
The response resource.
Properties
| conversation |
Which conversation the response is added to, determined by the |
| id | The unique ID of the response. |
| max |
Maximum number of output tokens for a single assistant response, inclusive of tool calls, that was used in this response. |
| metadata | Set of up to 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maximum of 512 characters long. |
| modalities | The set of modalities the model used to respond. If there are multiple modalities,
the model will pick one, for example if |
| object | The object type, must be |
| output | The list of output items generated by the response. |
| output |
The format of output audio. Options are |
| status | The final status of the response. One of: |
| status |
Additional details about the status. |
| temperature | Sampling temperature for the model, limited to [0.6, 1.2]. Defaults to 0.8. |
| usage | Usage statistics for the Response, this will correspond to billing. A VoiceLive API session will maintain a conversation context and append new Items to the Conversation, thus output from previous turns (text and audio tokens) will become the input for later turns. |
| voice | supported voice identifiers and configurations. |
Property Details
conversationId
Which conversation the response is added to, determined by the conversation
field in the response.create event. If auto, the response will be added to
the default conversation and the value of conversation_id will be an id like
conv_1234. If none, the response will not be added to any conversation and
the value of conversation_id will be null. If responses are being triggered
by server VAD, the response will be added to the default conversation, thus
the conversation_id will be an id like conv_1234.
conversationId?: string
Property Value
string
id
The unique ID of the response.
id?: string
Property Value
string
maxOutputTokens
Maximum number of output tokens for a single assistant response, inclusive of tool calls, that was used in this response.
maxOutputTokens?: number | "inf"
Property Value
number | "inf"
metadata
Set of up to 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format. Keys can be a maximum of 64 characters long and values can be a maximum of 512 characters long.
metadata?: Record<string, string>
Property Value
Record<string, string>
modalities
The set of modalities the model used to respond. If there are multiple modalities,
the model will pick one, for example if modalities is ["text", "audio"], the model
could be responding in either text or audio.
modalities?: string[]
Property Value
string[]
object
The object type, must be realtime.response.
object?: "realtime.response"
Property Value
"realtime.response"
output
The list of output items generated by the response.
output?: ResponseItemUnion[]
Property Value
outputAudioFormat
The format of output audio. Options are pcm16, g711_ulaw, or g711_alaw.
outputAudioFormat?: string
Property Value
string
status
The final status of the response.
One of: completed, cancelled, failed, incomplete, or in_progress.
status?: string
Property Value
string
statusDetails
Additional details about the status.
statusDetails?: ResponseStatusDetailsUnion
Property Value
temperature
Sampling temperature for the model, limited to [0.6, 1.2]. Defaults to 0.8.
temperature?: number
Property Value
number
usage
Usage statistics for the Response, this will correspond to billing. A VoiceLive API session will maintain a conversation context and append new Items to the Conversation, thus output from previous turns (text and audio tokens) will become the input for later turns.
usage?: TokenUsage