From Bright Pattern Documentation
Jump to: navigation, search
Tracy (talk | contribs)
No edit summary
Tracy (talk | contribs)
No edit summary
Line 1: Line 1:
<translate>
<translate>
= General Information About the Out-page JS API=
= General Information About the Embedded Agent Desktop API =
The Out-page JS API is a browser-based JavaScript API that allows a webpage to communicate with the Bright Pattern Agent Desktop application embedded on that page in iframe.
The Embedded Agent Desktop API is used for requesting for information about agent states and interactions, as well as controlling agent and supervisor login, status, call flow, call recordings, transfers, and outbound dialing.


With this API, you can:
The methods and events of the API are specified in the [[Embedded-agent-desktop-api-specification/Purpose |  Embedded Agent Desktop API Specification]].
* Request information about agent states and interactions
* Request agent routing state change
* Dial numbers
* Transfer calls
* Complete interactions
* Terminate interactions
* Control call recordings
* Request information about agent login, status, and call flow


== Supported Methods ==
== Supported Methods ==
The Out-page JS API supports the following types of methods:
The Embedded Agent Desktop API supports the following types of methods: agent state, dialing and transfer, completing and terminating an interaction, and call recordings control.


Agent State methods are used to request an agent's state and interaction information, as well as to change an agent's state.
'''Agent State''' methods are used to request an agent's state and interaction information, as well as to change an agent's state.
* [[Embedded-agent-desktop-sdk-specification/Methods/getState | getState]]
* [[Embedded-agent-desktop-api-specification/Methods/getState | getState]]
* [[Embedded-agent-desktop-sdk-specification/Methods/setStatus | setStatus]]
* [[Embedded-agent-desktop-api-specification/Methods/setStatus | setStatus]]


Dialing and Transfer methods are used for dialing phone numbers and transferring calls.
'''Dialing and Transfer''' methods are used for dialing phone numbers and transferring calls.
* [[Embedded-agent-desktop-sdk-specification/Methods/dialNumber | dialNumber]]
* [[Embedded-agent-desktop-api-specification/Methods/dialNumber | dialNumber]]
* [[Embedded-agent-desktop-sdk-specification/Methods/selectService | selectService]]
* [[Embedded-agent-desktop-api-specification/Methods/selectService | selectService]]
* [[Embedded-agent-desktop-sdk-specification/Methods/singleStepTransfer | singleStepTransfer]]
* [[Embedded-agent-desktop-api-specification/Methods/singleStepTransfer | singleStepTransfer]]
* [[Embedded-agent-desktop-sdk-specification/Methods/singleStepConference | singleStepConference]]
* [[Embedded-agent-desktop-api-specification/Methods/singleStepConference | singleStepConference]]


Completing and Terminating an Interaction methods are used for completing and terminating interactions.
'''Completing and Terminating an Interaction''' methods are used for completing and terminating interactions.
* [[Embedded-agent-desktop-sdk-specification/Methods/setDisposition |  setDisposition]]
* [[Embedded-agent-desktop-api-specification/Methods/setDisposition |  setDisposition]]
* [[Embedded-agent-desktop-sdk-specification/Methods/terminateInteraction |  terminateInteraction]]
* [[Embedded-agent-desktop-api-specification/Methods/terminateInteraction |  terminateInteraction]]
* [[Embedded-agent-desktop-sdk-specification/Methods/completeInteraction |  completeInteraction]]
* [[Embedded-agent-desktop-api-specification/Methods/completeInteraction |  completeInteraction]]
* [[Embedded-agent-desktop-sdk-specification/Methods/completeInteractionWithDisp |  completeInteractionWithDisp]]
* [[Embedded-agent-desktop-api-specification/Methods/completeInteractionWithDisp |  completeInteractionWithDisp]]


