Observing Calls
Guide to using the Vocera API for observing calls
Making an Observe Request
Send a POST request to https://new-prod.vocera.ai/observability/v1/observe/
with the following specification:
Headers
X-VOCERA-API-KEY
: Your API key copied from above
Request Body
-
call_id
(required): Unique identifier for the call -
Either
agent
orassistant_id
(required):-
agent
: The agent ID as shown on your dashboard -
assistant_id
: The assistant ID associated with agent
-
-
Either
voice_recording
orvoice_recording_url
(required):-
voice_recording
: Audio file of the call recording -
voice_recording_url
: URL to the call recording audio file
-
-
call_ended_reason
(optional): Reason for call termination -
customer_number
(optional): Phone number of the customer -
transcript_type
(required): Format the transcript is sent in. can bevocera
,vapi
,retell
ordeepgram
-
transcript_json
(required): JSON object containing the transcript of the call. Can be in Vocera, Vapi or Retell format -
metadata
(optional): Dictionary with additional data -
dynamic_variables
(optional): Dictionary of dynamic variables and values. These values will replace variables in double curly braces in the agent description.
Example Request
Transcript JSON Example:
Vocera Format
Method 1: Using a Voice Recording URL
Send a voice recording URL to be processed by our API.
Request Body
-
call_id
(required): Unique identifier for the call -
agent
(required): The agent ID as shown on your dashboard -
voice_recording_url
(required): URL to the call recording audio file -
call_ended_reason
(optional): Reason for call termination -
customer_number
(optional): Phone number of the customer -
transcript_json
(required): JSON object containing the transcript of the call. Can be in Vocera, Vapi or Retell format -
metadata
(optional): Dictionary with additional data -
dynamic_variables
(optional): Dictionary of dynamic variables and values. These values will replace variables in double curly braces in the agent description.
Method 2: Using a Voice Recording File
Upload an audio file directly in the request.
Request Body
-
call_id
(required): Unique identifier for the call -
agent
(required): The agent ID as shown on your dashboard -
voice_recording
(required): Audio file of the call recording -
call_ended_reason
(optional): Reason for call termination -
customer_number
(optional): Phone number of the customer -
transcript_json
(required): JSON object containing the transcript of the call. Can be in Vocera, Vapi or Retell format -
metadata
(optional): Dictionary with additional data -
dynamic_variables
(optional): Dictionary of dynamic variables and values. These values will replace variables in double curly braces in the agent description.