Jump to: navigation, search

Asynchronous Telephony Operations Notifications

User

/me

Currently the following nofication will be available via the /v2/me topic:

Attribute Description Applies to notification type
notificationType

The type of notification that has been received. Possible values: 

PasswordChangeSuccessful: A password change operation has been executed successfully for the current user. User should use the new password upon next login.

PasswordChangeError: An error occurred while changing the user's password

always present
errorMessage An error message describing why the password change failed PasswordChangeError
errorCode

The error code describing the reason for failure. Possible values are:

1: Password does not meet security guidelines

2: Did not enter old password correctly

3: Internal server error

PasswordChangeError

/users

NOTE: This topic is only available to supervisor and administrator users.

Currently the following nofication will be available via the /v2/users topic:

Attribute Description Applies to notification type
notificationType

The type of notification that has been received. Possible values: 

PasswordChangeSuccessful: A password change operation has been executed successfully for the referenced user. User should use the new password upon next login.

PasswordChangeError: An error occurred while changing the referenced user's password

always present
errorMessage An error message describing why the password change failed PasswordChangeError
errorCode

The error code describing the reason for failure. Possible values are:

1: Password does not meet security guidelines

2: Did not enter old password correctly

3: Internal server error

PasswordChangeError

userUri The uri identifying the user for whom this notification is received always present
userId The id identifying the user for whom this notification is received. always present

Calls

The following notifications are available via the /v2/me/calls topic. This topic should be used to subscribe to call notifications. A call notification will have the following json attributes:

Attribute Description
call An object describing the current call. See the voice interactions section for a list of its attributes.
phoneNumber The phone number digits assigned to the device on which the call is active.
notificationType Describes the reason the for the current notification. Can have one of the following values:

StatusChange—the call's status has changed.

ParticipantsUpdated—tthe participants list for the current call have been updated.

AttachedDataChanged—the list of attached data has changed.

DtmfSent—DTMF digits have been successfully sent for this call.

In addition, if an error occurs during an attempted call control operation, the following attributes will be present:

Attribute Description
deviceUri The URI for the device on which the call is active.
errorMessage The error message describing the error that occured.
connectionId Genesys ConnID
callUuid Genesys UUID


The following example shows the structure of a CallStateChangedMessage:

{
  "data": {
    "messageType": "CallStateChangeMessage",
    "call": {
      "id": "010a0229f0cbd001",
      "state": "Dialing",
      "callUuid": "RC5FN2QK1H3IFD3CV136FELT80000001",
      "deviceUri": "http://127.0.0.1:8080/api/v2/devices/5aceae61-0b5c-4578-9477-cd352d43cb17",
      "uri": "http://127.0.0.1:8080/api/v2/me/calls/010a0229f0cbd001",
      "participants": [
        "2"
      ],
      "participantsInfo": [
        {
          "location": null,
          "country": {
            "name": "",
            "code": "",
            "callingCode": ""
          },
          "formattedPhoneNumber": "2",
          "isValidNumber": false,
          "E164digits": "2"
        }
      ],
      "ani": "1",
      "capabilities": [
        "DeleteUserDataPair",
        "UpdateUserData",
        "AttachUserData",
        "Hangup",
        "DeleteUserData",
        "SendDtmf"
      ],
      "duration": "0",
      "mute": "Off"
    },
    "phoneNumber": "1",
    "notificationType": "StatusChange"
  },
  "channel": "/v2/me/calls"
}

Devices

The topic /v2/me/devices should be used to monitor the availability of a user's devices. The following json attributes will be present:

Attribute Description
id The ID of the device that is changing state.
deviceState The state of the device. Either Active, or Inactive.
userState A structure describing the current user state for the device. This will include the state (for example, Ready/NotReady), workMode, and reason (if applicable). If the combination of state, workMode, and reason match an agent state definition, the id and displayName of that agent state definition will also be included for convenience.
doNotDisturb Off
forwardTo If forwarding calls, the number to which calls will be forwarded.

The example below shows the structure and attribution of a DeviceStateChangeMessage:

{
  "data": {
    "messageType": "DeviceStateChangeMessage",
    "devices": [
      {
        "deviceState": "Active",
        "phoneNumberUri": "http://127.0.0.1:8080/api/v2/phone-numbers/2b36d336-d502-4e46-bc92-b727913a7754",
        "id": "5aceae61-0b5c-4578-9477-cd352d43cb17",
        "userState": {
          "id": "9430250E-0A1B-421F-B372-F29E69366DED",
          "displayName": "Ready",
          "state": "Ready"
        },
        "type": "PSTNPhone",
        "model": "FakeDeviceModel",
        "vendor": "FakeDeviceVendor",
        "phoneNumber": "1",
        "country": {
          "name": "",
          "code": "",
          "callingCode": ""
        },
        "e164Number": "1"
      }
    ]
  },
  "channel": "/v2/me/devices"
}


This page was last edited on September 6, 2013, at 23:26.
Comments or questions about this documentation? Contact us for support!