Accepts a virtual private cloud (VPC) peering connection request.

Usage notes

  • For a cross-account VPC peering connection, the connection is activated only after the acceptor VPC accepts the connection request.
  • The AcceptVpcPeerConnection operation is asynchronous. After you send a request, the system returns RequestId, but the operation is still being performed in the background. You can call the GetVpcPeerConnectionAttribute operation to query the status of a VPC peering connection.
    • If a VPC peering connection is in the Updating state, the VPC peering connection is being activated.
    • If a VPC peering connection is in the Activated state, the VPC peering connection is activated.
  • You cannot repeatedly call the AcceptVpcPeerConnection operation for the same VPC peering connection within the specified period of time.


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 AcceptVpcPeerConnection

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

InstanceId String Yes pcc-guzvyqlj0n6e10****

The ID of the VPC peering connection to be accepted by the acceptor VPC.

DryRun Boolean No false

Specifies whether to check the request without performing the operation. Valid values:

  • true: checks the request without performing the operation. The system checks the required parameters, request syntax, and limits. If the request fails to pass the check, an error message is returned. If the request passes the check, the DryRunOperation error code is returned.
  • false (default): sends the request. If the request passes the check, an HTTP 2xx status code is returned and the operation is performed.
ClientToken String No 02fb3da4-130e-11e9-8e44-001****

The client token that is used to ensure the idempotence of the request.

You can use the client to generate the value, but you must make sure that it is unique among different requests. The client token can contain only ASCII characters.

Note If you do not set this parameter, the system uses RequestId as ClientToken. The value of RequestId for each API request may be different.

Response parameters

Parameter Type Example Description
RequestId String 4EC47282-1B74-4534-BD0E-403F3EE64CAF

The ID of the request.


Sample requests

&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK


JSON format

HTTP/1.1 200 OK

  "RequestId" : "4EC47282-1B74-4534-BD0E-403F3EE64CAF"

Error codes

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