Call Recordings Control methods are used for controlling call recordings and getting the status of call recordings.  
'''Call Recordings Control''' methods are used for controlling call recordings and getting the status of call recordings.  
* [[Embedded-agent-desktop-sdk-specification/Methods/muteCallRecordings |  muteCallRecordings()]]
* [[Embedded-agent-desktop-api-specification/Methods/muteCallRecordings |  muteCallRecordings()]]
* [[Embedded-agent-desktop-sdk-specification/Methods/unmuteCallRecordings |  unmuteCallRecordings()]]
* [[Embedded-agent-desktop-api-specification/Methods/unmuteCallRecordings |  unmuteCallRecordings()]]
* [[Embedded-agent-desktop-sdk-specification/Methods/getCallRecordingStatusCallback |  getCallRecordingStatus(callback)]]
* [[Embedded-agent-desktop-api-specification/Methods/getCallRecordingStatusCallback |  getCallRecordingStatus(callback)]]
* [[Embedded-agent-desktop-sdk-specification/Methods/startCallRecordingCallback |  startCallRecording(callback)]]
* [[Embedded-agent-desktop-api-specification/Methods/startCallRecordingCallback |  startCallRecording(callback)]]
* [[Embedded-agent-desktop-sdk-specification/Methods/stopCallRecordingCallback |  stopCallRecording(callback)]]
* [[Embedded-agent-desktop-api-specification/Methods/stopCallRecordingCallback |  stopCallRecording(callback)]]
* [[Embedded-agent-desktop-sdk-specification/Methods/muteCallRecordingCallback |  muteCallRecording(callback)]]
* [[Embedded-agent-desktop-api-specification/Methods/muteCallRecordingCallback |  muteCallRecording(callback)]]
* [[Embedded-agent-desktop-sdk-specification/Methods/unmuteCallRecordingCallback |  unmuteCallRecording(callback)]]
* [[Embedded-agent-desktop-api-specification/Methods/unmuteCallRecordingCallback |  unmuteCallRecording(callback)]]
 
For more information, see section [[Embedded-agent-desktop-api-specification/Methods/Overview |  Methods]].


== Supported Events ==
== Supported Events ==
Agent Login events are used for showing whether an agent is logged in or out of Agent Desktop.
The Embedded Agent Desktop API supports the following types of events: agent login, agent status, and call flow.
* [[Embedded-agent-desktop-sdk-specification/Events/onAgentLoginCallback| onAgentLogin(callback)]]
 
Agent Status events are used for retrieving an agent's state and reason.
* [[Embedded-agent-desktop-sdk-specification/Events/onStatusChangeCallback| onStatusChange(callback)]]


Call Flow events are used for getting information about active interactions and completed interactions.
'''Agent Login''' events are used for showing whether an agent is logged in or out of Agent Desktop.
* [[Embedded-agent-desktop-sdk-specification/Events/AddInteractionRenderedHandlerCallback |  addInteractionRenderedHandler(callback)]]
* [[Embedded-agent-desktop-api-specification/Events/onAgentLoginCallback| onAgentLogin(callback)]]
* [[Embedded-agent-desktop-sdk-specification/Events/AddInteractionCompletedHandlerCallback | addInteractionCompletedHandler(callback)]]


== Syntax ==
'''Agent Status''' events are used for retrieving an agent's state and reason.
The syntax for all the methods and events in this specification includes the object ''window.bpspat.api''.  
* [[Embedded-agent-desktop-api-specification/Events/onStatusChangeCallback| onStatusChange(callback)]]
This object is created when the script file is included in an external webpage as shown:


<script type="text/javascript" src="https://YOUR_AGENT_DESKTOP_WEB_SERVER/agentdesktop/app/lib/servicepattern-sdk-v1.js"></script>
'''Call Flow''' events are used for getting information about active interactions and completed interactions.
* [[Embedded-agent-desktop-api-specification/Events/AddInteractionRenderedHandlerCallback |  addInteractionRenderedHandler(callback)]]
* [[Embedded-agent-desktop-api-specification/Events/AddInteractionCompletedHandlerCallback |  addInteractionCompletedHandler(callback)]]




Note that in the script source, you replace ''YOUR_AGENT_DESKTOP_WEB_SERVER'' with your actual web server.
For more information, see section [[Embedded-agent-desktop-api-specification/Events/Overview |  Events]].






</translate>
</translate>

Revision as of 21:15, 25 March 2019

<translate>

General Information About the Embedded Agent Desktop API

The Embedded Agent Desktop API is used for requesting for information about agent states and interactions, as well as controlling agent and supervisor login, status, call flow, call recordings, transfers, and outbound dialing.

The methods and events of the API are specified in the Embedded Agent Desktop API Specification.

Supported Methods

The Embedded Agent Desktop API supports the following types of methods: agent state, dialing and transfer, completing and terminating an interaction, and call recordings control.

Agent State methods are used to request an agent's state and interaction information, as well as to change an agent's state.

Dialing and Transfer methods are used for dialing phone numbers and transferring calls.

Completing and Terminating an Interaction methods are used for completing and terminating interactions.

Call Recordings Control methods are used for controlling call recordings and getting the status of call recordings.

For more information, see section Methods.

Supported Events

The Embedded Agent Desktop API supports the following types of events: agent login, agent status, and call flow.

Agent Login events are used for showing whether an agent is logged in or out of Agent Desktop.

Agent Status events are used for retrieving an agent's state and reason.

Call Flow events are used for getting information about active interactions and completed interactions.


For more information, see section Events.


</translate>

< Previous | Next >