End a conversation with an individual participant

Method disconnect.leg
API version v4.0
Description The method allows you to disconnect individual participants in a conversation. The unique identifier of each conversation participant can be obtained using the list.calls method or the notification server
Return to list of methods

End of arm contact (see methods start.employee_call, start.scenario_call, start.informer_call, start.vnumber_call) causes the entire call session to end

"List of errors common to all methods"

Request parameters

Title Type Required Description
access_token string yes Authentication session key
call_session_id number yes A unique call session identifier that can be received in a response message when calling the start.informer_call, start.vnumber_call, start.scenario_call, start.employee_call methods using the notification server or DATA API.
leg_id number yes A unique identifier for a conversation participant, which can be obtained through notification servers.

Example request```json

{ "jsonrpc": "2.0", "method": "disconnect.leg", "id": "req1", "params": { "access_token": "2fRN4g217ca0b4224a67988aff3e584f91964a692045415f36fa66146f5a3c1ae1f6093d", "call_session_id": 2875654, "leg_id": 9875 } }

#### Sample answer```json
{
  "jsonrpc": "2.0",
  "id": "req1",
  "result": {
    "data": {
      "success": "true"
    }
  }
}

List of returned errors

Error text Error code Error mnemonics Description
The call's leg not found -32602 leg_not_found

See also section "List of errors common to all methods"