tencent cloud

文档反馈

DescribeAlarmEvents

最后更新时间:2024-06-21 15:11:12

1. API Description

Domain name for API request: wedata.tencentcloudapi.com.

Alert event list

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: DescribeAlarmEvents.
Version Yes String Common Params. The value used for this API: 2021-08-20.
Region Yes String Common Params. For more information, please see the list of regions supported by the product.
ProjectId Yes String Project ID
PageNumber Yes Integer Current Page
PageSize Yes Integer Number of records per page
Filters.N No Array of Filter Filter criteria (key can be: AlarmLevel, AlarmIndicator, KeyWord)
OrderFields.N No Array of OrderField Sort Fields (AlarmTime)
TaskType No Integer Type (201 for real-time, 202 for offline)
StartTime No String Start Time
EndTime No String End time
MonitorType No Integer Monitored Object Type (1: All Tasks, 2: Assigned Task, 3: Designated Responsible Person, 4: Specified Resource Group)

3. Output Parameters

Parameter Name Type Description
AlarmEventInfoList Array of AlarmEventInfo Alert event listNote: This field may return null, indicating that no valid value can be obtained.
TotalCount Integer Number of records
RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

4. Example

Example1 Alert event list

Input Example

POST / HTTP/1.1
Host: wedata.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeAlarmEvents
<Common request parameters>

{
    "Filters": [
        {
            "Values": [
                "1"
            ],
            "Name": "AlarmLevel"
        }
    ],
    "PageSize": 1,
    "ProjectId": "1",
    "OrderFields": [
        {
            "Direction": "DESC",
            "Name": "AlarmTime"
        }
    ],
    "PageNumber": 1,
    "StartTime": "2022-12-12 12:12:12",
    "TaskType": 1,
    "EndTime": "2022-12-12 12:12:12"
}

Output Example

{
    "Response": {
        "TotalCount": 1,
        "AlarmEventInfoList": [
            {
                "AlarmId": "1",
                "AlarmIndicator": 0,
                "AlarmIndicatorDesc": null,
                "AlarmLevel": 0,
                "AlarmRecipientId": "1",
                "AlarmRecipientName": "name1",
                "AlarmTime": "2023-11-07 07:22:36",
                "AlarmWay": 1,
                "EstimatedTime": null,
                "InstanceId": null,
                "IsSendSuccess": 2,
                "MessageId": "0ee4bf30",
                "Operator": 1,
                "ProjectId": "1455251608631480320",
                "RegularId": "814",
                "RegularName": "mmmm",
                "SendResult": "email:1,sms:0,wecom:0,voice:0,wechat:0,http:0,wecomgroup:0",
                "TaskId": "h8591470e",
                "TaskName": "test",
                "TaskType": 201,
                "TriggerType": null
            }
        ],
        "RequestId": "1"
    }
}

5. Developer Resources

SDK

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
AuthFailure.SignatureExpire Not logged in or login has expired.
FailedOperation Operation Failure.
InternalError An internal error occurs.
InvalidParameter Parameter error.
InvalidParameterValue Parameter value error.
ResourceNotFound The resource does not exist.
UnsupportedOperation Operation not supported.