Skip to main content

Phone Call List

Tags: communication, telephony, voice

Voice call history and management

Resources​

Request and response models used by the endpoints on this page.

AgentMemoryConfig​

FieldTypeRequiredDescription
enabledBooleanDefault: False
episodicBooleanDefault: False
preferencesBooleanDefault: True
semanticBooleanDefault: True
summariesBooleanDefault: True

Example:

{
"enabled": false,
"preferences": true,
"semantic": true,
"summaries": true,
"episodic": false
}

BaseAssistantResponse​

FieldTypeRequiredDescription
chatModelString
chatModelConfigDict[str, Any]
codeInterpreterEnabledBooleanDefault: False
descriptionString
idInteger
identityString
memoryConfigAgentMemoryConfig | null
nameString✓
realtimeModelString
realtimeModelConfigDict[str, Any]
toolsArrayDefault: []
webBrowserEnabledBooleanDefault: False

Example:

{
"name": "string",
"tools": [],
"codeInterpreterEnabled": false,
"webBrowserEnabled": false
}

MemberExperimentGroupSummary​

FieldTypeRequiredDescription
groupIdInteger✓
groupNameString✓
groupSlugString✓
isControlBoolean✓

Example:

{
"groupId": 0,
"groupName": "string",
"groupSlug": "string",
"isControl": false
}

MemberLabelResponse​

FieldTypeRequiredDescription
colorString✓
descriptionString✓
idInteger✓
nameString✓
slugString✓
uuidString✓

Example:

{
"id": 0,
"uuid": "string",
"name": "string",
"slug": "string",
"color": "string",
"description": "string"
}

PaginatedResponse[PhoneCallResponse]​

FieldTypeRequiredDescription
itemsArray<PhoneCallResponse>✓
pageInteger✓
pageSizeInteger✓
totalInteger✓
totalPagesInteger✓

Example:

{
"items": [],
"total": 0,
"page": 0,
"pageSize": 0,
"totalPages": 0
}

PhoneCallResponse​

