From 78ca32de839e6506514666877c4a8cbda035ce7a Mon Sep 17 00:00:00 2001 From: OpenTelekomCloud Proposal Bot Date: Thu, 4 Jan 2024 12:55:24 +0000 Subject: [PATCH] Update content --- .../ddm_accounts/creating_a_ddm_account.rst | 219 ------------------ .../ddm_accounts/deleting_a_ddm_account.rst | 137 ----------- .../apis_recommended/ddm_accounts/index.rst | 10 - .../ddm_accounts/modifying_a_ddm_account.rst | 198 ---------------- .../ddm_accounts/querying_ddm_accounts.rst | 209 ----------------- ...esetting_the_password_of_a_ddm_account.rst | 153 ------------ 6 files changed, 926 deletions(-) delete mode 100644 api-ref/source/apis_recommended/ddm_accounts/creating_a_ddm_account.rst delete mode 100644 api-ref/source/apis_recommended/ddm_accounts/deleting_a_ddm_account.rst delete mode 100644 api-ref/source/apis_recommended/ddm_accounts/modifying_a_ddm_account.rst delete mode 100644 api-ref/source/apis_recommended/ddm_accounts/querying_ddm_accounts.rst delete mode 100644 api-ref/source/apis_recommended/ddm_accounts/resetting_the_password_of_a_ddm_account.rst diff --git a/api-ref/source/apis_recommended/ddm_accounts/creating_a_ddm_account.rst b/api-ref/source/apis_recommended/ddm_accounts/creating_a_ddm_account.rst deleted file mode 100644 index f01a9a3..0000000 --- a/api-ref/source/apis_recommended/ddm_accounts/creating_a_ddm_account.rst +++ /dev/null @@ -1,219 +0,0 @@ -:original_name: ddm_07_0001.html - -.. _ddm_07_0001: - -Creating a DDM Account -====================== - -Function --------- - -This API is used to create a DDM account. DDM accounts are used to connect to and manage schemas. A maximum of 100 DDM accounts can be created for each DDM instance, and one DDM account can be associated with multiple schemas. - -Constraints ------------ - -None - -URI ---- - -POST /v1/{project_id}/instances/{instance_id}/users - -.. table:: **Table 1** Path parameters - - =========== ========= ====== ================================== - Parameter Mandatory Type Description - =========== ========= ====== ================================== - project_id Yes String Project ID of a tenant in a region - instance_id Yes String DDM instance ID - =========== ========= ====== ================================== - -Request Parameters ------------------- - -.. table:: **Table 2** Request header parameters - - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+======================================================================================================================+ - | X-Auth-Token | Yes | String | User token | - | | | | | - | | | | It can be obtained by calling an IAM API. The value of **X-Subject-Token** in the response header is the user token. | - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - -.. table:: **Table 3** Request body parameters - - +-----------+-----------+--------------------------------------------------------------------------------+-------------------------+ - | Parameter | Mandatory | Type | Description | - +===========+===========+================================================================================+=========================+ - | users | Yes | Array of :ref:`CreateUsersInfo ` objects | DDM account information | - +-----------+-----------+--------------------------------------------------------------------------------+-------------------------+ - -.. _ddm_07_0001__request_createusersinfo: - -.. table:: **Table 4** CreateUsersInfo - - +-----------------+-----------------+------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+==========================================================================================+===============================================================================================================================+ - | name | Yes | String | Username of the DDM account, which: | - | | | | | - | | | | - Can include 1 to 32 characters. | - | | | | - Must start with a letter. | - | | | | - Can contain only letters, digits, and underscores (_). | - | | | | | - | | | | Minimum length: 1 character | - | | | | | - | | | | Maximum length: 32 characters | - +-----------------+-----------------+------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------+ - | password | Yes | String | DDM account password | - +-----------------+-----------------+------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------+ - | base_authority | Yes | Array of strings | Basic permissions of the DDM account. | - | | | | | - | | | | The value can be **CREATE**, **DROP**, **ALTER**, **INDEX**, **INSERT**, **DELETE**, **UPDATE**, or **SELECT**. | - | | | | | - | | | | Enumerated values: | - | | | | | - | | | | - **CREATE** | - | | | | - **DROP** | - | | | | - **ALTER** | - | | | | - **INDEX** | - | | | | - **INSERT** | - | | | | - **DELETE** | - | | | | - **UPDATE** | - | | | | - **SELECT** | - +-----------------+-----------------+------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------+ - | description | No | String | Description of the DDM account, which cannot exceed 256 characters. It is left blank by default. | - | | | | | - | | | | Maximum length: 256 characters | - +-----------------+-----------------+------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------+ - | databases | No | Array of :ref:`CreateUsersDatabases ` objects | Associated schemas. The **databases** field is optional. You can create a DDM account without associating it with any schema. | - +-----------------+-----------------+------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------+ - -.. _ddm_07_0001__request_createusersdatabases: - -.. table:: **Table 5** CreateUsersDatabases - - ========= ========= ====== ============================= - Parameter Mandatory Type Description - ========= ========= ====== ============================= - name Yes String Name of the associated schema - ========= ========= ====== ============================= - -Response Parameters -------------------- - -**Status code: 200** - -.. table:: **Table 6** Response body parameters - - +-----------+-------------------------------------------------------------------------------------------------------+-------------------------+ - | Parameter | Type | Description | - +===========+=======================================================================================================+=========================+ - | users | Array of :ref:`CreateUsersDetailResponses ` objects | DDM account information | - +-----------+-------------------------------------------------------------------------------------------------------+-------------------------+ - -.. _ddm_07_0001__response_createusersdetailresponses: - -.. table:: **Table 7** CreateUsersDetailResponses - - ========= ====== =========================== - Parameter Type Description - ========= ====== =========================== - name String Username of the DDM account - ========= ====== =========================== - -**Status code: 400** - -.. table:: **Table 8** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -**Status code: 500** - -.. table:: **Table 9** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -Example Request ---------------- - -.. code-block:: text - - POST https://{endpoint}/v1/{project_id}/instances/{instance_id}/users - - { - "users" : [ { - "name" : "DDMuser1", - "password" : "Axejs@98a", - "base_authority" : [ "CREATE", "DROP", "ALTER", "INDEX", "INSERT", "DELETE", "UPDATE", "SELECT" ], - "description" : "", - "databases" : [ { - "name" : "DDMdb1" - } ] - } ] - } - -Example Response ----------------- - -**Status code: 200** - -OK - -.. code-block:: - - { - "users" : [ { - "name" : "DDMuser1" - } ] - } - -**Status code: 400** - -bad request - -.. code-block:: - - { - "externalMessage" : "Parameter error.", - "errCode" : "DBS.280001" - } - -**Status code: 500** - -server error - -.. code-block:: - - { - "externalMessage" : "Server failure.", - "errCode" : "DBS.200412" - } - -Status Codes ------------- - -=========== ============ -Status Code Description -=========== ============ -200 OK -400 bad request -500 server error -=========== ============ - -Error Codes ------------ - -For details, see :ref:`Error Codes `. diff --git a/api-ref/source/apis_recommended/ddm_accounts/deleting_a_ddm_account.rst b/api-ref/source/apis_recommended/ddm_accounts/deleting_a_ddm_account.rst deleted file mode 100644 index 93b1a38..0000000 --- a/api-ref/source/apis_recommended/ddm_accounts/deleting_a_ddm_account.rst +++ /dev/null @@ -1,137 +0,0 @@ -:original_name: ddm_api_01_0045.html - -.. _ddm_api_01_0045: - -Deleting a DDM Account -====================== - -Function --------- - -This API is used to delete a DDM account. This operation will also disassociate the account from associated schemas if any. - -Constraints ------------ - -None - -URI ---- - -DELETE /v1/{project_id}/instances/{instance_id}/users/{username} - -.. table:: **Table 1** Path parameters - - =========== ========= ====== ========================================= - Parameter Mandatory Type Description - =========== ========= ====== ========================================= - project_id Yes String Project ID - instance_id Yes String DDM instance ID - username Yes String Username of the DDM account to be deleted - =========== ========= ====== ========================================= - -Request Parameters ------------------- - -.. table:: **Table 2** Request header parameters - - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+======================================================================================================================+ - | X-Auth-Token | Yes | String | User token | - | | | | | - | | | | It can be obtained by calling an IAM API. The value of **X-Subject-Token** in the response header is the user token. | - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - -Response Parameters -------------------- - -**Status code: 200** - -.. table:: **Table 3** Response body parameters - - ========= ====== =========================== - Parameter Type Description - ========= ====== =========================== - name String Username of the DDM account - ========= ====== =========================== - -**Status code: 400** - -.. table:: **Table 4** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -**Status code: 500** - -.. table:: **Table 5** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -Example Request ---------------- - -.. code-block:: text - - DELETE https://{endpoint}/v1/{project_id}/instances/{instance_id}/users/{username} - -Example Response ----------------- - -**Status code: 200** - -OK - -.. code-block:: - - { - "name" : "ddmtest" - } - -**Status code: 400** - -bad request - -.. code-block:: - - { - "externalMessage" : "Parameter error.", - "errCode" : "DBS.280001" - } - -**Status code: 500** - -server error - -.. code-block:: - - { - "externalMessage" : "Server failure.", - "errCode" : "DBS.200412" - } - -Status Codes ------------- - -=========== ============ -Status Code Description -=========== ============ -200 OK -400 bad request -500 server error -=========== ============ - -Error Codes ------------ - -For details, see :ref:`Error Codes `. diff --git a/api-ref/source/apis_recommended/ddm_accounts/index.rst b/api-ref/source/apis_recommended/ddm_accounts/index.rst index 99d318e..307a2a7 100644 --- a/api-ref/source/apis_recommended/ddm_accounts/index.rst +++ b/api-ref/source/apis_recommended/ddm_accounts/index.rst @@ -5,11 +5,6 @@ DDM Accounts ============ -- :ref:`Creating a DDM Account ` -- :ref:`Querying DDM Accounts ` -- :ref:`Modifying a DDM Account ` -- :ref:`Deleting a DDM Account ` -- :ref:`Resetting the Password of a DDM Account ` - :ref:`Managing the Administrator Password ` - :ref:`Validating Password Strength ` @@ -17,10 +12,5 @@ DDM Accounts :maxdepth: 1 :hidden: - creating_a_ddm_account - querying_ddm_accounts - modifying_a_ddm_account - deleting_a_ddm_account - resetting_the_password_of_a_ddm_account managing_the_administrator_password validating_password_strength diff --git a/api-ref/source/apis_recommended/ddm_accounts/modifying_a_ddm_account.rst b/api-ref/source/apis_recommended/ddm_accounts/modifying_a_ddm_account.rst deleted file mode 100644 index a532acd..0000000 --- a/api-ref/source/apis_recommended/ddm_accounts/modifying_a_ddm_account.rst +++ /dev/null @@ -1,198 +0,0 @@ -:original_name: ddm_api_01_0044.html - -.. _ddm_api_01_0044: - -Modifying a DDM Account -======================= - -Function --------- - -This API is used to modify the permissions and associated schemas of a DDM account. - -Constraints ------------ - -At least one of the following parameters must be configured: **password**, **base_authority**, **role**, **description**, and **databases**. - -URI ---- - -PUT /v1/{project_id}/instances/{instance_id}/users/{username} - -.. table:: **Table 1** Path parameters - - =========== ========= ====== =========================== - Parameter Mandatory Type Description - =========== ========= ====== =========================== - project_id Yes String Project ID - instance_id Yes String DDM instance ID - username Yes String Username of the DDM account - =========== ========= ====== =========================== - -Request Parameters ------------------- - -.. table:: **Table 2** Request header parameters - - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+======================================================================================================================+ - | X-Auth-Token | Yes | String | User token | - | | | | | - | | | | It can be obtained by calling an IAM API. The value of **X-Subject-Token** in the response header is the user token. | - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - -.. table:: **Table 3** Request body parameters - - +-----------+-----------+----------------------------------------------------------------------------------+-------------------------+ - | Parameter | Mandatory | Type | Description | - +===========+===========+==================================================================================+=========================+ - | user | Yes | :ref:`UpdateUserDetailReq ` object | DDM account information | - +-----------+-----------+----------------------------------------------------------------------------------+-------------------------+ - -.. _ddm_api_01_0044__request_updateuserdetailreq: - -.. table:: **Table 4** UpdateUserDetailReq - - +-----------------+-----------------+----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+==============================================================================================+=================================================================================================================+ - | base_authority | No | Array of strings | Basic permissions of the DDM account. The default value is the original account permission. | - | | | | | - | | | | The value can be **CREATE**, **DROP**, **ALTER**, **INDEX**, **INSERT**, **DELETE**, **UPDATE**, or **SELECT**. | - | | | | | - | | | | Enumerated values: | - | | | | | - | | | | - **CREATE** | - | | | | - **DROP** | - | | | | - **ALTER** | - | | | | - **INDEX** | - | | | | - **INSERT** | - | | | | - **DELETE** | - | | | | - **UPDATE** | - | | | | - **SELECT** | - +-----------------+-----------------+----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | description | No | String | Description of the DDM account, which cannot exceed 256 characters. | - | | | | | - | | | | It is left blank by default. | - | | | | | - | | | | Maximum length: 256 characters | - +-----------------+-----------------+----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | databases | No | Array of :ref:`UpdateUsersDatabases ` objects | DDM account information | - +-----------------+-----------------+----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - -.. _ddm_api_01_0044__request_updateusersdatabases: - -.. table:: **Table 5** UpdateUsersDatabases - - +-----------------+-----------------+-----------------+------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+==================================================================================================================+ - | name | No | String | Schema name, which is case-insensitive. The **databases** and **name** fields must be both or neither specified. | - | | | | | - | | | | The parameter is left blank by default. | - +-----------------+-----------------+-----------------+------------------------------------------------------------------------------------------------------------------+ - -Response Parameters -------------------- - -**Status code: 200** - -.. table:: **Table 6** Response body parameters - - ========= ====== =========================== - Parameter Type Description - ========= ====== =========================== - name String Username of the DDM account - ========= ====== =========================== - -**Status code: 400** - -.. table:: **Table 7** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -**Status code: 500** - -.. table:: **Table 8** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -Example Request ---------------- - -.. code-block:: text - - PUT https://{endpoint}/v1/{project_id}/instances/{instance_id}/users/{username} - - { - "user" : { - "base_authority" : [ "SELECT" ], - "description" : "test11", - "databases" : [ { - "name" : "db_7350" - } ] - } - } - -Example Response ----------------- - -**Status code: 200** - -OK - -.. code-block:: - - { - "name" : "ddmtest" - } - -**Status code: 400** - -bad request - -.. code-block:: - - { - "externalMessage" : "Parameter error.", - "errCode" : "DBS.280001" - } - -**Status code: 500** - -server error - -.. code-block:: - - { - "externalMessage" : "Server failure.", - "errCode" : "DBS.200412" - } - -Status Codes ------------- - -=========== ============ -Status Code Description -=========== ============ -200 OK -400 bad request -500 server error -=========== ============ - -Error Codes ------------ - -For details, see :ref:`Error Codes `. diff --git a/api-ref/source/apis_recommended/ddm_accounts/querying_ddm_accounts.rst b/api-ref/source/apis_recommended/ddm_accounts/querying_ddm_accounts.rst deleted file mode 100644 index e21e68d..0000000 --- a/api-ref/source/apis_recommended/ddm_accounts/querying_ddm_accounts.rst +++ /dev/null @@ -1,209 +0,0 @@ -:original_name: ddm_api_01_0043.html - -.. _ddm_api_01_0043: - -Querying DDM Accounts -===================== - -Function --------- - -This API is used to query DDM accounts. - -Constraints ------------ - -None - -URI ---- - -GET /v1/{project_id}/instances/{instance_id}/users?offset={offset}&limit={limit} - -.. table:: **Table 1** Path parameters - - =========== ========= ====== =============== - Parameter Mandatory Type Description - =========== ========= ====== =============== - project_id Yes String Project ID - instance_id Yes String DDM instance ID - =========== ========= ====== =============== - -.. table:: **Table 2** Query parameters - - +-----------------+-----------------+-----------------+--------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+========================================================================================================+ - | offset | No | Integer | Index offset. | - | | | | | - | | | | The query starts from the next piece of data indexed by this parameter. The value is **0** by default. | - | | | | | - | | | | The value must be a positive integer. | - +-----------------+-----------------+-----------------+--------------------------------------------------------------------------------------------------------+ - | limit | No | Integer | A maximum of DDM accounts to be queried. | - | | | | | - | | | | Value range: 1 to 128. | - | | | | | - | | | | If the parameter value is not specified, 10 accounts are queried by default. | - +-----------------+-----------------+-----------------+--------------------------------------------------------------------------------------------------------+ - -Request Parameters ------------------- - -.. table:: **Table 3** Request header parameters - - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+======================================================================================================================+ - | X-Auth-Token | Yes | String | User token. | - | | | | | - | | | | It can be obtained by calling an IAM API. The value of **X-Subject-Token** in the response header is the user token. | - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - -Response Parameters -------------------- - -**Status code: 202** - -.. table:: **Table 4** Response body parameters - - +--------------+-------------------------------------------------------------------------------------------------------------+----------------------------------+ - | Parameter | Type | Description | - +==============+=============================================================================================================+==================================+ - | users | Array of :ref:`GetUsersListDetailResponses ` objects | DDM account information | - +--------------+-------------------------------------------------------------------------------------------------------------+----------------------------------+ - | page_no | Integer | Current page | - +--------------+-------------------------------------------------------------------------------------------------------------+----------------------------------+ - | page_size | Integer | Data records on the current page | - +--------------+-------------------------------------------------------------------------------------------------------------+----------------------------------+ - | total_record | Integer | Total records | - +--------------+-------------------------------------------------------------------------------------------------------------+----------------------------------+ - | total_page | Integer | Total pages | - +--------------+-------------------------------------------------------------------------------------------------------------+----------------------------------+ - -.. _ddm_api_01_0043__response_getuserslistdetailresponses: - -.. table:: **Table 5** GetUsersListDetailResponses - - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | Parameter | Type | Description | - +=======================+===============================================================================================+=================================================================================================================+ - | name | String | Username of the DDM account | - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | status | String | Status of the DDM account | - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | base_authority | Array of strings | Basic permissions of the DDM account. | - | | | | - | | | The value can be **CREATE**, **DROP**, **ALTER**, **INDEX**, **INSERT**, **DELETE**, **UPDATE**, or **SELECT**. | - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | description | String | Description of the DDM account | - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | created | Integer | Time when the DDM account is created | - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - | databases | Array of :ref:`GetUsersListdatabase ` objects | Associated schemas | - +-----------------------+-----------------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------+ - -.. _ddm_api_01_0043__response_getuserslistdatabase: - -.. table:: **Table 6** GetUsersListdatabase - - =========== ====== ================================================== - Parameter Type Description - =========== ====== ================================================== - name String Name of the schema associated with the DDM account - description String Schema description - =========== ====== ================================================== - -**Status code: 400** - -.. table:: **Table 7** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -**Status code: 500** - -.. table:: **Table 8** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -Example Request ---------------- - -.. code-block:: text - - GET https://{endpoint}/v1/{project_id}/instances/{instance_id}/users?offset={offset}&limit={limit} - -Example Response ----------------- - -**Status code: 202** - -OK - -.. code-block:: - - { - "users" : [ { - "name" : "ddmtest", - "status" : "RUNNING", - "base_authority" : [ "SELECT" ], - "description" : "Account", - "created" : 1686904661709, - "databases" : [ { - "name" : "test", - "description" : "Schema" - } ] - } ], - "page_no" : 1, - "page_size" : 10, - "total_record" : 1, - "total_page" : 1 - } - -**Status code: 400** - -bad request - -.. code-block:: - - { - "externalMessage" : "Parameter error.", - "errCode" : "DBS.280001" - } - -**Status code: 500** - -server error - -.. code-block:: - - { - "externalMessage" : "Server failure.", - "errCode" : "DBS.200412" - } - -Status Codes ------------- - -=========== ============ -Status Code Description -=========== ============ -202 OK -400 bad request -500 server error -=========== ============ - -Error Codes ------------ - -For details, see :ref:`Error Codes `. diff --git a/api-ref/source/apis_recommended/ddm_accounts/resetting_the_password_of_a_ddm_account.rst b/api-ref/source/apis_recommended/ddm_accounts/resetting_the_password_of_a_ddm_account.rst deleted file mode 100644 index 78f17bf..0000000 --- a/api-ref/source/apis_recommended/ddm_accounts/resetting_the_password_of_a_ddm_account.rst +++ /dev/null @@ -1,153 +0,0 @@ -:original_name: ddm_api_01_0088.html - -.. _ddm_api_01_0088: - -Resetting the Password of a DDM Account -======================================= - -Function --------- - -This API is used to reset the password of a DDM account. - -Constraints ------------ - -None - -URI ---- - -POST /v2/{project_id}/instances/{instance_id}/users/{username}/password - -.. table:: **Table 1** Path parameters - - =========== ========= ====== ========================================== - Parameter Mandatory Type Description - =========== ========= ====== ========================================== - project_id Yes String Project ID - instance_id Yes String DDM instance ID - username Yes String Username of the DDM account to be modified - =========== ========= ====== ========================================== - -Request Parameters ------------------- - -.. table:: **Table 2** Request header parameters - - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - | Parameter | Mandatory | Type | Description | - +=================+=================+=================+======================================================================================================================+ - | X-Auth-Token | Yes | String | User token | - | | | | | - | | | | It can be obtained by calling an IAM API. The value of **X-Subject-Token** in the response header is the user token. | - +-----------------+-----------------+-----------------+----------------------------------------------------------------------------------------------------------------------+ - -.. table:: **Table 3** Request body parameters - - ========= ========= ====== ============ - Parameter Mandatory Type Description - ========= ========= ====== ============ - password Yes String New password - ========= ========= ====== ============ - -Response Parameters -------------------- - -**Status code: 200** - -.. table:: **Table 4** Response body parameters - - =========== ======= =================================== - Parameter Type Description - =========== ======= =================================== - success Boolean Whether the operation is successful - instance_id String DDM instance ID - user_name String Username of the DDM account - =========== ======= =================================== - -**Status code: 400** - -.. table:: **Table 5** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -**Status code: 500** - -.. table:: **Table 6** Response body parameters - - =============== ====== ================== - Parameter Type Description - =============== ====== ================== - errCode String Service error code - externalMessage String Error message - =============== ====== ================== - -Example Request ---------------- - -.. code-block:: text - - POST https://{endpoint}/v2/{project_id}/instances/{instance_id}/users/{username}/password - - { - "success": true, - "instance_id": "e6b99563-xxxx-xxxx-xxxx-1820d4fd2a67", - "user_name" : "ddmtest" - } - -Example Response ----------------- - -**Status code: 200** - -OK - -.. code-block:: - - { - "name" : "ddmtest" - } - -**Status code: 400** - -bad request - -.. code-block:: - - { - "externalMessage" : "Parameter error.", - "errCode" : "DBS.280001" - } - -**Status code: 500** - -server error - -.. code-block:: - - { - "externalMessage" : "Server failure.", - "errCode" : "DBS.200412" - } - -Status Codes ------------- - -=========== ============ -Status Code Description -=========== ============ -200 OK -400 bad request -500 server error -=========== ============ - -Error Codes ------------ - -For details, see :ref:`Error Codes `.