You need to enable JavaScript to run this app.
导航

DownloadAlarmAllHistory

最近更新时间2023.04.11 16:29:02

首次发布时间2022.11.01 11:26:01

调用DownloadAlarmAllHistory接口下载报警历史。

使用说明

  • 接口名称:DownloadAlarmAllHistory
  • 请求方式:POST
  • 接口地址:/?Action=DownloadAlarmAllHistory&Version=2022-10-12

请求参数

Query

参数

类型

是否必选

示例值

描述

Action

String

DownloadAlarmAllHistory

请求名称。

Version

String

2022-10-12

请求版本。

ServiceName : apmplus_openapi
Region : cn-beijing 
X-App-Ids : xxx
Content-Type : application/json

Body

参数

类型

是否必填

示例值

说明

common

object of common

-

通用参数。

id

int64

302

报警任务ID列表。

time_filter

object of time_filter

-

时间区间。

page_size

int32

10

报警历史列表返回项数。

page_num

int32

1

报警历史列表页数。

category_list

array

pageview

报警任务类别。不填时返回全部类别报警历史。调用GetAlarmMeta接口查看取值。

name_list

array

111111111

报警任务名称列表。不填时返回全部名称报警历史。调用GetAlarmRuleList接口查看取值。

level_list

array

warning

报警级别列表。不填时返回全部类型报警。

  • warning
  • fatal

common

参数

类型

是否必填

示例值

说明

aid

int64

12345

应用ID。

os

string

webpro

服务类型。

time_filter

参数

类型

是否必填

示例值

说明

start_time

int32

1665849600

起始时间。

end_time

int32

1666011403

终止时间。

granularity

int32

60

聚合时间粒度。

返回参数

参数

类型

示例值

说明

err_detail

string

-

错误详情。

data

string

all-history_xxx-xxx.xlsx

文件唯一key。

error_msg

string

-

错误信息。

error_no

int

0

错误码。0为成功。

请求示例

POST https://open.volcengineapi.com/?Action=GetAlarmAllHistory&Version=2022-10-12

{
    "common":{
        "aid":12345,
        "os":"webpro"
    },
    "time_filter":{
        "start_time":1665849600,
        "end_time":1666011403,
        "granularity":3600
    },
    "page_size":10,
    "page_num":1,
    "category_list":[
        "pageview"
    ],
    "name_list":[
        "111111111"
    ],
    "level_list":[
        "warning"
    ]
}

返回示例

{
    "err_detail":"",
    "data":"all-history_xxx-xxx.xlsx",
    "error_msg":"",
    "error_no":0
}