One lead with every call made to it
GET
https://server.heyrik.com/api/v1/campaigns/{id}/contacts/{contactId}Path parameters
idRequiredReplace {id} in the request URL with the value for this resource.
contactIdRequiredReplace {contactId} in the request URL with the value for this resource.
Headers
AuthorizationstringRequiredUse Bearer $HEYRIK_API_KEY with an account-scoped API key. Keep the key on your server.
Response
Explore the example values. This is not a complete response schema.
dataobjectExplore 2 properties
contactobjectExplore 8 properties
idstringExample "cct_9b1e"
phonestringExample "+919876543210"
statusstringExample "completed"
outcomestringExample "completed"
attemptsnumberExample 1
categorystringExample "hot"
variablesobjectExplore 2 properties
namestringExample "Ravi"
order_idstringExample "AC-8842"
extractedobjectExplore 1 property
callback_requestedstringExample "yes"
callsarrayExplore 1 example item
[0]objectExplore 7 properties
idstringExample "call_8eab93e5"
directionstringExample "outbound"
outcomestringExample "completed"
duration_secnumberExample 214
summarystringExample "Ravi confirmed the order and asked for a callback on Monday."
recording_urlstringExample "https://example.com/rec.mp3"
transcriptarrayExplore 1 example item
[0]objectExplore 2 properties
rolestringExample "assistant"
contentstringExample "Hi Ravi, this is Priya from Acme."
GET/campaigns/{id}/contacts/{contactId}
cURL
curl https://server.heyrik.com/api/v1/campaigns/cmp_4a19/contacts/cct_9b1e \
-H "Authorization: Bearer $HEYRIK_API_KEY"Response example
JSON
{
"data": {
"contact": {
"id": "cct_9b1e", "phone": "+919876543210", "status": "completed",
"outcome": "completed", "attempts": 1, "category": "hot",
"variables": { "name": "Ravi", "order_id": "AC-8842" },
"extracted": { "callback_requested": "yes" }
},
"calls": [
{
"id": "call_8eab93e5", "direction": "outbound", "outcome": "completed",
"duration_sec": 214, "summary": "Ravi confirmed the order and asked for a callback on Monday.",
"recording_url": "https://example.com/rec.mp3",
"transcript": [ { "role": "assistant", "content": "Hi Ravi, this is Priya from Acme." } ]
}
]
}
}Illustrative examples · No live request is sent
