Skip to content

Revoke Session

DELETE /api/sdk/session

End an agent’s embedded phone session. Call this from your backend when one of your users logs out or you need to cut off access.

Requires a Bearer API token and the call-center permission (same as Mint SDK Token).

After this, that agent cannot keep using the previous browser session. Unused tokens for that agent also stop working. A call that is already connected is not hung up. You can still create a new token for the same agent later.

Parameter Type Required Description
agent_id integer Yes Numeric id of a call-center agent that belongs to your account. Get ids from List Agents.
Terminal window
curl -X DELETE https://api.awajdigital.com/api/sdk/session \
-H "Authorization: Bearer your_api_token_here" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"agent_id": 42
}'
{
"revoked": true
}

A later Mint SDK Token for the same agent still works — this ends the current session; it does not disable the agent.

Status Code Description
401 — Missing or invalid access token
403 — Account does not have the call-center permission
404 agent_not_found Agent does not exist or belongs to another account
422 — Validation failed (agent_id missing or not a positive integer)
429 — Too many requests
{
"error": "agent not found",
"code": "agent_not_found"
}