获取top5最差性能页面列表。
请求说明 请求方式:POST 请求地址:https://open.volcengineapi.com/?Action=WorstPerf&Version=2022-10-12 ServiceName: apmplus_openapi
Region: cn-beijing
X-App-Ids: xxx
Content-Type: application/json
请求参数 Query 参数 类型 是否必选 示例值 描述 Action String 是 WorstPerf
接口名称。当前 API 的名称为 WorstPerf
。 Version String 是 2022-10-12
接口版本。当前 API 的版本为 2022-10-12
。
Body 参数 类型 是否必选 示例值 描述 time_filter Object of TimeFilter 是 -
时间区间。 common Object of CommonParams 是 -
通用参数。 filter_conditions Object of FilterCondition 否 -
筛选条件。 order_by String 是 fp
排序指标。支持按照fp、fcp、fmp、tti、load和lcp排序。 type String 否 avg
排序指标聚合方式。支持的聚合方式有avg、pct50、pct75、pct90和pct95。 min_count Integer 否 10
样本量阈值,样本量低于阈值的不参与计算。
TimeFilter 参数 类型 是否必选 示例值 描述 start_time Integer 是 1665485413
起始时间,单位s。 end_time Integer 是 1665744613
终止时间,单位s。 granularity Integer 否 3600
聚合时间粒度,单位s。
CommonParams 参数 类型 是否必选 示例值 描述 aid Long 是 12345
应用ID。 site_type String 是 web
站点类型。 env String 是 online
环境,填""时为全部。 os String 否 webpro
服务类型,可选值为webpro ,app ,minipro 。 user String 否 test_user
用户名。
FilterCondition 参数 类型 是否必选 示例值 描述 type String 是 and
筛选条件类型,可选值为and 和rule ,只支持两层,第一层的type必须为and,第二层的type必须为rule。 field String 否 pid
条件字段key,可选值集合由GetFieldKeys
方法获取。 op String 否 in
条件符号,可选值有eq,neq,lt,lte,gt,gte,in,not_in,regex,not_regex。 groupKey String 否 context
map类型字段key,可选值集合由GetFieldKeys
方法获取。 values Array of String 否 [数据探索]
条件值,可选值集合由GetFieldValues
方法获取。 children Array of FilterCondition 否 -
如果下层还有条件,则放入该处,即type为and 时必填。这一层与field,op,groupkey以及values不能同时存在。
返回参数 WorstPerfListResponseItem WorstPerfListResponseItemMetric 参数 类型 示例值 描述 name String fp
性能指标名。 value Long 1234
性能指标值。
ChartData 参数 类型 示例值 描述 fields Array of Field -
折线图/饼图维度,len(fields)=len(source[i])。 source Array of String [["1668355200","js_error","0","0"]]
趋势图具体点的集合,len(source)为折线图点的数量或者饼图中块数量。
Field 参数 类型 示例值 描述 id String date
维度key。 name String 日期
维度名。 dataType String string
维度类型。 aggregate String -
聚合方式。
请求示例 POST https:
{
"time_filter" : {
"start_time" : 1665485413 ,
"end_time" : 1665744613 ,
"granularity" : 3600
} ,
"common" : {
"aid" : 12345 ,
"site_type" : "web" ,
"env" : "online" ,
"os" : "webpro" ,
"user" : "test_user"
} ,
"order_by" : "fp,fcp,fmp,tti,load,lcp" ,
"filter_conditions" : {
"type" : "and" ,
"op" : "in" ,
"groupKey" : "context" ,
"field" : "pid" ,
"children" : [
{
"type" : "and" ,
"op" : "in" ,
"values" : "[数据探索]" ,
"children" : [ ] ,
"groupKey" : "context" ,
"field" : "pid"
}
] ,
"values" : "[数据探索]"
} ,
"min_count" : 10 ,
"type" : "avg,pct50,pct75,pct90,pct95"
}
返回示例 {
"error_no" : 0 ,
"error_msg" : "" ,
"data" : [
{
"data" : [
{
"value" : 1234 ,
"name" : "fp"
}
] ,
"trend" : {
"source" : [
[
"1668355200" ,
"js_error" ,
"0" ,
"0"
]
] ,
"fields" : [
{
"dataType" : "string" ,
"name" : "日期" ,
"id" : "date" ,
"aggregate" : ""
}
]
} ,
"pid" : "path_test"
}
]
}
错误码 本接口无特有的错误码。更多信息请参见错误码 。