Skip to content
Skip to page content

Responses and transcripts

Positional rows, timestamp units, aligned transcript arrays and detail JSON.

View as Markdown OpenAPI file

Rows, units and detail JSON

  • List responses are JSON arrays of positional rows. Each cell follows the request’s select order. [] is a successful query with no matching readable rows.
  • Top-level request start and end use Unix microseconds. List started_at and started_at filter values use Unix seconds. Durations and transcript offsets are seconds.
  • Combine turn_data.texts, turn_data.is_customers and turn_data.starts by index. true identifies customer speech; false identifies agent speech.
  • /session JSON uses camelCase keys and enum names; byte fields are base64. Default-valued fields may be omitted, and wordData is omitted. Without x-proto-as-json: true, the endpoint returns protobuf.
  • /get-audio-links returns one session object plus aligned audio and audio_links arrays. The URLs expire after one hour. Retention can leave both arrays empty.
  • Unset proto values can appear as 0, false, empty strings or empty arrays. They do not prove an event was measured. Detection flags are signals, not verified outcomes.

Map rows in code

Map list rows, transcript turns and grouped metrics
// Example only: select = ["session_id", "started_at", "customer_data.name"]
// Response: [["CALL_ID", 1791849600, "Example contact"]]
const calls = rows.map(row => Object.fromEntries(
  select.map((column, index) => [column, row[index]])
));
const startedAt = calls[0] ? new Date(calls[0].started_at * 1000) : null;

// Transcript columns are aligned arrays:
const turns = texts.map((text, index) => ({
  text,
  speaker: isCustomers[index] ? "customer" : "agent",
  startSeconds: starts[index]
}));

// /session with x-proto-as-json: true uses different JSON spelling:
// { "sessionId": "CALL_ID", "customerData": { "name": "Example contact" },
//   "turnData": { "texts": ["Hello"], "isCustomers": [true], "starts": [0] } }
// Default-valued proto fields may be omitted. wordData is omitted.

// Grouped metrics: selects = [{"cnf": []}, {"column_name": "duration"}]
// Example response: [["Interested", 12, 840]]
// Read as: disposition, count, summed duration in seconds.

Common fields

Common fields and their exact paths
What you needColumnHow to use it
Call IDsession_idCopy the exact string into the x-session-id header for /session.
Call timestarted_atUnix seconds in list rows. Convert with new Date(value * 1000).
Customer phone/addresscustomer_addressFor phone calls, the customer address; phone is not a column name.
Rep IDresource_idMatch to users[].user_id from /visible.
Contact namecustomer_data.nameUse this instead of prospect_name or name.
Contact titlecustomer_data.titleUse this instead of title.
Companycustomer_data.company_nameUse this instead of company.
Company websitecustomer_data.company_urlMay be empty when not enriched.
Contact email / custom datacustomer_data.custom_fieldsNo standard email column. Custom fields are JSON text; inspect available keys rather than assuming email exists.
Transcript textturn_data.textsArray of utterances, not one transcript string.
Transcript speakerturn_data.is_customersAligned with texts: true = customer, false = agent.
Transcript timingturn_data.startsAligned with texts; seconds from the start of the session.
Call durationdurationSeconds. dial_metric.live_duration measures the live portion.
Saved outcomeuser_log.dispositionUse /bootstrap for your exact configured option strings.

The field reference lists every selectable path with its type and values.