This socket event is emitted by Spaces after successful pairing. It is intended for the Room applications.

Payload Parameters

NameDescriptionJSON typeRequiredDefault Value
isPairingAuthorizedPairing resultBooleanYes
ChannelSpace details:
  • type: (String) 'topic'
  • _id: (String) unique identifier of the space
ObjectYes
AuthorizerAuthorizer details:
  • type: (String) authorizer type
  • _id: (String) unique identifier of the authorizer
  • display: (String) display name of the authorizer
  • username: (String) username of the authorizer
ObjectYes
pairingInfoPairing information:
  • pairingCode: (String) Pairing code
  • appId: (String) App ID
  • pairingTime: (Date) The moment of pairing
ObjectYes
sipInfoSIP Information:
  • sipURL: (String)
ObjectYes
accessTokenToken information:
  • token
  • type
  • expires
ObjectYes
appApp information:
  • _id
  • type
  • displayname
  • username
  • picture_url
  • role
ObjectYes

Authorization

Subscribed to the channel.

Example

socketConnection.emit('APP_PAIRING_AUTHORIZED', payload);

Payload

{
    "channel": {
        "type": "TOPIC",
        "_id": "TOPIC_ID"
        "isPrivate": "true"
    },
    "authorizer": {
        "type": "user",
        "_id": "USER_ID",
        "display": "Avaya Test User",
        "username": "tester@avaya.com"
    },
    "pairing_info": {
        "pairingcode": "BI89A",
        "app_id": "GQ6KK8H1G99X43CD",
        "pairing_time": "2019-10-08T18:29:06.920Z"
    },
    "sipInfo": {
        "sipURI": "sips:_PT_d8f4deb6c34833a4af30f37ac2f926fafe1b8640411e7ce556f0db0896655ecb@spaces.sip.mpaas.avayacloud.com:5061"
    },
    "accessToken": {
        "token": "94c8aa2452bccd82ee129b46f7c4be79",
        "type": "sat", //Bearer, jwt, custom
        "scope": ["space.read", "space.write", "meeting.read", "meeting.write", "app.profile", "authorizer.profile", "space.join"]
        "expires": 432000 // Expiry time in seconds
    },
    "app": {
        "_id": "APP-ID",
        "displayname": "APP-DISPLAY-NAME"
        "username": "APP-USER-NAME"
        "type": "app"
        "picture_url": "APP-PICTURE-URL"
        "role": "guest"
    }
}