GET
/
v1
/
slo
/
slos:batchGet
const fetch = require('node-fetch');

let url = 'https://api.coralogix.com/mgmt/openapi/v1/slo/slos:batchGet?ids=SOME_ARRAY_VALUE';

let options = {method: 'GET', headers: {Authorization: 'Bearer <API_KEY>'}};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error('error:' + err));
{
  "slos": [
    {
      "id": "b11919d5-ef85-4bb1-8655-02640dbe94d9",
      "name": "Example Slo Name",
      "description": "A brief description of my SLO",
      "creator": "test@domain.com",
      "labels": {},
      "revision": {
        "revision": 1,
        "updateTime": "2023-11-07T05:31:56Z"
      },
      "grouping": {
        "labels": [
          "<string>"
        ]
      },
      "createTime": "2023-11-07T05:31:56Z",
      "updateTime": "2023-11-07T05:31:56Z",
      "targetThresholdPercentage": 99.999,
      "sloTimeFrame": "SLO_TIME_FRAME_UNSPECIFIED",
      "requestBasedMetricSli": {
        "goodEvents": {
          "query": "sum(rate(http_requests_total{status=\"200\"}[5m]))"
        },
        "totalEvents": {
          "query": "sum(rate(http_requests_total{status=\"200\"}[5m]))"
        }
      },
      "windowBasedMetricSli": {
        "query": {
          "query": "sum(rate(http_requests_total{status=\"200\"}[5m]))"
        },
        "window": "WINDOW_SLO_WINDOW_UNSPECIFIED",
        "comparisonOperator": "COMPARISON_OPERATOR_UNSPECIFIED",
        "threshold": 0.95
      }
    }
  ],
  "notFoundIds": [
    "<string>"
  ]
}

Authorizations

Authorization
string
header
required

API key authentication

Query Parameters

ids
string[]
required

Response

200
application/json

A successful response.

Response containing a batch of SLOs and any IDs not found.