Enables or disables a virtual private cloud (VPC) firewall. The VPC firewall can control traffic between two VPCs that are connected by using an Express Connect circuit.

Description

You can call the ModifyVpcFirewallSwitchStatus operation to enable or disable a VPC firewall. The VPC firewall can control traffic between two VPCs that are connected by using an Express Connect circuit. After you enable the VPC firewall, the VPC firewall controls mutual access traffic between two VPCs that are connected by using an Express Connect circuit. After you disable the VPC firewall, the VPC firewall no longer controls mutual access traffic between two VPCs that are connected by using an Express Connect circuit.

Before you call the operation, make sure that you created a VPC firewall by calling the CreateVpcFirewallConfigure operation.

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 ModifyVpcFirewallSwitchStatus

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

Lang String No zh

The natural language of the request and response. Valid values:

  • zh: Chinese (default)
  • en: English
VpcFirewallId String Yes vfw-m5e7dbc4y****

The instance ID of the VPC firewall.

Note You can call the DescribeVpcFirewallList operation to query the instance IDs of VPC firewalls.
FirewallSwitch String Yes open

Specifies whether to enable the VPC firewall. Valid values:

  • open: enables the VPC firewall.
  • close: disables the VPC firewall.
MemberUid String No 258039427902****

The UID of the member that is managed by your Alibaba Cloud account.

Response parameters

Parameter Type Example Description
RequestId String 850A84D6-0DE4-4797-A1E8-00090125afj2

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ModifyVpcFirewallSwitchStatus
&Lang=zh
&VpcFirewallId=vfw-m5e7dbc4y****
&FirewallSwitch=open
&MemberUid=258039427902****
&Common request parameters

Sample success responses

XML format

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

<ModifyVpcFirewallSwitchStatusResponse>
    <RequestId>850A84D6-0DE4-4797-A1E8-00090125afj2</RequestId>
</ModifyVpcFirewallSwitchStatusResponse>

JSON format

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

{
  "RequestId" : "850A84D6-0DE4-4797-A1E8-00090125afj2"
}