Help Center/ Edge Security/ API Reference/ API/ DDoS Statistics/ Querying the Timeline Data of DDoS Attack Statistics
Updated on 2024-11-18 GMT+08:00

Querying the Timeline Data of DDoS Attack Statistics

Function

This API is used to query the timeline data of DDoS attack statistics.

URI

GET /v1/edgesec/stat/ddos-attack-timelines

Table 1 Query Parameters

Parameter

Mandatory

Type

Description

enterprise_project_id

No

String

Obtain the enterprise project ID by calling the ListEnterpriseProject API of Enterprise Project Management Service (EPS). The default value is 0.

stat_type

Yes

String

Type of the security statistics metric. Currently, bw and pps are supported.

group_by

Yes

String

bw corresponds to max_bps and avg_bps, and pps corresponds to max_pps and avg_pps.

start_time

Yes

Long

Start time

end_time

Yes

Long

End time

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

stat_type

String

Metric type

group_by

String

Group type

interval

Integer

Time granularity (s)

values

Array of TimeStatItem objects

Value array

Table 4 TimeStatItem

Parameter

Type

Description

key

Long

Timestamp, which is left aligned with the time granularity. For example, if the time granularity is 5 minutes and the time range is [19:10,19:15), the timestamp is 19:10.

value

Long

Number of attack requests

Status code: 400

Table 5 Response body parameters

Parameter

Type

Description

error_code

String

Error code

error_msg

String

Error description

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error_code

String

Error code

error_msg

String

Error description

Status code: 500

Table 7 Response body parameters

Parameter

Type

Description

error_code

String

Error code

error_msg

String

Error description

Example Requests

None

Example Responses

None

Status Codes

Status Code

Description

200

Request succeeded.

400

Request failed.

401

The token does not have required permissions.

500

Internal server error.

Error Codes

See Error Codes.