This page gives an example to fetch match count of Action Rules, Routing Rules and SLA Rules.

Rule Types

ACTION_RULE_MATCH_COUNT ROUTING_RULE_MATCH_COUNT SLA_1_RULE_MATCH_COUNT SLA_2_RULE_MATCH_COUNT SLA_1_RULE_MISS_COUNT SLA_2_RULE_MISS_COUNT

Fetch

This API call returns a aggregated object of rule matches https://developers.chatvisor.com/#operation/getUsingPOST_5

Request

Request with Filter

Response

POST https://api.chatvisor.com/rest/v1/report/rule/?access_token=<TOKEN>

BODY:
{
  "metrics": [
    {
      "metricName": "ACTION_RULE_MATCH_COUNT"
    }
  ],
  "dateFilter": {
    "grouping": "TODAY"
  }
}

The ID of a rule can be found in the backend of TeamViewer Engage within the details of the Action Rules/SLA rules... menu.