连接组网
站点连接质量
单用户调用频率:300/5min
Open API在线调试功能提供可视化界面在线调试API、支持生成代码示例、快速检索查看API文档等能力。前往调试
参数名称 | 描述 |
---|---|
*siteANameString | 站点A名称
该参数必须指定时,查询指定的站点数据 |
*siteBNameString | 站点B名称
该参数必须指定时,查询指定的站点数据 |
*startTimeString | 1、查询的开始时间,格式:yyyy-mm-ddThh:mm:ss 或 yyyy-mm-ddThh:mm
2、必须小于当前时间和endtime
3、startTime和endTime相差不能超过31天(可联系技术支持调整)
4、只能查询最近半年内数据 |
*endTimeString | 1、查询的结束时间,格式:yyyy-mm-ddThh:mm:ss或 yyyy-mm-ddThh:mm
2、必须小于当前时间,大于starttime
3、startTime和endTime相差不能超过31天(可联系技术支持调整)
4、只能查询最近半年内数据 |
参数名称 | 描述 |
---|---|
returnCode | 接口状态码 |
returnMsg | 接口信息 |
content | 响应内容 |
siteAName | 站点A名称 |
siteBName | 站点B名称 |
siteAId | 站点A ID |
siteBId | 站点B ID |
status | 链路状态0–未知,1–在线,2-离线,3-未上报,4-挂起 |
quality | 质量趋势数据 |
timeStamp | 时间戳 |
timeData | 时间分片 |
rtt | 时延 |
loss | 丢包率 |
mdev | 抖动 |
错误代码(code) | 描述(message) | HTTP状态码 | 语义 |
---|---|---|---|
4001 | Illegal time parameter | 400 | 非法时间参数 |
4002 | The time parameter cannot be empty | 400 | 时间参数不能为空 |
4003 | Start no earlier than six months ago | 400 | 开始时间不能早于半年前 |
4004 | The start and end time cannot be more than x days apart | 400 | 开始与结束时间不能相差超过x天 |
4005 | The start time cannot be later than the end time | 400 | 开始时间不能大于结束时间 |
4006 | The start and end time must be earlier than the current time | 400 | 开始结束时间必须小于当前时间 |
5001 | Site name cannot be empty | 400 | 站点名称不能为空 |
5003 | Site connection does not exist | 400 | 站点连接不存在 |
#!/bin/bash username="example_username" apiKey="example_apiKey" date=`env LANG="en_US.UTF-8" date -u "+%a, %d %b %Y %H:%M:%S GMT"` password=`echo -en "$date" | openssl dgst -sha1 -hmac $apiKey -binary | openssl enc -base64` siteAName="autotest_owned_initial01" siteBName="autotest_cpe_initial01" startTime="2021-12-03T15:16" endTime="2021-12-03T16:16" curl -i --url "http://10.8.218.160/api/siteLogic/qualityChart?siteAName=$siteAName&siteBName=$siteBName&startTime=$startTime&endTime=$endTime" \ -X "GET" \ -u "$username:$password" \ -H "Date: $date"
{ "returnCode": "1", "returnMsg": "success", "content":{ "siteAName": "北京总部", "siteAId": 740317625433843, "siteBName": "厦门分公司", "siteBId": 760845625433843, "status": 1, "quality":{ "timeStamp":[1638322140000,1638322200000], "timeData":["2021-10-31 22:05","2021-10-31 22:10"], "rtt":[13.45, 11.25], "loss":[0.1, 0], "mdev":[3.5, 4.2] } } }