The Live Assist for Microsoft Dynamics 365 USD chat control can call or receive the following:
You can enable the USD debugger in order to experiment and find out more about each of these action calls and events.
See the following articles by Neil Parkhurst:
Using the debugger to get or set the presence state
- When the agent user is online, you can use the debugger to select the Chat Control and the GetAllPresenceStates action.
- Data Parameters > All Presence States returns the following available states:
- Online
- Back Soon
- Away
- You can also use the debugger to test actions. Pass JSON in to call the SetPresenceState action. The Action Calls tab provides the Status Changed event, and the agent's status is set to Back Soon.
Video summary
Actions
Action | Parameters | Comments |
---|---|---|
SendMessage | message | The message to send. |
SendInternalMessage | message | The message to send. |
WriteMessage | message | The message to send. |
ReadLastMessage | chatSessionId | The ID of the chat session to read the last message from. |
ReadChatContext | chatSessionId | The ID of the chat session to read the context from. |
SwitchChat | chatSessionId | The ID of the chat session to switch to. |
GetAllPresenceStates | ||
GetCurrentState | ||
SetPresenceState | presence | The state to switch to. JSON object. Must be one of the states returned by GetAllPresenceStates. |
GetChatState | chatSessionId | The ID of the chat session to get the state from. |
AttachChatToSession | Attaches the currently selected chat to the currently selected USD session. | |
GetMaxNumberOfChatsAllowed | ||
GetCurrentActiveChatCount | ||
AssociateContactToChat | contactInfo | The contact data. |
chatSessionId | The ID of the chat session. | |
GetActiveChatId | ||
CobrowseClosed | ||
GetChatContextUrl | ||
SwitchOrCreateSession | chatSessionId | Either switches to the USD session associated with the specified chat (or the active chat if none is specified), or associates the specified chat with the currently active USD session. The chat session in question, defaults to the current chat. |
IsSessionCreate | If true, associate the current USD session with the specified chat session, otherwise switch to the USD session associated with the specified chat. | |
FocusApplication | RedirectUrl | |
ApplicationName | ||
NavBarEnabled | ||
RefreshData | ||
UpdateContext | LogicalName | |
Id | ||
ShowOutside | url | |
RefreshChatContextData | ApplicationName | |
chatSessionId | ||
CacheUpdate | ||
ReadTranscript | chatSessionId | |
ReadCustomerMessages | chatsessionid |
Events
Event | Parameters | Comments |
---|---|---|
WidgetReady | Success (boolean) | Fired when an agent has logged in and the agent widget is initialized. The Presence Control had loads after this event.
|
StatusChanged | { oldStatus: oldStatus, newStatus: newStatus } | Fired when the agent status changes. |
PendingChatCountChanged |
{ oldCount: X, newCount: Y } |
Fired when the number of chats in the queue changes |
AgentDisconnected | Fired when the agent loses connectivity | |
OpeningNewChat | chatContext | Fired when the agent takes a chat. |
ChatEnded | chatId | Fired when the chat ends |
ChatMessageReceived | chatId | Fired when a message is received. Note: This event is not triggered by messages sent by the agent. |
MaxChatCountReached | Fired when the agent reaches the maximum number of concurrent chats configured. Note: This event is not executed if the agent is configured to take an unlimited number of concurrent chats. |
|
CobrowseInitiated | { chatId: chatId, cobrowseUrl: cobrowseUrl } | Fired when the agent starts a co-browse or shortcode request. |
CloseCobrowse | Fired when the co-browse session ends. | |
PopOut | Fired when the agent app is popped out into a separate window. | |
PopIn | Fired when the Pop in button is clicked when the agent app is displayed in a separate window (is popped out) | |
ChatSessionSwitch | { OldChatId: oldId, NewChatId: newId } | Fired when the active chat changes in the agent app—this can happen when the agent selects another chat, or when the active conversation is closed. |
OpenContact | contactUrl | Fired when the agent is in an authenticated chat and clicks the visitor's name on the top bar of the agent app. |
OpenChatActivity | activityUrl | Fired when the Open chat activity button is clicked in the agent app, or when the agent has the Auto-open chat activity option selected and they grab a chat. |
OpenKnowledgeBase | Fired when the the agent performs a knowledge base search in the agent app. | |
CreateCase | Fired when the agent opens the bottom bar menu item Create > Case. | |
CreateContact | Fired when the agent clicks the toolbar + button. | |
ChatActivityCreated | { activityId: activityId, chatId: chatId } | Fired a few seconds after opening a chat, when the chat activity is created. |
OpenChatContextWebResource | { chatId: chatId, chatContextData: chatContextData } | Fired when the agent clicks the link to open the chat context. |
ChatContextWebResourceDataUpdated | { chatId: chatId, chatContextData:chatContextData } | Fired usually 30–60 seconds after creating the chat activity, when the wait time data is populated in the chat context. |
CloseVoice | Called when a Voice and Video escalation is terminated | |
Voice Initiated | url | Called when a Voice and Video Escalation is initiated |
CreateEntity | entityFormURL, entityId | Called when selecting an entity with the /n command other than Case |
EngagementAttributesAvailable | chatContext | Fired when the agent takes a chat. |