Skip to main content
GET
/
parsers
/
metrics
/
usage
Get the parsers usage metrics over a period of time for a log id.
curl --request GET \
  --url https://api.eu.bronto.io/parsers/metrics/usage \
  --header 'X-BRONTO-API-KEY: <api-key>'
{
  "log_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "match_ratio": [
    {
      "name": "host123",
      "count": 124,
      "stat": "average(duration_millis)",
      "value": 50325.25,
      "quantiles": {
        "min": 691,
        "p25": 713.75,
        "p50": 796,
        "p75": 847.5,
        "p90": 1237,
        "p95": 1331,
        "p99": 1331,
        "p999": 1331,
        "max": 1331
      },
      "series_resolution_ms": 60000,
      "timeseries": [
        {
          "@timestamp": "1711535140632",
          "count": 40,
          "value": 35.625,
          "quantiles": {
            "min": 691,
            "p25": 713.75,
            "p50": 796,
            "p75": 847.5,
            "p90": 1237,
            "p95": 1331,
            "p99": 1331,
            "p999": 1331,
            "max": 1331
          }
        }
      ],
      "groups_series": [
        {
          "name": "host123",
          "count": 124,
          "stat": "average(duration_millis)",
          "value": 50325.25,
          "series_resolution_ms": 60000,
          "timeseries": [
            {
              "@timestamp": "1711535140632",
              "count": 40,
              "value": 35.625,
              "quantiles": {
                "min": 691,
                "p25": 713.75,
                "p50": 796,
                "p75": 847.5,
                "p90": 1237,
                "p95": 1331,
                "p99": 1331,
                "p999": 1331,
                "max": 1331
              }
            }
          ]
        }
      ]
    }
  ],
  "latency_ns": [
    {
      "name": "host123",
      "count": 124,
      "stat": "average(duration_millis)",
      "value": 50325.25,
      "quantiles": {
        "min": 691,
        "p25": 713.75,
        "p50": 796,
        "p75": 847.5,
        "p90": 1237,
        "p95": 1331,
        "p99": 1331,
        "p999": 1331,
        "max": 1331
      },
      "series_resolution_ms": 60000,
      "timeseries": [
        {
          "@timestamp": "1711535140632",
          "count": 40,
          "value": 35.625,
          "quantiles": {
            "min": 691,
            "p25": 713.75,
            "p50": 796,
            "p75": 847.5,
            "p90": 1237,
            "p95": 1331,
            "p99": 1331,
            "p999": 1331,
            "max": 1331
          }
        }
      ],
      "groups_series": [
        {
          "name": "host123",
          "count": 124,
          "stat": "average(duration_millis)",
          "value": 50325.25,
          "series_resolution_ms": 60000,
          "timeseries": [
            {
              "@timestamp": "1711535140632",
              "count": 40,
              "value": 35.625,
              "quantiles": {
                "min": 691,
                "p25": 713.75,
                "p50": 796,
                "p75": 847.5,
                "p90": 1237,
                "p95": 1331,
                "p99": 1331,
                "p999": 1331,
                "max": 1331
              }
            }
          ]
        }
      ]
    }
  ]
}

Authorizations

X-BRONTO-API-KEY
string
header
required

Query Parameters

time_range
string

The relative time range for which to calculate parser metrics. Time range supported is from minutes to years. For an exact range, use from_ts and to_ts instead.

from_ts
integer

The starting time (unix time in milliseconds) for which to calculate parser metrics. Must be used together with to_ts. This parameter is not to be used when using time_range.

to_ts
integer

The ending time (unix time in milliseconds) for which to calculate parser metrics. Must be used together with from_ts. This parameter is incompatible with time_range.

limit
integer

Returns the top N logs based on the usage. If not provided, the default limit is 50. The maximum limit is 100.

num_of_slices
integer

The num_of_slices parameter defines how the time range is divided into intervals. It is optional, and if not provided, a default value is applied. The default number of slices is 1 minute granularity for up to 12 hours time range and 20 minutes granularity for longer than 12 hours time range up to 720 slices. - default for 20 minutes time window: 20 slices - default for 12 hour time window: 720 slices - default for 1 day time window: 72 slices (1 slice per 20 minutes) - default for 10 days time window: 720 slices (1 slice per 20 minutes) - default for 30 days time window: 720 slices (max number of slices allowed)

delta
boolean

Enables calculation of the difference between the current and previous time range values. When set to true, the response includes a delta object with the computed difference and its relative change. Defaults to false.

delta_time_range
string

The time period for which to query data for delta comparison. Either delta_time_range or both delta_from_ts and delta_to_ts can be provided if delta is enabled. If delta_time_range is provided, it will take precedence

delta_from_ts
integer

The starting unix time in milliseconds for which to query data for delta comparison. Either delta_time_range or both delta_from_ts and delta_to_ts can be provided if delta is enabled. If delta_time_range is provided, it will take precedence.

delta_to_ts
integer

The ending unix time in milliseconds for which to query data for delta comparison. Either delta_time_range or both delta_from_ts and delta_to_ts can be provided if delta is enabled. If delta_time_range is provided, it will take precedence.

Response

Successful response

log_id
string<uuid>

The uuid of the log being parsed

match_ratio
object[]

The ratio for log lines matched with the parser

latency_ns
object[]

The latency in milliseconds for parsing log lines with this parser