- Print
- PDF
SearchEvent
- Print
- PDF
The latest service changes have not yet been reflected in this content. We will update the content as soon as possible. Please refer to the Korean version for information on the latest updates.
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
|
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)
|
eventId | String | - | Event ID |
eventLevel | String | - | Event level
|
inMaintenance | Boolean | - | Whether to set maintenance
|
interval | Integer | - | Aggregation interval
|
metric | String | - | Metric name |
metricGroupItemId | String | - | Metric group item ID |
notificationGroups | String | - | Notification recipient group name |
notificationStatus | String | - | Notification status
|
operator | String | - | Comparison operator for evaluating event occurrence conditions
|
operatorSymbol | String | - | Comparison operator symbol |
prodKey | String | - | Product key (cw_key) |
prodName | String | - | Product name |
regionCode | String | - | Region code |
resourceDeleted | Boolean | - | Resource deletion status
|
resourceName | String | - | Resource name |
ruleId | String | - | Event rule ID |
ruleName | String | - | Name of event rule |
startTime | Integer | - | Query start time (millisecond)
|
unit | String | - | Event unit |
zoneCode | String | - | Zone code |
pageNum | Integer | Required | Page number
|
pageSize | Integer | - | Required |
totalRecords | Integer | - | Number of response results |
Response status codes
For response 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
}