A handler for the event OnRequestByREST detects emergency situations and returns HTTP code 403 Forbidden.

 

The reply contains JSON object:


{"Error":1}

 

Error description

Number

Description

1

 

REST_API_ERROR_TELEGRAM_SCRIPT_NOT_FOUND

event handler does not contain the script "Telegram";

2

REST_API_ERROR_TELEGRAM_SCRIPT_DISABLED

script "Telegram" disabled;

3

REST_API_ERROR_INVALID_SCRIPT_RESULT

script returned incorrect JSON object;

4

REST_API_ERROR_SCRIPT_TIMED_OUT

script executed for too long and was disabled by the system;

5

REST_API_ERROR_SCRIPT_SYNTAX

syntax error in the script text. View logs;

6

REST_API_ERROR_SCRIPT_RUNTIME

error during script execution. View logs;

7

REST_API_ERROR_SCRIPT_NO_ONREQUESTBYREST

event handler does not contain the script with this name;

8

REST_API_ERROR_SCRIPT_INVALID_ONREQUESTBYREST

script text contains modified function "OnRequestByREST", incorrect type or set of parameters.