FieldTypeRequiredDescription
agentBaseAssistantResponse | null
carrierStatusStringTwilio CallStatus / DialCallStatus terminal value (GRA-6416): completed, busy, no-answer, failed, or canceled. Independent of product intent — a successful transfer is terminationReason=forward + carrierStatus=completed; a transfer whose destination was busy is forward + busy.
chatIdInteger
chatUuidStringUuid of the chat the call belongs to (chatId's public identifier). Null when the call has no chat.
createdAtDateTime✓
creditsNumber
failureDetailStringTransport / infra failure detail (GRA-6416): connection_reset (Twilio ErrorCode on completed call), stream_reset (media-stream WebSocket reset, e.g. Twilio 31921), never_connected (bridge-leg provisional), timeout, bridge_call_create_failed, bridge_call_create_missing_sid, fax_t30_failed, other closed fax_* receive codes, or error.
finishedAtDateTime
idInteger✓
inboundBoolean✓
memberWorkspaceMemberResponse | null
phoneNumberIdInteger✓
startedAtDateTime
statusString✓
terminationReasonStringProduct / app outcome for how the call ended (GRA-6416). Preferred values: hangup (assistant ended), forward (call forwarded), handoff, completed (caller hung up / normal end), policy rejects (voice_disabled, anonymous_rejected, …), blocked_outbound_safety, strict_voice_blocked, voicemail, amd_unknown. Legacy rows may also hold carrier strings (busy, no-answer, …) or transport failures (connection_reset, stream_reset, never_connected); prefer carrierStatus / failureDetail when present. Null for in-progress/unknown calls.
twilioCallIdString✓
uuidString✓Public identifier of the call — the uuid the Activity Spine (organization webhooks v2) uses as the call subject.
workflowIdIntegerID of the workflow associated with this call, resolved via the chat's assignment (PhoneCall.chat_id -> Chat.assignment_id -> Assignment.workflow_revision_id -> WorkflowRevision.workflow_id). Null for direct human-to-human calls with no chat, or chats with no assignment.

Example:

{
"id": 0,
"uuid": "string",
"phoneNumberId": 0,
"twilioCallId": "string",
"status": "string",
"createdAt": "2024-01-01T00:00:00Z",
"inbound": false
}

SharedContactResponse​

FieldTypeRequiredDescription
archivedBooleanDefault: False
fieldLiteral['phone', 'email']✓
memberIdInteger✓

Example:

{
"field": "phone",
"memberId": 0,
"archived": false
}

WorkspaceMemberResponse​

FieldTypeRequiredDescription
accountEnabledBoolean
accountTosAcceptedBoolean✓
accountUuidString✓
canLoginBooleanDefault: True
createdAtDateTime✓
dateOfBirthDate
descriptionString✓
emailString✓
emailVerifiedBooleanDefault: False
experimentGroupMemberExperimentGroupSummary | null
externalIdString✓
homeFolderIdInteger
idInteger✓
isArchivedBooleanDefault: False
isImportProtectedBooleanDefault: False
isOrgOwnerBoolean
isSuperuserBoolean
labelsArray<MemberLabelResponse>Default: []
localeString✓
memberRoleIdInteger✓
memberRoleNameString✓
memberRoleSystemKeyString
memberTypeStringDefault: member
nameString✓
notifyEmailBoolean✓
notifySmsBoolean✓
notifyVoiceBoolean✓
notifyWhatsappBooleanDefault: False
orgRoleString
phoneString✓
phoneTypeString✓
phoneVerifiedBooleanDefault: False
roleString✓
sharedContactPlacementsArray<SharedContactResponse>Default: []
timezoneString
titleString
tosAcceptedBoolean✓
updatedAtDateTime✓
usagePausedBooleanDefault: False
uuidString✓

Example:

{
"id": 0,
"uuid": "string",
"role": "string",
"tosAccepted": false,
"accountTosAccepted": false,
"accountUuid": "string",
"createdAt": "2024-01-01T00:00:00Z",
"updatedAt": "2024-01-01T00:00:00Z",
"name": "string",
"description": "string",
"phone": "string",
"phoneType": "string",
"email": "string",
"externalId": "string",
"emailVerified": false,
"phoneVerified": false,
"notifySms": false,
"notifyEmail": false,
"notifyVoice": false,
"notifyWhatsapp": false,
"locale": "string",
"memberRoleId": 0,
"memberRoleName": "string",
"labels": [],
"memberType": "member",
"isArchived": false,
"isImportProtected": false,
"usagePaused": false,
"canLogin": true,
"sharedContactPlacements": []
}

Endpoints​

List​

GET /api/v2/w/{workspace_uuid}/calls

Description:

List phone calls in the workspace.

Optional filters: phoneNumberId (int PK), chatId, workflowId, callId, status, inbound, and date range (dateFrom / dateTo). Requires phones:read scope. callId is an equality predicate on the same audited, scope-gated listing; it intersects every other filter and returns an empty page when the target is unavailable.

Authorization: Requires phones:read scope

Parameters:

  • page (Integer) — min: 1
  • page_size (Integer) — min: 1, max: 100
  • phoneNumberId (Integer)
  • chatId (Integer)
  • workflowId (Integer)
  • callId (Integer)
  • status (CallStatus)
  • inbound (Boolean)
  • dateFrom (datetime)
  • dateTo (datetime)

Response: See PaginatedResponse[PhoneCallResponse]


By Uuid​

GET /api/v2/w/{workspace_uuid}/calls/by-uuid/{uuid}

Description:

Get one phone call by uuid — the subject of call.completed / call.summary in organization webhooks v2.

Authorization is GET /chats/\{chat_id}/phone-calls's, applied to the call's own chat: chats:read, then get_chat_or_raise's chat access policy (get_readable_phone_call_by_uuid_or_404). A call the caller's chat access does not reach — and a call with no chat, which that policy cannot be applied to — is a 404 identical to a missing uuid, so the route is not an existence oracle. A uuid from another workspace cannot resolve; the session sees one workspace schema.

The response carries chatId and chatUuid so the caller can read the chat (and its summary) next. The path segment is \{uuid} so @phi_audit records the numeric call id via resource_id.

Authorization: Requires chats:read scope

Parameters:

  • uuid (String)

Response: See PhoneCallResponse