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

let url = 'https://api.coralogix.com/mgmt/openapi/aaa/team-scopes/v1';

let options = {
  method: 'PUT',
  headers: {Authorization: 'Bearer <API_KEY>', 'content-type': 'application/json'},
  body: '{"defaultExpression":"<v1>true","description":"The best scope","displayName":"my-scope","filters":[{"entityType":"ENTITY_TYPE_UNSPECIFIED","expression":"<v1>true"}],"id":"60c82be2-413f-4b8e-8201-7f5c51e2ef2b"}'
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error('error:' + err));
{
  "scope": {
    "defaultExpression": "<v1>true",
    "description": "The best scope",
    "displayName": "my-scope",
    "filters": [
      {
        "entityType": "ENTITY_TYPE_UNSPECIFIED",
        "expression": "<v1>true"
      }
    ],
    "id": "60c82be2-413f-4b8e-8201-7f5c51e2ef2b",
    "teamId": 1234
  }
}

Authorizations

Authorization
string
header
required

API key authentication

Body

application/json

This data structure represents a request to update a scope

defaultExpression
string
required
Example:

"<v1>true"

displayName
string
required
Example:

"my-scope"

filters
Filter · object[]
required
id
string
required
Example:

"60c82be2-413f-4b8e-8201-7f5c51e2ef2b"

description
string
Example:

"The best scope"

Response

This data structure represents a response to update a scope

scope
object
required

This data structure represents a scope