Register a web call
curl --request POST \
--url https://backend.drivehealth.ai/api/calls/web/register \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"assistant_id": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
'import requests
url = "https://backend.drivehealth.ai/api/calls/web/register"
payload = { "assistant_id": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({assistant_id: '1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d'})
};
fetch('https://backend.drivehealth.ai/api/calls/web/register', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"err": false,
"msg": "Success",
"results": {
"call_id": "3c2b1a09-8f7e-4d6c-9b8a-7d6c5b4a3f2e",
"token": "eyJEXAMPLE.LIVEKIT.TOKEN"
}
}Voice
Register a web call
Register a browser voice call and receive a LiveKit token for it. The token joins the LiveKit room for that call and nothing else. Call this from your backend and return only the token and call_id to the browser, never the organization API key. The call runs only when workspace balance, caregiver readiness, and the concurrency limit allow it; a refused call creates no record.
POST
/
api
/
calls
/
web
/
register
Register a web call
curl --request POST \
--url https://backend.drivehealth.ai/api/calls/web/register \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"assistant_id": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d"
}
'import requests
url = "https://backend.drivehealth.ai/api/calls/web/register"
payload = { "assistant_id": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({assistant_id: '1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d'})
};
fetch('https://backend.drivehealth.ai/api/calls/web/register', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"err": false,
"msg": "Success",
"results": {
"call_id": "3c2b1a09-8f7e-4d6c-9b8a-7d6c5b4a3f2e",
"token": "eyJEXAMPLE.LIVEKIT.TOKEN"
}
}Authorizations
organizationBearerorganizationApiKey
An organization API key starting with dh_, sent as Authorization: Bearer dh_your_api_key.
Body
application/json
