LogoLogo
  • What is Itgrix
  • Contacts
  • Our story
  • Connector installation
    • System requirements
    • Itgrix for Bitrix24 and Asterisk
      • How to perform offline authorization
      • How to obtain a license offline
      • Configuring the connector to work in a closed network
      • Call tests
    • Itgrix for Kommo and Asterisk
      • Restricted mode setting features
      • Call card
      • Call tests
  • Additional functions
    • Automatic call transfer to responsible manager
    • Setting up click-to-call features
      • Features of customization after Bitrix24 23.300.0 update
    • Autoreplacement for phone numbers
    • How to view employee call statistics in Bx24
    • FMC number recognition
    • Configuring WebRTC in Asterisk (FreePBX)
    • Itgrix AsterPhone for Bitrix24
    • Itgrix AsterPhone for Kommo
  • For admins
    • Running an additional copy of the module
    • Deploying a module backup
    • Call processing for the period
    • Examples of the structure of registered calls from CEL
    • Wrong time in created cases in Bitrix24
    • SSH access
    • Useful commands
    • Script to test the module service
    • Changing login and password to enter the admin panel
    • Module files
    • Status monitoring
    • Application update
    • In the CEL table, there is no internal employee number in the cid_num column
    • How to fix click-to-call
    • Custom SSL certificates for https requests
    • Examples of configuring WSS connections
    • Converting recordings to MP3 before sending to Bitrix24
    • How to fix call recording problems
    • Install and configure CEL
    • B24 authorization bugfix
  • Useful customizations (any CRM)
    • Audio file name customization
    • Call data (call_full) in customizations
    • Change the number / context for calling to asterisk
    • Change phone number before sending data to CRM
    • Black and white lists
  • Useful customizations itgrix_bx (Bitrix24)
  • Useful customizations itgrix_kmo (Kommo)
  • FAQ
    • How to pay
    • How to check licence status
    • Differences in connection to B24 via SIP-connector and Itgrix
    • How to turn off the display of calls in the calendar
    • How to view statistics on employee calls
    • Updating the app
    • Offline install (only for Bitrix24)
    • Offline update
    • Reliable softphones for Asterisk
    • Detail-call-statuses
  • Changelog Itgrix_bx
  • Changelog Itgrix_kommo
  • Policy of interaction with Asterisk
Powered by GitBook
On this page
  • Status monitoring
  • Examples of requests
  • Stop/restart status of the application
  • License change

Was this helpful?

  1. For admins

Status monitoring

PreviousModule filesNextApplication update

Last updated 10 months ago

Was this helpful?

Status monitoring

Starting from versions Itgrix bx and Itgrix Kommo , an API method for checking the application status at <Asterisk IP>:8077/status is added. Periodic checks of the response to this request can be used to track the application status and automatically react to problems.

Examples of requests

The following are request examples for specific status elements with explanations of their intended use. The elements can be extracted from the response using the jq utility, a json data processor on Itgrix-compatible systems, or simply by specifying the target element in the path request parameter.

Full status data can be obtained by querying:

curl -s --digest -u <login>:<password> "<Asterisk IP>:8077/status"

Here <Asterisk IP> - is the address of the Asterisk server where the module was installed. -s - reduces the amount of intermediate output from curl. --digest -u - specifies the method of authorization. <login> and <password> - login and password for the admin panel.

The reaction that should follow upon identifying faulty states of the application is not described here and should be determined according to the user's needs.

Example of a response:

