Queries client IP addresses that are ranked by the number of requests or the amount of network traffic within a specific time range for one or more accelerated domain names. You can query data collected within the last 90 days.

The statistical analysis feature of Alibaba Cloud CDN is no longer available. The API operations related to the statistical analysis feature are no longer maintained. We recommend that you do not use the API operations because data may be missing or inaccurate. You can use the operations report feature to for data analysis.

Note
  • If you do not set StartTime or EndTime, data collected within the last 24 hours is queried. If you set both StartTime and EndTime, data collected within the specified time range is queried.
  • Data is collected every hour.
  • You can call this operation up to 10 times per second per account.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeDomainTopClientIpVisit

The operation that you want to perform. Set the value to DescribeDomainTopClientIpVisit.

DomainName String No example.com

The accelerated domain name. Separate multiple accelerated domain names with commas (,).

By default, this operation queries client IP addresses for all accelerated domain names.

LocationNameEn String No beijing

The name of the region. Separate multiple region names with commas (,).

You can call the DescribeCdnRegionAndIsp operation to query regions.

StartTime String No 2019-09-30T16:00:00Z

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

EndTime String No 2019-10-01T16:00:00Z

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

The end time must be later than the start time.

SortBy String No traf

The method that is used to sort the client IP addresses. Valid values:

  • traf: by network traffic. This is the default value.
  • acc: by the number of requests.
Limit String No 20

The maximum number of entries to return. Maximum value: 100.

Default value: 20. The default value 20 specifies that the top 20 data entries are returned.

Response parameters

Parameter Type Example Description
RequestId String 64D28B53-5902-409B-94F6-FD46680144FE

The ID of the request.

ClientIpList Array of ClientIp

A list of client IP addresses.

Rank Integer 2

The ranking of the client IP address returned.

ClientIp String 1.1.xxx

The client IP address returned. Only IPv4 addressed are supported.

Acc Long 256

The total number of requests.

Traffic Long 1024

The total amount of network traffic consumed. Unit: bytes.

Examples

Sample requests

http://cdn.aliyuncs.com/?Action=DescribeDomainTopClientIpVisit
&DomainName=example.com
&StartTime=2019-09-30T16:00:00Z
&EndTime=2019-10-01T16:00:00Z
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeDomainTopClientIpVisitResponse>
<RequestId>64D28B53-5902-409B-94F6-FD46680144FE</RequestId>
<ClientIpList>
    <Rank>1</Rank>
    <ClientIp>1.1.xx</ClientIp>
    <Traffic>1024</Traffic>
    <Acc>128</Acc>
</ClientIpList>
<ClientIpList>
    <Rank>2</Rank>
    <ClientIp>2.2.xx</ClientIp>
    <Traffic>2048</Traffic>
    <Acc>256</Acc>
</ClientIpList>
</DescribeDomainTopClientIpVisitResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "64D28B53-5902-409B-94F6-FD46680144FE",
  "ClientIpList" : [ {
    "Rank" : 1,
    "ClientIp" : "1.1.xx",
    "Traffic" : 1024,
    "Acc" : 128
  }, {
    "Rank" : 2,
    "ClientIp" : "2.2.xx",
    "Traffic" : 2048,
    "Acc" : 256
  } ]
}

Error codes

HttpCode Error code Error message Description
400 InvalidStartTime.Malformed Specified StartTime is malformed. The error message returned because the format of the specified start time is invalid. For more information about the time format, see the Request parameters section.
400 InvalidEndTime.Malformed Specified EndTime is malformed. The error message returned because the format of the specified end time is invalid. For more information about the time format, see the Request parameters section.
400 InvalidStartTime.ValueNotSupported The specified value of parameter StartTime is not supported. The error message returned because the specified start time is invalid. Set a valid value and try again.

For a list of error codes, visit the API Error Center.