All Products
Search
Document Center

Virtual Private Cloud:MoveResourceGroup

Last Updated:Aug 29, 2024

Moves a resource to a different resource group.

Debugging

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

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:
    • The required resource types are displayed in bold characters.
    • 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
vpc:MoveResourceGroupupdate
  • BandwidthPackage
    acs:vpc:{#regionId}:{#accountId}:bandwidthpackage/{#BandwidthPackageId}
  • Eip
    acs:vpc:{#regionId}:{#accountId}:eip/{#AllocationId}
  • VPC
    acs:vpc:{#regionId}:{#accountId}:vpc/{#VpcId}
  • PrefixList
    acs:vpc:{#regionId}:{#accountId}:prefixlist/{#PrefixListId}
  • GatewayEndpoint
    acs:vpc:{#regionId}:{#accountId}:gatewayendpoint/{#GatewayEndpointId}
  • DhcpOptionsSet
    acs:vpc:{#regionId}:{#accountId}:dhcpoptionsset/{#DhcpOptionsSetId}
  • FlowLog
    acs:vpc:{#regionId}:{#accountId}:flowlog/{#FlowLogId}
  • HaVip
    acs:vpc:{#regionId}:{#accountId}:havip/{#HaVipId}
  • Ipv4Gateway
    acs:vpc:{#regionId}:{#accountId}:ipv4gateway/{#Ipv4GatewayId}
  • Ipv6Gateway
    acs:vpc:{#regionId}:{#accountId}:ipv6gateway/{#Ipv6GatewayId}
  • PublicIpAddressPool
    acs:vpc:{#regionId}:{#accountId}:publicipaddresspool/{#PublicIpAddressPoolId}
  • TrafficMirrorFilter
    acs:vpc:{#regionId}:{#accountId}:trafficmirrorfilter/{#TrafficMirrorFilterId}
  • TrafficMirrorSession
    acs:vpc:{#regionId}:{#accountId}:trafficmirrorsession/{#TrafficMirrorSessionId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ResourceIdstringYes

The resource ID.

vpc-hp31psbg8ec3023s6****
ResourceTypestringYes

The type of the resource for which you want to modify the resource group. Valid values:

  • Vpc
  • Eip
  • BandwidthPackage
  • PrefixList
  • PublicIpAddressPool
  • FlowLog
  • HaVip
  • TrafficMirrorFilter
  • TrafficMirrorSession
  • IPv4Gateway
  • IPv6Gateway
  • DhcpOptionsSet
  • GatewayEndpoint
vpc
NewResourceGroupIdstringYes

The ID of the resource group to which you want to move the resource.

Note You can use resource groups to facilitate resource grouping and permission management for an Alibaba Cloud. For more information, see What is resource management?
rg-acfm3peow3k****
RegionIdstringYes

The ID of the region to which the cloud resource belongs.

You can call the DescribeRegions operation to query the most recent region list.

cn-hangzhou

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The request ID.

611CB80C-B6A9-43DB-9E38-0B0AC3D9B58F

Examples

Sample success responses

JSONformat

{
  "RequestId": "611CB80C-B6A9-43DB-9E38-0B0AC3D9B58F"
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidResourceGroupIdThe specified ResourceGroupId does not exist.The specified resource group ID does not exist.
400InvalidResourceId.NotFoundThe specified ResourceId does not exist.The specified resource ID does not exist.
400IllegalParam.ResourceTypeInvalid Resource Type value.The ResourceType parameter is not supported or set to an invalid value.
400OperationFailed.InstanceStatusNotAllowedThe current status of the resource does not support this operation.The resource in this state does not support the current operation.
400IncorrectStatus.VpcThe status of %s [%s] is incorrect.The instance is in an invalid state.
404InvalidBandwidthPackageId.NotFoundThe specified bandwidthPackage resourceId does not exist in our records.The error message returned because the specified EIP bandwidth plan does not exist.

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

Change history

Change timeSummary of changesOperation
2023-08-09The Error code has changedView Change Details
2023-07-18The Error code has changedView Change Details
2023-05-17The Error code has changedView Change Details