Skip to main content
POST
Create Call

Authorizations

Authorization
string
header
required

Use Tuner API key (tr_api_...) or user session token. Find your API key in Workspace Settings > API Keys.

Query Parameters

workspace_id
integer
required

Workspace ID. Find this in Workspace > General Settings.

agent_remote_identifier
string
required

Your Agent ID configured in Tuner. Get this value from Agent Settings > Agent Connection > Agent ID.

Example:

"agent_abc123"

Body

application/json

Request schema for public call creation.

call_id
string
required

Unique call identifier from your provider. Must be unique; a duplicate is rejected with a conflict (409).

Required string length: 1 - 200
Example:

"call_example_0001"

call_type
string
required

Call channel/type from your provider (e.g., 'phone_call', 'web_call').

Required string length: 1 - 100
Example:

"phone_call"

transcript_with_tool_calls
PublicTranscriptSegment · object[]
required

The call timeline in chronological order. Each item is a user turn, an agent turn, a tool call or its result, or a workflow node transition.

User and agent turns must carry timing — as words, as start_ms and end_ms, or as start_ms and duration_ms. Latency and voice metrics are computed from it.

Minimum array length: 1
start_timestamp
integer
required

Call start time as Unix epoch. Accepts either seconds or milliseconds.

end_timestamp
integer
required

Call end time as Unix epoch. Accepts either seconds or milliseconds. Must be greater than or equal to start_timestamp.

recording_url
string
required

Public https URL of the call recording (audio file or provider recording link). Required. A value that isn't a public https URL (e.g. a placeholder such as pending) is stored as sent but treated as no recording: it isn't played back or used for Dataset calls.

Required string length: 1 - 1024
sip_call_id
string | null

Optional SIP Call-ID reported by your provider. Stored as the call's SIP identifier and used to correlate the call with a simulation; it never replaces call_id for persistence or idempotency.

Required string length: 1 - 200
sip_headers
Sip Headers · object | null

Optional SIP headers from the incoming call. For Tuner simulation calls, pass back the X-Correlation-Id header Tuner sent to link the call to its simulation. Only the X-Correlation-Id (or Correlation-Id) header is kept, and it is used only to link the call to its simulation; all other headers are ignored.

Example:
recipient
string | null

Recipient phone number (E.164) or SIP URL for outbound calls. For outbound Tuner simulation calls, send the SIP URI your agent dialed so the call can be linked to its simulation.

Required string length: 1 - 500
agent_version
integer | null

The version of the agent that handled this call (e.g. 3).

Required range: x >= 0
transcript
string | null

Diarized plain-text transcript (fallback for display/search). If omitted, we derive it from transcript_with_tool_calls when possible.

duration_ms
integer | null

Call duration in milliseconds. If omitted, we compute it from start_timestamp and end_timestamp.

call_status
string | null

Provider call status at ingest time. Preferred values: 'call_ended'.

Maximum string length: 100
disconnection_reason
string | null

Why the call ended (e.g. user_hangup, agent_hangup).

Maximum string length: 100
caller_phone_number
string | null

Caller phone number in E.164 format when available (e.g., '+14155550123').

Maximum string length: 50
call_successful
boolean | null

Whether the call was successful

user_sentiment
string | null

User sentiment label. Must be one of [positive, neutral, negative, unknown]

Maximum string length: 50
in_voicemail
boolean | null

Whether the call reached voicemail

collected_dynamic_variables
Collected Dynamic Variables · object | null

Dynamic variables collected during the call (free-form JSON). Evals can read these through metadata.<key> in inputs_used; rules and alerts cannot, so send values you want to filter or alert on in metadata.

Example:
call_cost
number | null

Total call cost in cents (e.g. 125 for $1.25).

call_analysis
Call Analysis · object | null

Provider-native analysis payload (free-form JSON; stored as-is)

metadata
CallMetadata · object | null

Custom data about the call, as a JSON object. Nested objects are allowed and keys are case-sensitive. ai_models and usage_token have a defined structure; any other keys are accepted. Merged with general_meta_data_raw, whose keys win on collision. Evals, rules and alerts can refer to these keys as metadata.<key>: in an eval's inputs_used, in an alert condition, and in the key of a call_metadata rule condition.

Example:
general_meta_data_raw
General Meta Data Raw · object | null

Custom data about the call, as a JSON object. Nested objects are allowed and keys are case-sensitive. If metadata is also sent, the keys are merged and these keys win on collision. Evals, rules and alerts refer to these keys the same way as for metadata.

Example:
recording_multi_channel_url
string | null

Public https URL of a multi-channel recording (separate speaker channels), if available. A value that isn't a public https URL is stored as sent but treated as no recording: it isn't played back or used for Dataset calls.

Maximum string length: 1024
recording_file_extension
string | null

Supplying this opts the call into receiving a presigned upload target (recording_upload in the response) so you can upload the call's audio directly to Tuner's storage. Provide the file extension without a leading dot (e.g. 'wav', 'mp3'). Omit this field entirely if you are not uploading audio.

recording_s3_multi_channel
boolean | null

Whether the audio being uploaded has the caller and the agent on separate channels rather than mixed into a single channel. Only applies to audio uploaded via recording_file_extension. Omit this field if the recording is a mono mix -- it is treated as a mono mix by default.

recording_s3_caller_channel
integer | null

The 0-based index of the channel carrying the caller's voice, for audio uploaded via recording_file_extension. Defaults to 0 and is only meaningful when recording_s3_multi_channel is true.

Required range: x >= 0

Response

Successful Response

Response schema for public call creation.

id
integer
required

Internal Tuner call ID

provider_call_id
string
required

Echo of the provider call ID, which is the call_id supplied in the request.

is_new
boolean
required

Always true for a successful create; re-sending an existing call_id returns 409 instead.

recording_upload
RecordingUploadTarget · object | null

Present only when the request set recording_file_extension and the upload target could be prepared; the target is valid for 24 hours. Null if the extension was omitted, if the call already had a recording uploaded, or if preparing the target failed after the call was otherwise saved successfully.