All Products
Search
Document Center

API Gateway:ModifyVpcAccessAndUpdateApis

Last Updated:Jul 31, 2025

Modifies the information of a VPC access authorization and updates the metadata of the associated API.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • For mandatory resource types, indicate with a prefix of * .
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
apigateway:ModifyVpcAccessAndUpdateApisupdate
*All Resources
*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
VpcIdstringYes

The ID of the new VPC.

vpc-m5e7jqfppv5wbvmdw5pg2
InstanceIdstringYes

The ID of the new instance.

i-uf6bzcg1pr4oh5jjmxxx
PortintegerYes

The new port number.

80
NamestringYes

The name of the VPC authorization.

Note
  • The name of a VPC authorization cannot be changed. You cannot use this parameter to change the name of a VPC authorization.

  • You must set this parameter to the name of the current VPC authorization.

VpcName
TokenstringNo

The token of the request.

c20d86c4-1eb3-4d0b-afe9-c586df1e2136
NeedBatchWorkbooleanNo

Specifies whether to update the associated API.

**

Warning: If you want to update the VPC authorization of a published API, you must set this parameter to true. Otherwise, the update will not be synchronized to the backend service of the API.

true
RefreshbooleanNo

Specifies whether to update the VPC authorization.

Note
  • If the ID of the instance in your VPC is changed but the IP address of the instance remains unchanged, you can set this parameter to true to update the VPC authorization.
false
VpcTargetHostNamestringNo

The hostname of the backend service.

iot.hu***ng.com

Response parameters

ParameterTypeDescriptionExample
object
OperationIdstring

The ID of the asynchronous task.

Note
  • If the associated API is updated, you can use the task ID in the DescribeUpdateVpcInfoTask operation to query the update result.
7b6d0cb72b2e4215b0129f675c889746
RequestIdstring

The ID of the request.

C2CEC6EA-EEBA-5FD6-8BD9-2CF01980FE39

Examples

Sample success responses

JSONformat

{
  "OperationId": "7b6d0cb72b2e4215b0129f675c889746",
  "RequestId": "C2CEC6EA-EEBA-5FD6-8BD9-2CF01980FE39"
}

Error codes

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

Change history

Change timeSummary of changesOperation
No change history