Endpoint
/api/v2/tenants/{tenantId}/serviceGroups
Path Parameters
tenantId
string

alert
boolean

(Optional) Generate an alert when the threshold limits are breached.

alertType
integer

(Optional) Provide specific alertType value to set service availability monitor: - Service Availability Monitor will be set to Available, If alertType = 2. - Service Availability Monitor will be set to Any critical alert, If alertType = 0. - Service Availability Monitor will be set to Critical alert, If alertType = 1.

childType
string

Child service group type. Example: DEVICE, SERVICEGROUP, SNS, SQS

createdDate
string

filterCriteria
object

filterCriteria.actions
filterCriteria.executionOrder
filterCriteria.id
filterCriteria.matchType
(Optional) The type of match: -To match all the filter conditions, provide matchType: ALL. - To match any one of the filter conditions, provide matchType: ANY.
filterCriteria.name
Name of the policy.
filterCriteria.resourceType
Type of resource. Example: DEVICE, VOLUME, VPN, XENSERVER
filterCriteria.rules
(Optional) Filter devices with specific attributes: - Attribute name of device. Example: Name, Operating System. Attribute names change with device types. - Matching parameter. Supported operators are: Equals, Contains, Not Contains, Starts with, Ends with, Regex. Learn more about Regex. - Type of resource
frequency
integer

(Optional)

id
string

include
string

kbArticlesIds
array

Assign knowledge base articles to a device group.Note: To fetch a knowledge base article ID: 1. Log into OpsRamp. 2. Click Knowledge Base. 3. Select the required article and then copy the article ID. 4. Provide the article ID in "kbArticleIds" field. Example: "kbArticleIds": [22089].

metrics
array

monitorNames
array

name
string

Unique name for the service group. The service group is identified with this name.

parent
object

parent.id
Add a service group as a child under an existing service group (parent). This field is required for adding a service group to a parent service group.
thresholdLimit
integer

(Optional) Provide a specific threshold value to determine count or percentage.

thresholdType
string

(Optional) Define the availability status for a service group with below threshold types: - count: Define availability of a service group based on the number of resources in the group. For example, if 10 resources are down. - percentage: Percentage of resources or services that should be considered to determine the availability. Below are the supported availability statuses: - Down: If resources or services down are greater than or equal to a specific value(count/percentage), then service is considered as Down. - Degraded: If resource or services down are less than a specific value(count/percentage), then service is considered as Degraded. - OK: If all resources or services are Up, then service is considered as OK. For example, a user wants to define availability status as Down if 5 resources are down, then the values are provided as: `"thresholdType": "count","thresholdLimit": 5`.

type
string

(Optional) - To generate an alert when the threshold limits are breached, provide type: alert. - To display the availability status without generating an alert, provide type: default.

updatedDate
string

[
  {
    "alert": false,
    "alertType": 2,
    "childType": "DEVICE",
    "createdDate": "2018-06-20T11:33:08+0000",
    "filterCriteria": {
      "matchType": "ANY",
      "rules": [
        {
          "key": "Name",
          "operator": "Contains",
          "resourceType": "DEVICE",
          "value": "Linux"
        }
      ]
    },
    "frequency": 5,
    "include": "ALL",
    "metrics": [],
    "monitorNames": [
      "service.availability.metric"
    ],
    "name": "Warehouse Inventory",
    "parent": {
      "id": "SGP-c93673d0-355e-40bf-807c-44cc1d8678a4"
    },
    "thresholdLimit": 1,
    "thresholdType": "count",
    "type": "alert",
    "updatedDate": "2018-06-20T11:33:08+0000"
  }
]
[
  {
    "alert": false,
    "alertType": 2,
    "childType": "DEVICE",
    "createdDate": "2018-06-20T11:33:08+0000",
    "filterCriteria": {
      "matchType": "ANY",
      "rules": [
        {
          "key": "Name",
          "operator": "Contains",
          "resourceType": "DEVICE",
          "value": "Windows"
        }
      ]
    },
    "frequency": 5,
    "include": "ALL",
    "metrics": [],
    "monitorNames": [
      "service.availability.metric"
    ],
    "name": "Finance Inventory",
    "thresholdLimit": 1,
    "thresholdType": "count",
    "type": "alert",
    "updatedDate": "2018-06-20T11:33:08+0000"
  }
]
[
  {
    "childType": "SERVICEGROUP",
    "description": "Warehouse maintenance servers in North VJ",
    "id": "SGP-a20e13ad-e98f-416e-a9dd-40158ffdb2af",
    "kbArticlesIds": [
      1
    ],
    "name": "Warehouse servers"
  }
]

Responses

OK

[
  {
    "alert": false,
    "alertType": 2,
    "childType": "DEVICE",
    "createdDate": "2018-06-20T12:13:34+0000",
    "filterCriteria": {
      "matchType": "ANY",
      "rules": [
        {
          "key": "Name",
          "operator": "Contains",
          "resourceType": "DEVICE",
          "value": "Linux"
        }
      ]
    },
    "frequency": 5,
    "id": "SGP-f4e6100a-7180-43c8-955c-679205bbc419",
    "include": "ALL",
    "metrics": [],
    "monitorNames": [
      "service.availability.metric"
    ],
    "name": "Warehouse Inventory",
    "thresholdLimit": 1,
    "thresholdType": "count",
    "type": "alert",
    "updatedDate": "2018-06-20T12:13:34+0000"
  }
]
[
  {
    "alert": false,
    "alertType": 2,
    "childType": "DEVICE",
    "createdDate": "2018-06-20T11:33:08+0000",
    "filterCriteria": {
      "actions": [],
      "matchType": "ANY",
      "rules": [
        {
          "key": "Name",
          "operator": "Contains",
          "resourceType": "DEVICE",
          "value": "Windows"
        }
      ]
    },
    "frequency": 5,
    "id": "SGP-d71e0398-f33b-48ba-a283-1fa11ebe3e17",
    "include": "ALL",
    "metrics": [],
    "monitorNames": [
      "service.availability.metric"
    ],
    "name": "Finance Inventory",
    "thresholdLimit": 1,
    "thresholdType": "count",
    "type": "alert",
    "updatedDate": "2018-06-20T11:43:17+0000"
  }
]
[
  {
    "childType": "SERVICEGROUP",
    "description": "Warehouse maintenance servers in North VJ",
    "id": "SGP-a20e13ad-e98f-416e-a9dd-40158ffdb2af",
    "kbArticlesIds": [
      1
    ],
    "name": "Warehouse servers"
  }
]