Skip to main content
node
const fetch = require('node-fetch');

let url = 'https://api.coralogix.com/mgmt/openapi/dataplans/data-usage/v2/logs:count';

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));
{
  "logsCount": [
    {
      "logsCount": 100,
      "priority": "PRIORITY_UNSPECIFIED",
      "severity": "SEVERITY_UNSPECIFIED",
      "timestamp": "2023-11-07T05:31:56Z"
    }
  ]
}

Authorizations

Authorization
string
header
required

API key authentication

Response

This data structure is used to return logs count.

logsCount
Logs Count · object[]
I