Overview
You can call this API to modify the status of a tenant user.
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}/tenantUsers/{userName}/status
Request parameters
Path
| Parameter | Type | Required | Description | Example value |
|---|---|---|---|---|
| instanceId | String | Yes | The ID of the instance. | obxxx |
| tenantId | String | Yes | The ID of the tenant. | txxx |
| userName | String | Yes | The name of the user. | testuser |
Body
| Parameter | Type | Required | Description | Example value |
|---|---|---|---|---|
| status | String | Yes | The status of the user. Valid values: ONLINE (normal) and LOCKED (locked). | LOCKED |
Response parameters
| Parameter | Type | Description | Example value |
|---|---|---|---|
| requestId | String | The ID of the request. | b34ae828-5bb0-4ca6-aa76-5fa387c5f3d2 |
| success | Boolean | Indicates whether the request was successful. | true |
Examples
Request example
curl --digest -u 'ak:sk' \
-X PUT \
'https://api-cloud.oceanbase.com/api/v2/instances/{instanceId}/tenants/{tenantId}/tenantUsers/{userName}/status' \
--data '{"status":"LOCKED"}'
Response example
JSON format
{
"requestId": "b34ae828-5bb0-4ca6-aa76-5fa387c5f3d2",
"success": true
}