Hangup a call
Hangup call command can be used in two situation:
- Hangup an ongoing call.
- Reject an inbound call that is starting or ringing
POST
/workspaces/{workspaceId}/channels/{channelId}/calls/{callId}/hangup
Hangup a channel call
Corps de la requête
cause
string
Possible values: rejected, busy
Corps de la réponse
id
string
callId
string
callFlowId
string
status
string
command
string
conditions
array of object
Afficher les attributs enfants
conditions.variable
string
Possible values: keys, speech
conditions.operator
string
Possible values: eq, ne, ==, !=, contains
conditions.value
string
Exemple de code
curl -X POST 'https://api.bird.com/workspaces/{workspaceId}/channels/{channelId}/calls/{callId}/hangup' \
-H 'Authorization: AccessKey YOUR_ACCESS_KEY'Example 1: Hangup a call
Exemple de code
curl -X POST "https://api.bird.com/workspaces/{workspaceId}/channels/{channelId}/calls/{callId}/hangup" \
-H "Authorization: AccessKey YOUR_SECRET_TOKEN"
Exemple de code
// N/A
Exemple de code
{
"id": "db35bd0e-b5ed-4a6a-a01f-e12c2489059a",
"callId": "c47724eb-978c-46a4-96f7-fbb061ba969a",
"command": "hangup",
"status": "accepted"
}