[EVENT]

An Allocated Call Requires Scripts

A call_script_to_use event typically occurs shortly after a call is allocated to an operator. It contains details of the scripts that the operator will be presented with on the call, with up to six entries each containing an ID (indicating the type of script) and a URL (the location of the script).

The information in this event corresponds with the settings applied in the queue's Notifications tab, under the CC4Web Operator Scripts heading. There is also an option under that heading that stops this event occurring unless the operator answers the call.

Parameters

call_id number

The unique number allocated to the call by TelXL.

operator_id number The unique number associated with the target operator.
script_id_[1-6] number

Represents the type of script for this entry:

  • 0 means there is no script to show for this entry. This is the default value.
  • A positive number represents the unique ID of an Operator Script belonging to the customer who owns the queue.
  • -2 means the text exists on a page at a specific URL, but is not one of the system-defined operator scripts associated with the customer.
  • -3 means the script is based on JavaScript at a specific URL.

For example, script_id_1 might be 2500, indicating it uses an internal script with the ID 2500, whereas script_id_2 might be -2, indicating it points to an external page.

script_url_[1-6] string

Where a script is used, this contains its URL. The URL will depend on the type of script, including whether or not it was created in the admin portal.

For example, if script_id_1 is 2500, the value of script_url_1 would be something like "script_show.asp?id=2500". If script_id_2 is -2, the value of script_url_2 would be something like "https://call-control.com/script_2.html".

If any script_id is 0 (no script), the corresponding URL will be an empty string.

Example Response

Copy
{"event":{"event_type":"call_script_to_use","call_id":90210,"operator_id":5,"script_id_1":2500,"script_url_1":"script_show.asp?id=2500","script_id_2":-2,"script_url_2":"https://call-control.com/script_2.html","script_id_3":0,"script_url_3":"","script_id_4":0,"script_url_4":"","script_id_5":0,"script_url_5":"","script_id_6":0,"script_url_6":""}}