Switch Active and Standby For RouteTargetGroup.
Operation description
Switch Active and Standby For RouteTargetGroup.
Debugging
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 Resourcesis 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.
| Operation | Access level | Resource type | Condition key | Associated operation |
|---|---|---|---|---|
| vpc:SwitchActiveRouteTarget | update | *RouteTargetGroup acs:vpc:{#regionId}:{#accountId}:routetargetgroup/{#RouteTargetGroupId} |
| none |
Request parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
| RouteTargetGroupId | string | Yes | The instance ID of the RouteTargetGroup. | rtg-xxxx |
| RegionId | string | Yes | The region ID where the RouteTargetGroup is located. You can obtain the region ID by calling the DescribeRegions API. | cn-hangzhou |
| ClientToken | string | No | Client token, used to ensure the idempotence of the request. Generate a unique value for this parameter from your client to ensure that it is unique across different requests. The ClientToken only supports ASCII characters. Note: If you do not specify this, the system will automatically use the RequestId of the API request as the ClientToken identifier. The RequestId may differ for each API request. | 0c593ea1-3bea-11e9-b96b-88e9fe6**** |
| Tag | array<object> | No | Resource tags. | |
| object | No | List of resource tags. | ||
| Key | string | No | The key of the resource tag. Up to 20 tag keys are supported. If you need to pass this value, you cannot input an empty string. Each tag key can have up to 128 characters and cannot start with | FinanceDept |
| Value | string | No | The value of the resource tag. Up to 20 tag values are supported. If you need to pass this value, you can input an empty string. A maximum of 128 characters is allowed. The value cannot start with | FinanceJoshua |
Response parameters
Examples
Sample success responses
JSONformat
{
"RequestId": "C1221A1F-2ACD-4592-8F27-474E02883159"
}Error codes
| HTTP status code | Error code | Error message | Description |
|---|---|---|---|
| 400 | ResourceNotFound.RouteTargetGroup | The specified resource of %s is not found. | The specified resource% s does not exist. |
| 400 | IncorrectStatus.RouteTargetGroup | The status of %s [%s] is incorrect. | The current state of the RouteTargetGroup prohibits the operation. |
| 400 | OperationDenied.SwitchToAbnormalMember | The operation is not allowed because of the inability to switch the RouteTargetMember when the disabled member is in an unhealthy state. | The operation is not allowed because of the inability to switch the RouteTargetMember when the disabled member is in an unhealthy state. |
For a list of error codes, visit the Service error codes.
Change history
| Change time | Summary of changes | Operation |
|---|---|---|
| 2026-01-04 | Add Operation | View Change Details |
