Queries the top Internet traffic statistics over time.
Try it now
Test
RAM authorization
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| SourceIp |
string |
No |
The source IP address of the visitor. |
60.179.179.XXX |
| Lang |
string |
No |
The language of the response. Valid values:
|
zh |
| Lang |
string |
No |
The language of the response. Valid values:
|
zh |
| Direction |
string |
Yes |
The traffic direction. Valid values:
|
out |
| SourceCode |
string |
Yes |
The source tracing code. |
yundun |
| Sort |
string |
No |
The sorting method. Valid values:
|
in_bps |
| TrafficTime |
string |
No |
The time point of the traffic. If you do not specify this parameter, the latest data is returned. |
1745222880 |
| Limit |
string |
No |
The maximum number of entries to return. The default value is 50. Valid values: 1 to 50. |
5 |
| SrcIP |
string |
No |
The source IP address. |
8.153.18.XX |
| NatIP |
string |
No |
The public IP address of the NAT Gateway. If you do not specify this parameter, the IP addresses of all assets are queried. |
47.97.66.XXX |
| Order |
string |
No |
The sort order. Valid values:
|
desc |
| StartTime |
string |
No |
The beginning of the time range to query. This value is a UNIX timestamp. Unit: seconds. |
1749434787 |
| EndTime |
string |
No |
The end of the time range to query. This value is a UNIX timestamp. Unit: seconds. |
1733796528 |
| TrafficType |
string |
No |
The traffic type. |
EIP_TRAFFIC |
| IPType |
string |
No |
The network type of the IP address. Valid values:
|
Public |
| Interval |
integer |
No |
The time interval. |
60 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| TrafficTime |
integer |
The time point of the traffic. This value is a UNIX timestamp. Unit: seconds. |
1734399660 |
| RequestId |
string |
The ID of the request. |
7F2D5C04-731F-50B0-ADE1-01637B3C**** |
| DataCount |
integer |
The number of entries. |
19 |
| DataList |
array<object> |
The list of data. |
|
|
object |
The list of data. |
||
| ResourceInstanceName |
string |
The name of the asset instance. |
test |
| InBps |
integer |
The inbound bandwidth. Unit: bps. |
187 |
| ResourceInstanceId |
string |
The ID of the resource instance. |
lb-bp14ue2rgktunncq**** |
| NewConn |
integer |
The number of new connections. |
27 |
| RegionNo |
string |
The region ID. |
cn-shenzhen |
| OutPps |
integer |
The outbound packet forwarding rate. Unit: pps. |
2 |
| IP |
string |
The IP address. |
183.60.164.XXX |
| OutBps |
integer |
The outbound traffic. Unit: bps. |
45 |
| PrivateIP |
string |
The private IP address. |
10.21.186.XXX |
| SessionCount |
integer |
The number of sessions. |
27 |
| ResourceType |
string |
The type of the public IP address. Valid values:
|
EcsPublicIP |
| InPps |
integer |
The inbound packet forwarding rate. Unit: pps. |
2 |
| TotalPps |
integer |
The total number of packets. |
88 |
| TotalBps |
integer |
The total bandwidth. Unit: bps. |
232 |
| VpcId |
string |
The ID of the VPC instance. |
vpc-wz9o0uzfjuj81fx7m**** |
| NatGatewayId |
string |
The ID of the NAT Gateway. |
ngw-wz98eedr5l5hkb8****e7 |
| NatGatewayName |
string |
The name of the NAT Gateway. |
ngw-test |
| NatIP |
string |
The public IP address of the NAT Gateway. |
47.97.66.XXX |
Examples
Success response
JSON format
{
"TrafficTime": 1734399660,
"RequestId": "7F2D5C04-731F-50B0-ADE1-01637B3C****",
"DataCount": 19,
"DataList": [
{
"ResourceInstanceName": "test",
"InBps": 187,
"ResourceInstanceId": "lb-bp14ue2rgktunncq****",
"NewConn": 27,
"RegionNo": "cn-shenzhen",
"OutPps": 2,
"IP": "183.60.164.XXX",
"OutBps": 45,
"PrivateIP": "10.21.186.XXX",
"SessionCount": 27,
"ResourceType": "EcsPublicIP",
"InPps": 2,
"TotalPps": 88,
"TotalBps": 232,
"VpcId": "vpc-wz9o0uzfjuj81fx7m****",
"NatGatewayId": "ngw-wz98eedr5l5hkb8****e7",
"NatGatewayName": "ngw-test",
"NatIP": "47.97.66.XXX"
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | ErrorSourceCodeError | The source code is invalid. | The source code is invalid. |
| 400 | ErrorDirectionError | The direction is invalid. | The direction is invalid. |
| 400 | ErrorTimeError | The time is invalid. | The time is invalid. |
| 400 | ErrorIpFormat | The IP address is invalid. | The IP address is invalid. |
| 400 | ErrorParameters | A parameter error occurred. | A parameter error occurred. |
| 400 | ErrorDBSelectError | A database select error occurred. | The error message returned because an internal error has occurred in querying the database. |
| 400 | ErrorTrafficType | The traffic type is invalid. | The traffic type is invalid. |
| 400 | ErrorSortError | The sort is invalid. | The sort is invalid. |
| 400 | ErrorLimitFailed | The limit is invalid. | The limit count is invalid. |
| 400 | ErrorOrderFailed | The order is invalid. | The order is invalid. |
| 400 | ErrorMarshalJSON | internal error. | Internal error. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.