Changes the scrubbing thresholds for an asset. The asset can be an elastic IP address (EIP). The asset can also be an Elastic Compute Service (ECS) instance or Server Load Balancer (SLB) instance that is assigned a public IP address.

Usage notes

You can call the ModifyDefenseThreshold operation to change the scrubbing thresholds for an asset.

Limits

You can call this operation up to 10 times per second per account. If the number of the calls per second exceeds the limit, throttling is triggered. As a result, your business may be affected. We recommend that you take note of the limit when you call this operation.

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 ModifyDefenseThreshold

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

DdosRegionId String Yes cn-hangzhou

The region ID of the asset for which you want to change the scrubbing thresholds.

Note You can call the DescribeRegions operation to query the most recent region list.
InstanceType String Yes ecs

The type of the asset. Valid values:

  • ecs: ECS instance
  • slb: SLB instance
  • eip: EIP
InstanceId String Yes i-uf6idy3c57psf7vu****

The ID of the asset.

Note You can call the DescribeInstance operation to query the IDs of ECS instances, SLB instances, and EIPs within the current Alibaba Cloud account.
Bps Integer No 100

Specifies the traffic scrubbing threshold. Unit: Mbit/s. The traffic scrubbing threshold cannot exceed the peak inbound or outbound Internet traffic, whichever is larger, of the asset.

You can use the monitoring tool that is provided by the asset to query the Internet traffic of the asset:

Pps Integer No 70000

Specifies the packet scrubbing threshold. Unit: packets per second (pps).

The packet scrubbing threshold cannot exceed the peak number of inbound or outbound packets, whichever is larger, of the asset. You can use the monitoring tool that is provided by the asset to query the number of packets of the asset:

IsAuto Boolean No false

Specifies whether to automatically adjust the scrubbing thresholds based on the traffic load on the asset. Valid values:

  • true: automatically adjusts the scrubbing thresholds. You do not need to configure the Bps and Pps parameters.
  • false: The scrubbing thresholds are not automatically adjusted. You must configure the Bps and Pps parameters.

Default value: false

All Alibaba Cloud API operations must include common request parameters. For more information about common request parameters, see Common parameters.

For more information about sample requests, see the "Examples" section of this topic.

Response parameters

Parameter Type Example Description
RequestId String 9F092395-E1E3-5EE3-890D-B96F1964D184

The ID of the request, which is used to locate and troubleshoot issues.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ModifyDefenseThreshold
&DdosRegionId=cn-hangzhou
&InstanceType=ecs
&InstanceId=i-uf6idy3c57psf7vu****
&Bps=100
&Pps=70000
&IsAuto=false
&Common request parameters

Sample success responses

XML format

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

<ModifyDefenseThresholdResponse>
    <RequestId>9F092395-E1E3-5EE3-890D-B96F1964D184</RequestId>
</ModifyDefenseThresholdResponse>

JSON format

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

{
  "RequestId" : "9F092395-E1E3-5EE3-890D-B96F1964D184"
}

Error codes

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