{
  "app": {
    "c2c": {
      "connected": true,
      "on": true,
      "portal": "example.bitrix24.ru",
      "stayon": false,
      "url": "https://apix.itgrix.ru:9004"
    },
    "calls_queue": {
      "calls": 0,
      "lock": "locked in 384ns"
    },
    "calls_storage": {
      "calls": 0
    },
    "crm": {
      "host": "https://example.bitrix24.ru",
      "manager": {
        "batch_queue": 0,
        "connector": {
          "app_type": "LicenseType_Subscription",
          "authseq": {
            "err": "<nil>",
            "sequences": 0
          },
          "on": true,
          "portal": "example.bitrix24.ru"
        },
        "on": true
      },
      "on": true,
      "users_cache": {
        "last_updated": "2023-05-11 13:03:55.485 +05:00",
        "phones": 39,
        "users": 120
      }
    },
    "crm_type": "bitrix",
    "customizer": {
      "enabled": true,
      "methods": {
        "customize_activity": true,
        "customize_attach_record_url": true,
        "customize_autodistribution": true,
        "customize_entity": true,
        "customize_show_call_card": true,
        "need_registration": true,
        "post_registration": true,
        "process_client_phone": true,
        "process_final_params": true,
        "process_originate_params": true,
        "process_record_file_path": true,
        "process_registration_params": true,
        "process_task_creation_params": true,
        "process_user_phone": true
      },
      "path": "/opt/itgrix_bx/customizer/customize.php",
      "timeout": 2000
    },
    "err": "<nil>",
    "license_manager": {
      "currentLicense": {
        "offline": false,
        "type": "Professional",
        "valid_till": "2025-04-15"
      },
      "on": true,
      "soft_mode": "ready"
    },
    "lock": "locked in 279ns",
    "master": {
      "general": {
        "app_err": "<nil>",
        "app_state": "",
        "app_status": "Ok",
        "app_status_updated": "2023-04-27 08:58:38.172 +05:00"
      }
    },
    "originated": 0,
    "pbx": {
      "ami": {
        "logged_in": true,
        "on": true,
        "pending_actions": 0
      },
      "cel_queue": {
        "calls": 0,
        "pending_events": 0
      },
      "db": {
        "connected": true,
        "dbConnector": {
          "on": true
        }
      },
      "fmc_cache": {
        "last_refresh": "2023-05-11 13:03:55.485 +05:00",
        "phones": 39
      },
      "last_id": 713065,
      "on": true,
      "parked": 0,
      "sql_parser": {
        "originated": 0,
        "transfer_bridges": 0
      },
      "trunks": 2
    },
    "restarting": false,
    "version": "Itgrix_bx v3.10.12"
  },
  "instance": {
    "config": "/etc/itgrix_bx/config.json",
    "index": 0,
    "log": "/var/log/itgrix_bx.log",
    "service": "itgrix_bx"
  }
}

Stop/restart status of the application

Using the queries described below, you can track when and why an application stops working.

curl -s --digest -u <login>:<password> "<Asterisk IP>:8077/status?path=app.master.general.app_state

Possible values of app_state:

  • Normal operation will return a value of "".

  • The value "stopped" is returned when the application has encountered an error preventing further operation and is waiting for user action.

  • The value "restarting" is returned while the application is restarting. This can be caused by a problem that is supposed to be resolvable by reconnecting and/or by a short pause, e.g. network problems. It can also be caused by a normal restart, e.g. when changing connection settings.

curl -s --digest -u <login>:<password> "<Asterisk IP>:8077/status?path=app.master.general.app_status" 

app_status contains the overall status of the application, which can be "Ok"/"Warning"/"Error". This is the status that is displayed at the top of the main page in admin panel. Most often it corresponds to the running/restarted/stopped status, but in some situations it can provide additional information. For example, it can help in distinguishing between a normal restart and a restart due to an error.

curl -s --digest -u <login>:<password> "<Asterisk IP>:8077/status?path=app.master.general.app_err"

app_err contains error details, based on which the error text is generated under the application status on the main page in admin panel. This element can be useful in finding out the causes of the failure.

License change

This query helps to identify if the application has switched to a license with limited functionality. This can occur not only when the license expires but also due to connection issues with the licensing server.

curl -s --digest -u <login>:<password> "<Asterisk IP>:8077/status?path=app.license_manager.currentLicense.type"

license.type returns the license type displayed at the top of the main admin page.

Possible values:

  • "Professional" - paid license with full functionality.

  • "Subscription" - subscription license with limited functionality.

  • "Free" - free license with basic functionality.

curl -s --digest -u <login>:<password> "<Asterisk IP>:8077/status?path=app.license_manager.currentLicense.valid_till"

license.valid_till contains the license expiration date (the last day on which the license is valid ) in YYYYY-MM-DD format.

3.6.0
2.13.0
available for installation