IVR script execution management (ivrscript_runtimes)

Overview

Manages active IVR script handlers.
An IVR script handler is an algorithm interpreting an IVR script instance.

Requests

HTTP verb Endpoint Description

GET

/rest/v1/uc/ivrscript_runtimes

Getting the list of running IVR script instances

DELETE

/rest/v1/uc/ivrscript_runtimes/<id>

Stopping an IVR script instance


Getting the list of running IVR script instances

Returns the list of all IVR script handlers executed by the system in the current domain on all available sites where it is served.

Request

Table 1. Request parameters
Name Type Description

filter

object

Filter by field values.

mask

str

List of fields to output.

offset

int

Offset in the list of resources to output.

limit

int

Maximum number of resources in the list.

order

array<object|str>

Sorting order of resources in the list.

flat

bool

Transformation of composite fields to flat form.

Example request
GET /rest/v1/uc/ivrscript_runtimes HTTP/1.1

Response

Returns all discovered active running IVR script handlers.

Table 2. Field description:
Field Description

id

Script handler identifier

site

Site where the handler is running.

node

Node within which the handler is running.

domain

Script domain.

type

Script type.

code

Code of the running script. If the source script passed control to a nested script, the nested script code is returned.

name

Name of the running script. If the source script passed control to a nested script, the nested script name is returned.

starttime

Handler start date and time in RFC3339 format in UTC.

Example response
HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

[
  {
    "id": "244f84aa-0624-e639-8061-a80000000006",
    "site": "SITE1",
    "node": "site1_h6@192.168.0.12",
    "domain": "test.rootdomain.ru",
    "type": "ivr",
    "code": "player",
    "name": "TEST PLAY",
    "starttime": "2019-11-05T08:36:40Z"
  },
  {
    "id": "6b3ba923-0624-e8c9-6bee-b00000000008",
    "site": "SITE1",
    "node": "site1_h8@192.168.0.12",
    "domain": "test.rootdomain.ru",
    "type": "ivr",
    "code": "welcome",
"name": "Main Script",
    "starttime": "2019-11-05T11:31:34Z"
  }
]

Stopping an IVR script instance

Forcibly terminates the script handler.

If the currently executing script has a post-processing branch corresponding to the completion type External call stop, control is passed to it and the handler continues executing. In this case another DELETE API request is required to fully stop the handler.

Request

Example request
DELETE /rest/v1/uc/ivrscript_runtimes/244f84aa-0624-e639-8061-a80000000006 HTTP/1.1

Response

Example response
HTTP/1.1 204 No Content

See also