Overview
You can call this API to modify the primary zone of a tenant.
API details
Constraints
The caller must have an AccessKey for accessing the multi-cloud API. For information about how to obtain the AccessKey ID and AccessKey secret, see Manage AccessKeys.
Request path
PUT api/v2/instances/{instanceId}/tenants/{tenantId}/primaryZone
Request parameters
Path
| Parameter | Type | Required | Description |
|---|---|---|---|
| instanceId | String | Yes | The ID of the instance. |
| tenantId | String | Yes | The ID of the tenant. |
Body
| Parameter | Type | Required | Description |
|---|---|---|---|
| primaryZone | String | Yes | The primary zone of the tenant. |
| proxyAddressMasterZone | String | Yes | The primary zone of the link. |
Response parameters
| Parameter | Type | Description |
|---|---|---|
| requestId | String | The ID of the request. |
| success | Boolean | Indicates whether the request was successful. |
Examples
Request example
curl --digest -u 'ak:sk' \
-X PUT \
'https://api-cloud.oceanbase.com/api/v2/instances/{instanceId}/tenants/{tenantId}/primaryZone' \
--data '{
"primaryZone": "primaryZone_7766715fb478",
"proxyAddressMasterZone": "proxyAddressMasterZone_c0831d11a19e"
}'
Response example
JSON format
{
"requestId": "xxxxxx",
"success": true
}
Differences from the public cloud
The multi-cloud and public cloud have significant differences. In the public cloud, you can modify the primary zone of a tenant and the primary zone of a link at the same time. You need to specify the corresponding VPC and VSwitch.