All Products
Search
Document Center

Virtual Private Cloud:RejectVpcPeerConnection

Last Updated:Aug 05, 2024

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

Operation description

  • An acceptor VPC can reject a connection request from the requester VPC of a cross-account VPC peering connection. After the connection request is rejected, the VPC peering connection enters the Rejected state.
  • You cannot repeatedly call the RejectVpcPeerConnection operation for the same VPC peering connection within the specified period of time.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
InstanceIdstringYes

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

pcc-lnk0m24khwvtkm0****
DryRunbooleanNo

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.
false
ClientTokenstringNo

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.
123e4567-e89b-12d3-a456-426655440000

Response parameters

ParameterTypeDescriptionExample
object

RpcResponse

RequestIdstring

The ID of the request.

4EC47282-1B74-4534-BD2E-403F3EE64CAF

Examples

Sample success responses

JSONformat

{
  "RequestId": "4EC47282-1B74-4534-BD2E-403F3EE64CAF"
}

Error codes

HTTP status codeError codeError messageDescription
400ResourceNotFound.InstanceIdThe specified resource of %s is not found.The specified instance is not found
400IncorrectStatus.VpcPeerThe status of %s [%s] is incorrect.The status of the peer-to-peer connection instance does not meet the requirements. In this status, the peer-to-peer connection instance cannot be received.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-01-23API Description Update. The Error code has changedView Change Details