Agent Operations
The agent operations of the Call Recording API are asynchronous operations. Each operation has a corresponding notification which provides the state of the operation. Call recording operations are performed via a POST to the /me/calls/{id} URI with the operationName attribute set as described in the table below.
Operation name | Required Attributes | Description |
---|---|---|
StartCallRecording | n/a | Starts call recording. Recording stops when the call is completed or "StopCallRecording" is called either on the call or on the device. |
StopCallRecording | n/a | Stop recording the specified phone call. |
PauseCallRecording | n/a | Temporarily stops recording the specified phone call. |
ResumeCallRecording | n/a | Resumes recording the specified phone call. |
Notifications
The client application can subscribe to the standard call notifications topic /notifications/me/calls to receive recording event notifications. In contact centers where call recording is enabled, additional call recording state events will be sent when call recording state changes. The following attributes will be present in a call recording state change notification:
Attribute Name | Value type | Description |
---|---|---|
notificationType | String | Call recording state notifications will always be of type "CallRecordingStateChange." |
call | Call resource | The call resource whose state has changed (the actual state will be specified in the call object -- see below). |
API Extensions
The attribute recordingState will be added to the call resource. Its possible values are:
- Recording: The call is currently being recorded
- Paused: Recording is currently paused.
- Stopped: Recording has been stopped.
In addition, the call's capabilities will be extended with call recording operations. The capabilities list will contain the names of call recording operations that are available in the current recording state.
Examples
Start call recording:
Request:
POST http://localhost:8080/api/v2/me/calls/0071022ec8ac8056 { "operationName": "StartCallRecording" }
Response:
{ "statusCode": 0 }
Event:
{ "data": { "messageType": "CallStateChangeMessage", "call": { "id": "0071022ec8ac8056", "state": "Established", "callUuid": "00RV9H7S6O8V3BSHAG7GK2LAES00002M", "deviceUri": "http://127.0.0.1:8080/api/v2/devices/55b8023d-573d-48d3-b4ac-e29ba3c5861d", "uri": "http://127.0.0.1:8080/api/v2/me/calls/0071022ec8ac8056", "participants": [ "5000" ], "participantsInfo": [ { "country": { "name": "", "code": "", "callingCode": "" }, "formattedPhoneNumber": "5000", "location": null, "E164digits": "5000", "isValidNumber": false } ], "ani": "5000", "dnis": "5001", "callType": "Internal", "capabilities": [ "DeleteUserDataPair", "SingleStepTransfer", "InitiateConference", "InitiateTransfer", "UpdateUserData", "Hold", "Hangup", "DeleteUserData", "SingleStepConference", "SendDtmf", "AttachUserData", "PauseCallRecording", "StopCallRecording" ], "userData": { "GSIP_RECORD": "ON", "IW_CaseUid": "8dfca5ac-ed84-4f9a-d902-8ef3c2faad81", "IW_BundleUid": "ba431089-f52b-4ce2-0658-f8bdfdfe3034", "GSIP_REC_FN": "00RV9H7S6O8V3BSHAG7GK2LAES00002M_5001_5000_5001_2013-08-09_21-11-22_hpe-voicevm-84.genesyslab.com__%3Ccont_center_id%3E" }, "duration": "106", "mute": "Off", "recordingState": "Recording" }, "phoneNumber": "5001", "notificationType": "CallRecordingStateChange" }, "channel": "/v2/me/calls" }
Pause
Request:
POST http://localhost:8080/api/v2/me/calls/0071022ec8ac8056 { "operationName": "PauseCallRecording" }
Response:
{ "statusCode": 0 }
Event:
{ "data": { "messageType": "CallStateChangeMessage", "call": { "id": "0071022ec8ac8056", "state": "Established", "callUuid": "00RV9H7S6O8V3BSHAG7GK2LAES00002M", "deviceUri": "http://127.0.0.1:8080/api/v2/devices/55b8023d-573d-48d3-b4ac-e29ba3c5861d", "uri": "http://127.0.0.1:8080/api/v2/me/calls/0071022ec8ac8056", "participants": [ "5000" ], "participantsInfo": [ { "country": { "name": "", "code": "", "callingCode": "" }, "formattedPhoneNumber": "5000", "location": null, "E164digits": "5000", "isValidNumber": false } ], "ani": "5000", "dnis": "5001", "callType": "Internal", "capabilities": [ "DeleteUserDataPair", "SingleStepTransfer", "InitiateConference", "InitiateTransfer", "UpdateUserData", "Hold", "Hangup", "DeleteUserData", "SingleStepConference", "SendDtmf", "AttachUserData", "ResumeCallRecording", "StopCallRecording" ], "userData": { "GSIP_RECORD": "PAUSED", "IW_CaseUid": "8dfca5ac-ed84-4f9a-d902-8ef3c2faad81", "IW_BundleUid": "ba431089-f52b-4ce2-0658-f8bdfdfe3034", "GSIP_REC_FN": "00RV9H7S6O8V3BSHAG7GK2LAES00002M_5001_5000_5001_2013-08-09_21-11-22_hpe-voicevm-84.genesyslab.com__%3Ccont_center_id%3E" }, "duration": "141", "mute": "Off", "recordingState": "Paused" }, "phoneNumber": "5001", "notificationType": "CallRecordingStateChange" }, "channel": "/v2/me/calls" }
Resume
Request:
POST http://localhost:8080/api/v2/me/calls/0071022ec8ac8056 { "operationName": "ResumeCallRecording" }
Response:
{ "statusCode": 0 }
Event:
{ "data": { "messageType": "CallStateChangeMessage", "call": { "id": "0071022ec8ac8056", "state": "Established", "callUuid": "00RV9H7S6O8V3BSHAG7GK2LAES00002M", "deviceUri": "http://127.0.0.1:8080/api/v2/devices/55b8023d-573d-48d3-b4ac-e29ba3c5861d", "uri": "http://127.0.0.1:8080/api/v2/me/calls/0071022ec8ac8056", "participants": [ "5000" ], "participantsInfo": [ { "country": { "name": "", "code": "", "callingCode": "" }, "formattedPhoneNumber": "5000", "location": null, "E164digits": "5000", "isValidNumber": false } ], "ani": "5000", "dnis": "5001", "callType": "Internal", "capabilities": [ "DeleteUserDataPair", "SingleStepTransfer", "InitiateConference", "InitiateTransfer", "UpdateUserData", "Hold", "Hangup", "DeleteUserData", "SingleStepConference", "SendDtmf", "AttachUserData", "PauseCallRecording", "StopCallRecording" ], "userData": { "GSIP_RECORD": "ON", "IW_CaseUid": "8dfca5ac-ed84-4f9a-d902-8ef3c2faad81", "IW_BundleUid": "ba431089-f52b-4ce2-0658-f8bdfdfe3034", "GSIP_REC_FN": "00RV9H7S6O8V3BSHAG7GK2LAES00002M_5001_5000_5001_2013-08-09_21-11-22_hpe-voicevm-84.genesyslab.com__%3Ccont_center_id%3E" }, "duration": "588", "mute": "Off", "recordingState": "Recording" }, "phoneNumber": "5001", "notificationType": "CallRecordingStateChange" }, "channel": "/v2/me/calls" }
Stop
Request:
POST http://localhost:8080/api/v2/me/calls/0071022ec8ac8056 { "operationName": "StopCallRecording" }
Response:
{ "statusCode": 0 }
Event:
{ "data": { "messageType": "CallStateChangeMessage", "call": { "id": "0071022ec8ac8056", "state": "Established", "callUuid": "00RV9H7S6O8V3BSHAG7GK2LAES00002M", "deviceUri": "http://127.0.0.1:8080/api/v2/devices/55b8023d-573d-48d3-b4ac-e29ba3c5861d", "uri": "http://127.0.0.1:8080/api/v2/me/calls/0071022ec8ac8056", "participants": [ "5000" ], "participantsInfo": [ { "country": { "name": "", "code": "", "callingCode": "" }, "formattedPhoneNumber": "5000", "location": null, "E164digits": "5000", "isValidNumber": false } ], "ani": "5000", "dnis": "5001", "callType": "Internal", "capabilities": [ "DeleteUserDataPair", "SingleStepTransfer", "InitiateConference", "InitiateTransfer", "UpdateUserData", "Hold", "Hangup", "DeleteUserData", "SingleStepConference", "SendDtmf", "AttachUserData", "StartCallRecording" ], "userData": { "GSIP_RECORD": "OFF", "IW_CaseUid": "8dfca5ac-ed84-4f9a-d902-8ef3c2faad81", "IW_BundleUid": "ba431089-f52b-4ce2-0658-f8bdfdfe3034", "GSIP_REC_FN": "00RV9H7S6O8V3BSHAG7GK2LAES00002M_5001_5000_5001_2013-08-09_21-11-22_hpe-voicevm-84.genesyslab.com__%3Ccont_center_id%3E" }, "duration": "613", "mute": "Off", "recordingState": "Stopped" }, "phoneNumber": "5001", "notificationType": "CallRecordingStateChange" }, "channel": "/v2/me/calls" }