From Bright Pattern Documentation
No edit summary |
Updated via BpDeleteTranslateTags script |
||
| (One intermediate revision by one other user not shown) | |||
| Line 1: | Line 1: | ||
= addInteractionRenderedHandler(callback) = | = addInteractionRenderedHandler(callback) = | ||
Gets information about an active interaction. | Gets information about an active interaction. | ||
| Line 30: | Line 30: | ||
| '''Example''' | | '''Example''' | ||
|- | |- | ||
| | | item_id | ||
| string | | string | ||
| Interaction ID | | Interaction ID | ||
| Line 70: | Line 70: | ||
} | } | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Latest revision as of 04:02, 29 May 2024
addInteractionRenderedHandler(callback)
Gets information about an active interaction.
Request
Syntax
window.bpspat.api.addInteractionRenderedHandler(callback)
callback = function(data) {
}
Arguments
| Parameter | Type | Description |
| callback | function | JavaScript method executed when API method request is completed |
Response
The response object may contain the following fields.
| Name | Data Type | Description | Example |
| item_id | string | Interaction ID | "121212121" |
| global_id | string | Global interaction ID (GIID) | "asd234asdf234df" |
| phone_number | string | Customer phone number | "4151234567" |
| service | string | Name of the service handling the interaction | "Inbound Voice" |
| screenpop_data | string | Information shown on screen-pop | "Case: 123123" |
Example
{
"command": "INTERACTION_RENDERED",
"data": {
"item_id": "5AA90906-ECB9-4597-8F98-5A9D859AB3D9",
"global_id": "A39ECF09-28A2-4F25-8681-F4D76FE1288B",
"service": "Maintenance Renewal_MS",
"phone_number": "19294599406",
"screenpop_data": {
}
}
}