Usage Monitoring¶
GET Get Packages¶
GET /prod-api/cdn/domain/getPackages
Get packages
Request Parameters¶
| Name | Location | Type | Required | Description |
|---|---|---|---|---|
| Authorization | header | string | No | none |
Response Example
{
"msg": "Operation successful",
"code": 200,
"data": [
{
"label": "11123",
"value": "20220825123456"
},
{
"label": "1111122",
"value": "20231213190456877"
}
]
}
401 Response
Response Results¶
| Status Code | Meaning | Description | Data Model |
|---|---|---|---|
| 200 | OK | none | Inline |
| 401 | Unauthorized | none | Inline |
| 403 | Forbidden | none | Inline |
| 404 | Not Found | none | Inline |
Response Data Structure¶
Status Code 200
| Name | Type | Required | Constraints | Chinese Name | Description |
|---|---|---|---|---|---|
| » msg | string | true | none | none | |
| » code | integer | true | none | none | |
| » data | [object] | true | none | none | |
| »» label | string | false | none | Label | none |
| »» value | string | false | none | Value | none |
数据统计接口¶
POST 用量监控数据¶
POST /prod-api/cdn/layer7/statistic/describeL7UsageData
Body Request Parameters
{
"interval": "1m",
"oids": ["20240412279000084616"],
"params": {
"beginTime": "2024-11-25 00:00:00",
"endTime": "2024-11-25 23:59:59"
},
"action": [
{
"metricName": "totalTraffic"
},
{
"metricName": "trafficTrend"
},
{
"metricName": "bandwidthTrend"
},
{
"metricName": "totalBandwidth"
}
]
}
Request Parameters¶
| Name | Location | Type | Required | Chinese Name | Description |
|---|---|---|---|---|---|
| Authorization | header | string | No | none | |
| body | body | object | No | none | |
| » interval | body | string | Yes | Statistics Granularity | 1m:1 minute 5m:5 minute 1h:1 hour 1d:1 day |
| » oids | body | [string] | Yes | Domain | none |
| » params | body | object | Yes | none | |
| »» beginTime | body | string | Yes | Start time | none |
| »» endTime | body | string | Yes | End time | none |
| » action | body | [object] | Yes | none | |
| »» metricName | body | string | Yes | Data retrieval name | metricName: "trafficTrend (Traffic Statistics Chart)" |
详细 Description¶
»» metricName: metricName:“trafficTrend(Traffic Statistics Chart)” metricName:“totalTraffic(Traffic Data Overview)” metricName:“bandwidthTrend(Bandwidth Statistics Chart)” metricName:“totalBandwidth(BandwidthData Overview)”
Response Example
{
"msg": "Success",
"code": 200,
"data": [
{
"metricName": "trafficTrend",
"objectArrayListMap": {
"inTraffic": [
[1732464060000, 15229],
[1732462560000, 2246]
],
"ouTraffic": [
[1732464060000, 15229],
[1732462560000, 2246]
],
"totalTraffic": [
[1732464060000, 15229],
[1732462560000, 2246]
]
},
"totalMap": {
"inTotalTraffic": 0,
"outTotalTraffic": 0,
"totalTraffic": 0
}
},
{
"metricName": "bandwidthTrend",
"objectArrayListMap": {
"inBandwidth": [
[1732464060000, 15229],
[1732462560000, 2246]
],
"outBandwidth": [
[1732464060000, 15229],
[1732462560000, 2246]
],
"totalBandwidth": [
[1732464060000, 15229],
[1732462560000, 2246]
]
},
"totalMap": {
"maxInBandwidth": 0,
"maxOutBandwidth": 0,
"maxTotalBandwidth": 0
}
}
]
}
Response Results¶
| Status Code | Meaning | Description | Data Model |
|---|---|---|---|
| 200 | OK | none | Inline |
Response Data Structure¶
Status Code 200
| Name | Type | Required | Constraints | Chinese Name | Description |
|---|---|---|---|---|---|
| » msg | string | true | none | none | |
| » code | integer | true | none | none | |
| » data | [object] | true | none | none | |
| »» metricName | string | true | none | Metric Name | none |
| »» objectArrayListMap | object | true | none | none | |
| »»» inTraffic | [array] | false | none | Inbound Traffic Trend | none |
| »»» ouTraffic | [array] | false | none | Outbound Traffic Trend | none |
| »»» totalTraffic | [array] | false | none | Total Traffic Trend | none |
| »»» inBandwidth | [array] | true | none | Inbound Bandwidth Peak Trend | none |
| »»» outBandwidth | [array] | true | none | Outbound Bandwidth Peak Trend | none |
| »»» totalBandwidth | [array] | true | none | Total Bandwidth Peak Trend | none |
| »» totalMap | object | true | none | none | |
| »»» inTotalTraffic | integer | false | none | Total Inbound Traffic | none |
| »»» outTotalTraffic | integer | false | none | Total Outbound Traffic | none |
| »»» totalTraffic | integer | false | none | Total Traffic | none |
| »»» maxInBandwidth | integer | true | none | Downstream Bandwidth Peak | none |
| »»» maxOutBandwidth | integer | true | none | Upstream Bandwidth Peak | none |
| »»» maxTotalBandwidth | integer | true | none | Total Bandwidth Peak | none |