SearchEvent

Prev Next

Available in Classic and VPC

This API queries events.

Request

This section describes the request format. The method and URI are as follows:

Method URI
POST /cw_fea/real/cw/api/event/search

Request headers

For information about the headers common to all Cloud Insight APIs, see Cloud Insight request headers.

Request body

See EventSearchRequest for more information about the fields related to the request information required when querying events.

Request example

The request example is as follows:

curl --location --request POST 'https://cw.apigw.ntruss.com/cw_fea/real/cw/api/event/search' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \
--header 'Content-Type: application/json' \
--data '{
    "endTime": "1702870800",
    "startTime": "1702867200"
}'

Response

This section describes the response format.

Response body

The response body includes the following data:

Field Type Required Description
events Array - Event information
pageNum Integer - Page number
pageSize Integer - Page output count
totalRecords Integer - Number of response results

events

The following describes events.

Field Type Required Description
calc String - Aggregation function
  • COUNT | AVG | SUM | MAX | MIN
calcSlidingGroupKey String - Event details
criteria String - Event rule value
describe String - Event description
detectValue String - Event value
dimension Object - Dimension information
dimension.instanceNo String - Instance number
dimension.type String - Dimension type
endTime Integer - Query end date and time (millisecond)
  • Unix timestamp format
eventId String - Event ID
eventLevel String - Event level
  • INFO | WARNING | CRITICAL
inMaintenance Boolean - Whether to set maintenance
  • true | false
    • true: set
    • false: not set
interval Integer - Aggregation interval
  • Min1 | Min5 | Min30 | Hour2 | Day1
metric String - Metric name
metricGroupItemId String - Metric group item ID
notificationGroups String - Notification recipient group name
notificationStatus String - Notification status
  • OK | FAIL | NONE
operator String - Comparison operator for evaluating event occurrence conditions
  • LT | LE | EQ | GE | NE | EXP
operatorSymbol String - Comparison operator symbol
prodKey String - Product key (cw_key)
prodName String - Product name
regionCode String - Region code
resourceDeleted Boolean - Resource deletion status
  • true | false
    • true: delete
    • false: not delete
resourceName String - Resource name
ruleId String - Event rule ID
ruleName String - Name of event rule
startTime Integer - Query start time (millisecond)
  • Unix timestamp format
unit String - Event unit
zoneCode String - Zone code
pageNum Integer Required Page number
  • 1-N
pageSize Integer - Required
totalRecords Integer - Number of response results

Response status codes

For information about the HTTP status codes common to NAVER Cloud Platform, see Cloud Insight API response status codes.

Response example

The response example is as follows:

{
    "events": [
        {
            "calc": "AVG",
            "calcSlidingGroupKey": "**********",
            "criteria": "0",
            "describe": "Server event rule",
            "detectValue": "0.0",
            "dimension": {
                "instanceNo": "**********",
                "type": "svr"
            },
            "endTime": 0,
            "eventId": "**********",
            "eventLevel": "INFO",
            "inMaintenance": false,
            "interval": 1,
            "metric": "load_average_5m",
            "metricGroupItemId": "**********",
            "notificationGroups": "**********",
            "notificationStatus": "OK",
            "operator": "EQ",
            "operatorSymbol": "=",
            "prodKey": "**********",
            "prodName": "System/Server(VPC)",
            "regionCode": "KR",
            "resourceDeleted": false,
            "resourceName": "svr-pub",
            "ruleId": "**********",
            "ruleName": "rule001",
            "startTime": 1702867200,
            "unit": "%",
            "zoneCode": "KR-1"
        }
    ],
    "pageNum": 1,
    "pageSize": 20,
    "totalRecords": 15
}