Performing Operations on an O&M Account
Function
This API is used to perform operations on a database O&M account.
Calling Method
For details, see Calling APIs.
URI
POST /v1/{project_id}/clusters/{cluster_id}/db-manager/om-user/action
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Definition Project ID. To obtain the value, see Obtaining a Project ID. Constraints N/A Range N/A Default Value N/A |
cluster_id |
Yes |
String |
Definition Cluster ID. For details about how to obtain the value, see Obtaining the Cluster ID. Constraints The value must be a valid DWS cluster ID. Range It is a 36-digit UUID. Default Value N/A |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
operation |
Yes |
String |
Definition Operation type. Range addOmUser: adding an O&M user deleteOmUser: deleting an O&M user. increaseOmUserPeriod: extending the validity period of an O&M user. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
error_code |
Integer |
Definition Error code. Non-zero values indicate abnormal scenarios. Range N/A |
error_msg |
String |
Definition Error message. Range N/A |
om_user_info |
DatabaseOmUserInfo object |
Definition O&M user information. Range N/A |
Example Requests
-
Add an O&M account.
https://{Endpoint}/dws/rest-dms/v1.0/05f2cff45100d5112f4bc00b794ea08e/clusters/e7107fab-cac0-4261-916b-7f32b3053034/db-manager/om-user/action { "operation" : "addOmUser" }
-
Delete an O&M account.
https://{Endpoint}/dws/rest-dms/v1.0/05f2cff45100d5112f4bc00b794ea08e/clusters/e7107fab-cac0-4261-916b-7f32b3053034/db-manager/om-user/action { "operation" : "deleteOmUser" }
-
Extend the validity period of an O&M account.
https://{Endpoint}/dws/rest-dms/v1.0/05f2cff45100d5112f4bc00b794ea08e/clusters/e7107fab-cac0-4261-916b-7f32b3053034/db-manager/om-user/action { "operation" : "increaseOmUserPeriod" }
Example Responses
Status code: 200
Operation succeeded.
{ "error_code" : 0, "error_msg" : null, "om_user_info" : { "om_user_status" : "on", "om_user_expires_time" : 1747214333491 } }
Status Codes
Status Code |
Description |
---|---|
200 |
Operation succeeded. |
400 |
Request error. |
401 |
Authentication failed. |
403 |
You do not have required permissions. |
404 |
No resources found. |
500 |
Internal server error. |
503 |
Service unavailable. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot