Call data model

Updated:

View field support, webhooks, and list parameters for each integration on the Supported Integrations page.

FieldTypeRequiredDescription
idstringNoUnique identifier for this call object
created_atstring (date-time)NoThe date that this call object was created (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
updated_atstring (date-time)NoThe last date that this call object was updated (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
contact_idstringNoThe contact ID for call (reference to UcContact)
telephoneobjectNoThe telephone number called
telephone.telephonestringYes
telephone.typeenumNoValues: WORK, HOME, OTHER, FAX, MOBILE
start_atstring (date-time)NoThe start time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
end_atstring (date-time)NoThe end time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
user_idstringNo(reference to HrisEmployee)
contactsUcContact[]No
contacts[].idstringNoUnique identifier for this contact object
contacts[].created_atstring (date-time)NoThe date that this contact object was created (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
contacts[].updated_atstring (date-time)NoThe last date that this contact object was updated (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
contacts[].namestringNoThe name of the contact
contacts[].first_namestringNo
contacts[].last_namestringNo
contacts[].titlestringNoThe job title of the contact
contacts[].companystringNoThe company/organization name of the contact
contacts[].emailsUcEmail[]NoAn array of email addresses for this contact
contacts[].emails[].emailstringYes
contacts[].emails[].typeenumNoValues: WORK, HOME, OTHER
contacts[].telephonesUcTelephone[]NoAn array of telephones for this contact
contacts[].telephones[].telephonestringYes
contacts[].telephones[].typeenumNoValues: WORK, HOME, OTHER, FAX, MOBILE
contacts[].metadataUcMetadata[]No
contacts[].metadata[].idstringNo
contacts[].metadata[].slugstringNo
contacts[].metadata[].valueobjectNo
contacts[].metadata[].namespacestringNo
contacts[].metadata[].formatenumNoValues: TEXT, NUMBER, DATE, BOOLEAN, FILE, TEXTAREA, SINGLE_SELECT, MULTIPLE_SELECT, MEASUREMENT, PRICE, YES_NO, CURRENCY, URL
contacts[].metadata[].extra_dataobjectNo
is_privatebooleanNo
user_namestringNo
user_phonestringNo
typeenumNoValues: INBOUND, OUTBOUND
metadataUcMetadata[]No
metadata[].idstringNo
metadata[].slugstringNo
metadata[].valueobjectNo
metadata[].namespacestringNo
metadata[].formatenumNoValues: TEXT, NUMBER, DATE, BOOLEAN, FILE, TEXTAREA, SINGLE_SELECT, MULTIPLE_SELECT, MEASUREMENT, PRICE, YES_NO, CURRENCY, URL
metadata[].extra_dataobjectNo
conversation_identifierstringNoopaque identifier shared across legs of one interaction
statusenumNoThe current or final status of the call Values: QUEUED, RINGING, IN_PROGRESS, COMPLETED, BUSY, NO_ANSWER, FAILED, CANCELED, OTHER
answer_atstring (date-time)NoWhen the call was answered (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
duration_secondsnumberNoCall length in seconds
cost_amountnumberNoWhat the integration charged for the call
currencystringNoISO 4217 currency of cost_amount
parent_idstringNoThe parent call (leg) that this call belongs to
instructionsUcCallInstruction[]NoWrite-only: what the call does once answered (create/update only; never returned)
instructions[].typeenumYesValues: SAY, PLAY, PAUSE, DIAL, HANGUP
instructions[].textstringNoSAY: text to speak
instructions[].languagestringNoSAY: BCP 47 language code (e.g. en-US), passed to the integration as-is
instructions[].audio_urlstringNoPLAY: public MP3 or WAV URL
instructions[].secondsnumberNoPAUSE: length of silence
instructions[].telephoneUcCallInstruction_telephoneNoDIAL: number to dial and bridge
instructions[].telephone.telephonestringYes
instructions[].telephone.typeenumNoValues: WORK, HOME, OTHER, FAX, MOBILE
instructions[].sip_uristringNoDIAL: SIP address to dial instead of telephone
instructions[].user_phonestringNoDIAL: caller ID on the dialed leg (defaults to the call's user_phone)
instructions[].timeout_secondsnumberNoDIAL: how long to ring before giving up

TypeScript

TypeScript
export type UcCall = {
	id?: string; // Unique identifier for this call object
	created_at?: string-time; // The date that this call object was created (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	updated_at?: string-time; // The last date that this call object was updated (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	contact_id?: string; // The contact ID for call (reference to UcContact)
	telephone?: {
		telephone: string; 
		type?: 'WORK' | 'HOME' | 'OTHER' | 'FAX' | 'MOBILE'; 
	}; // The telephone number called
	start_at?: string-time; // The start time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	end_at?: string-time; // The end time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	user_id?: string; // (reference to HrisEmployee)
	contacts?: [];
	is_private?: boolean;
	user_name?: string;
	user_phone?: string;
	type?: 'INBOUND' | 'OUTBOUND';
	metadata?: [];
	raw?: any; // The raw data returned by the integration for this call
	conversation_identifier?: string; // opaque identifier shared across legs of one interaction
	status?: 'QUEUED' | 'RINGING' | 'IN_PROGRESS' | 'COMPLETED' | 'BUSY' | 'NO_ANSWER' | 'FAILED' | 'CANCELED' | 'OTHER'; // The current or final status of the call
	answer_at?: string-time; // When the call was answered (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)
	duration_seconds?: number; // Call length in seconds
	cost_amount?: number; // What the integration charged for the call
	currency?: string; // ISO 4217 currency of cost_amount
	parent_id?: string; // The parent call (leg) that this call belongs to
	instructions?: []; // Write-only: what the call does once answered (create/update only; never returned)
} 

Zod

Zod
import { z } from 'zod';

export const ZodUcCall = z.object({
	id: z.string().optional().describe("Unique identifier for this call object"),
	created_at: z.string-time().optional().describe("The date that this call object was created (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	updated_at: z.string-time().optional().describe("The last date that this call object was updated (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	contact_id: z.string().optional().describe("The contact ID for call (reference to UcContact)"),
	telephone: z.object({
			telephone: z.string(),
			type: z.enum("WORK", "HOME", "OTHER", "FAX", "MOBILE").optional()
}).optional().describe("The telephone number called"),
	start_at: z.string-time().optional().describe("The start time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	end_at: z.string-time().optional().describe("The end time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	user_id: z.string().optional().describe("(reference to HrisEmployee)"),
	contacts: z.array().optional(),
	is_private: z.boolean().optional(),
	user_name: z.string().optional(),
	user_phone: z.string().optional(),
	type: z.enum("INBOUND", "OUTBOUND").optional(),
	metadata: z.array().optional(),
,
	conversation_identifier: z.string().optional().describe("opaque identifier shared across legs of one interaction"),
	status: z.enum("QUEUED", "RINGING", "IN_PROGRESS", "COMPLETED", "BUSY", "NO_ANSWER", "FAILED", "CANCELED", "OTHER").optional().describe("The current or final status of the call"),
	answer_at: z.string-time().optional().describe("When the call was answered (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"),
	duration_seconds: z.number().optional().describe("Call length in seconds"),
	cost_amount: z.number().optional().describe("What the integration charged for the call"),
	currency: z.string().optional().describe("ISO 4217 currency of cost_amount"),
	parent_id: z.string().optional().describe("The parent call (leg) that this call belongs to"),
	instructions: z.array().optional().describe("Write-only: what the call does once answered (create/update only; never returned)")
});

Python

Python
import dataclasses

@dataclasses.dataclass
class UcCallType(str, Enum):
	INBOUND = 'INBOUND'
	OUTBOUND = 'OUTBOUND'

@dataclasses.dataclass
class UcCallStatus(str, Enum):
	QUEUED = 'QUEUED'
	RINGING = 'RINGING'
	IN_PROGRESS = 'IN_PROGRESS'
	COMPLETED = 'COMPLETED'
	BUSY = 'BUSY'
	NO_ANSWER = 'NO_ANSWER'
	FAILED = 'FAILED'
	CANCELED = 'CANCELED'
	OTHER = 'OTHER'

@dataclasses.dataclass
class UcCallTelephoneType(str, Enum):
	WORK = 'WORK'
	HOME = 'HOME'
	OTHER = 'OTHER'
	FAX = 'FAX'
	MOBILE = 'MOBILE'

@dataclasses.dataclass
class PropertyUcCallTelephone:
	telephone: Optional[str]
	type: Optional[UcCallTelephoneType]

@dataclasses.dataclass
class UcCall:
	"""Unique identifier for this call object"""
	id: Optional[str]
	"""The date that this call object was created (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	created_at: Optional[str]
	"""The last date that this call object was updated (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	updated_at: Optional[str]
	"""The contact ID for call (reference to UcContact)"""
	contact_id: Optional[str]
	"""The telephone number called"""
	telephone: Optional[PropertyUcCallTelephone]
	"""The start time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	start_at: Optional[str]
	"""The end time of the call (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	end_at: Optional[str]
	"""(reference to HrisEmployee)"""
	user_id: Optional[str]
	contacts: Optional[PropertyUcCallContacts]
	is_private: Optional[bool]
	user_name: Optional[str]
	user_phone: Optional[str]
	type: Optional[UcCallType]
	metadata: Optional[PropertyUcCallMetadata]

	"""opaque identifier shared across legs of one interaction"""
	conversation_identifier: Optional[str]
	"""The current or final status of the call"""
	status: Optional[UcCallStatus]
	"""When the call was answered (ISO-8601 / YYYY-MM-DDTHH:MM:SSZ format)"""
	answer_at: Optional[str]
	"""Call length in seconds"""
	duration_seconds: Optional[int]
	"""What the integration charged for the call"""
	cost_amount: Optional[int]
	"""ISO 4217 currency of cost_amount"""
	currency: Optional[str]
	"""The parent call (leg) that this call belongs to"""
	parent_id: Optional[str]
	"""Write-only: what the call does once answered (create/update only; never returned)"""
	instructions: Optional[PropertyUcCallInstructions]
Are we missing anything? Let us know
Was this page helpful?