Modifies the protection status of an on-demand instance.

Note Anti-DDoS Origin API operations are available only for Anti-DDoS Origin Enterprise users.


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 ModifyOnDemaondDefenseStatus

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

DdosRegionId String Yes cn-hangzhou

The region ID of the on-demand instance.

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

The protection status of the on-demand instance. Valid values:

  • Defense: enables rerouting.
  • UnDefense: disables rerouting.
InstanceId String Yes ddosbgp-xxx

The ID of an on-demand instance.

Response parameters

Parameter Type Example Description
RequestId String 4C467B38-3910-447D-87BC-AC049166F216

The ID of the request.


Sample requests

http(s)://[Endpoint]/? Action=ModifyOnDemaondDefenseStatus
&<Common request parameters>

Sample success responses

XML format


JSON format


Error codes

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