curl --request PATCH \
--url https://omni-api.sendblue.com/calls/{call_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "completed"
}
'{
"id": "<string>",
"direction": "inbound",
"status": "queued",
"to": "<string>",
"from": "<string>",
"parent_call_id": "<string>",
"answered_by": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z",
"duration_seconds": 123,
"price": {
"amount_micro_usd": 7900,
"currency": "USD"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": {
"code": "invalid_request",
"message": "Unknown field",
"details": {
"field": "colour"
}
}
}Redirect a call in progress, or end it.
Exactly one change per request. {"status": "canceled"} ends a call
that has not been answered; {"status": "completed"} ends it in any
state; twiml, or url with an optional method, replaces the
instructions of a call in progress.
Required permission: calls:write. Accepted credentials: a signed-in person, an API key, the account token.
PATCH
/
calls
/
{call_id}
curl --request PATCH \
--url https://omni-api.sendblue.com/calls/{call_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "completed"
}
'{
"id": "<string>",
"direction": "inbound",
"status": "queued",
"to": "<string>",
"from": "<string>",
"parent_call_id": "<string>",
"answered_by": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z",
"duration_seconds": 123,
"price": {
"amount_micro_usd": 7900,
"currency": "USD"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": {
"code": "invalid_request",
"message": "Unknown field",
"details": {
"field": "colour"
}
}
}Authorizations
personbearerlegacyKeyId & legacyKeySecret
Body
application/json
Response
The call after the change was recorded.