Jump to: navigation, search

Invite

This operation is part of the SMS Session API section of the Web Services API.

Overview

This allows an agent to invite another agent to a conference.

The customer will be aware of the presence of all agents in the conference.

Agents have the ability to communicate with the customer, or they can communicate with other agents without the customer seeing the communications.

For the 'Invite through queue' feature InternalConferenceInvite value should be added to the InteractionSubtype business attribute.

Request URL /api/v2/me/smssessions/{id}
HTTP Method POST
Required Features api-multimedia

Parameters

Parameter Value
operationName Invite
targetUri The user uri to invite or queue uri to invite through.

Mandatory, if targetPath is not specified.

targetPath The user path to invite or queue path to invite through.

Mandatory, if targetUri is not specified.

Sample

Request

POST api/v2/smssessions/0000Na9B26EF006E
{
  "operationName": "Invite",
  "userUri": "http://localhost:8080/api/v2/contacts/429a55994ef64991a77acb77c1cf9041"
}

Response

{
  "statusCode": 0,
  "referenceId": 35
}

Notification

Successful

First Notification

{
    u'notificationType': u'ParticipantsUpdated',
    u'messageType': u'SMSsessionStateChangeMessage',
    u'smssession': {
        u'participants': [
            {
                u'nickname': u'TestName',
                u'type': u'Agent',
                u'participantId': u'009052CB05C900EA'
            },
            {
                u'nickname': u'BFriend',
                u'type': u'Agent',
                u'participantId': u'009052CB05CA00EB'
            },
            {
                u'nickname': u'FirstL',
                u'type': u'Customer',
                u'participantId': u'009052CB056C00E5'
            },
            {
                u'nickname': u'TestName',
                u'type': u'Agent',
                u'participantId': u'009052CB057100E7'
            }
        ],
        u'state': u'Chatting',
        u'id': u'0000Na9B26EF006E',
        u'capabilities': [
            u'Transfer',
            u'Leave',
            u'Invite',
            u'Consult',
            u'SetInFocus',
            u'SetDisposition',
            u'AttachUserData',
            u'DeleteUserData',
            u'UpdateUserData',
            u'SendToAgents',
            u'SendStartTypingToAgentsNotification',
            u'SendStopTypingToAgentsNotification',
            u'Complete',
            u'SendMessage',
            u'SendStartTypingNotification',
            u'SendStopTypingNotification'
        ],
        u'uri': u'http: //localhost: 8080/api/v2/smssessions/0000Na9B26EF006E'
    }
}

Second Notification

{
    u'messages': [
        {
            u'index': 3,
            u'from': {
                u'nickname': u'BFriend',
                u'type': u'Agent',
                u'participantId': u'009052CB05CA00EB'
            },
            u'timestamp': u'2014-01-0612: 14: 06.007-0800',
            u'visibility': u'All',
            u'type': u'ParticipantJoined',
            u'timestampSeconds': 1389039246007L
        }
    ],
    u'notificationType': u'NewMessages',
    u'messageType': u'MessageLogUpdated',
    u'smssessionUri': u'http: //localhost: 8080/api/v2/smssessions/0000Na9B26EF006E'
}

Failed

{
    u'notificationType': u'Error',
    u'messageType': u'SMSsessionStateChangeMessage',
    u'errorMessage': u'Operationfailed',
    u'referenceId': 36,
    u'smssession': {
        u'participants': [
            {
                u'nickname': u'TestName',
                u'type': u'Agent',
                u'participantId': u'009052CB110900F5'
            },
            {
                u'nickname': u'FirstL',
                u'type': u'Customer',
                u'participantId': u'009052CB10CC00F0'
            }
        ],
        u'state': u'Chatting',
        u'id': u'0000Na9B26EF006M',
        u'capabilities': [
            u'Transfer',
            u'Leave',
            u'Invite',
            u'Consult',
            u'SetInFocus',
            u'SetDisposition',
            u'AttachUserData',
            u'DeleteUserData',
            u'UpdateUserData',
            u'Complete',
            u'SendMessage',
            u'SendStartTypingNotification',
            u'SendStopTypingNotification'
        ],
        u'uri': u'http: //localhost: 8080/api/v2/smssessions/0000Na9B26EF006M'
    }
}
This page was last edited on November 4, 2016, at 17:53.
Comments or questions about this documentation? Contact us for support!