Updating Tenant Configuration
Function
This API is used to update tenant configuration.
Calling Method
For details, see Calling APIs.
Authorization Information
Each account root user has all the permissions required to call all APIs, but IAM users must be assigned the following required identity policy-based permissions. For details about the required permissions, see Permissions Policies and Supported Actions.
| Action | Access Level | Resource Type (*: required) | Condition Key | Alias | Dependencies |
|---|---|---|---|---|---|
| codeartscheck::updateConfig | Write | - | - | - | - |
URI
PUT /v1/tenant-configs/{id}
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| id | Yes | String | Tenant configuration ID. |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | Definition User token. Obtain one by calling the IAM API Obtaining a User Token. The value of X-Subject-Token in the response header is a token. Constraints N/A Range The length is the value of [1-100000]. Default Value N/A |
| Content-Type | Yes | String | Definition Encoding format. Constraints N/A Range N/A Default Value application/json: The return value is in JSON format for any input value. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| key | Yes | String | Definition: Key of the tenant configuration. If the tenant check language is configured, the value starts with languageFileSuffix_ followed by the required language. Constraints: N/A Range: N/A Default value: N/A |
| value | Yes | String | Definition: Value of the tenant configuration. If the tenant check language is configured, the value indicates the file name extension of the current language. Multiple file name extensions are separated by commas (,). Constraints: N/A Range: N/A Default value: N/A |
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| id | String | Definition ID of the tenant configuration. Range N/A |
| key | String | Definition Key of the tenant configuration. If the tenant check language is configured, the value starts with languageFileSuffix_ followed by the language. Range N/A |
| value | String | Definition Value of the tenant configuration. If the tenant check language is configured, the value indicates the file name extension of the current language. Multiple file name extensions are separated by commas (,). Range N/A |
| description | String | Definition Description of the tenant configuration. Range N/A |
| create_time | String | Definition Time when a tenant configuration is created. Range N/A |
| last_update_time | String | Definition Last update time of a tenant configuration. Range N/A |
| creator | String | Definition Creator of a tenant configuration. Range N/A |
| last_reviser | String | Definition Last modifier of a tenant configuration. Range N/A |
| domain_id | String | Definition Tenant ID, which is the same as the IAM tenant ID. Range N/A |
| has_default_config | Boolean | Definition Whether the default configuration item exists. For example, for the tenant language, the system language has a default file suffix, so the value is true. The tenant-defined language does not have a default file suffix, so the value is false. Range N/A |
Status code: 400
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition: Error code. Value range: N/A |
| error_msg | String | Definition: Error message. Value range: N/A |
Status code: 401
| Parameter | Type | Description |
|---|---|---|
| error_code | String | Definition: Error code. Value range: N/A |
| error_msg | String | Definition: Error message. Value range: N/A |
Example Requests
Modify the system configuration whose ID is bbcc56db34b149f0a15bd106dc3ae5b5, key is languageFileSuffix_Fortran, and value is** f,f90,F**.
PUT https://{endpoint}/v1/tenant-configs/bbcc56db34b149f0a15bd106dc3ae5b5
{
"key" : "languageFileSuffix_Fortran",
"value" : "f,f90,F"
} Example Responses
Status code: 200
Tenant configuration updated.
{
"id" : "bbcc56db34b149f0a15bd106dc3ae5b5",
"key" : "languageFileSuffix_Fortran",
"value" : "f,f90,F",
"description" : null,
"create_time" : null,
"creator" : null,
"last_reviser" : null,
"domain_id" : "389efb76b1354e4482eabeed25c895e4",
"has_default_config" : false,
"last_update_time" : null
} Status code: 400
A request error occurred.
{
"error_code" : "CC.xxxxxxxx.400",
"error_msg" : "Verify request parameter failed. Check whether the request parameters are correct."
} Status code: 401
The permission is insufficient.
{
"error_code" : "CC.00000003",
"error_msg" : "Authentication information expired."
} Status Codes
| Status Code | Description |
|---|---|
| 200 | Tenant configuration updated. |
| 400 | A request error occurred. |
| 401 | The permission is insufficient. |
Error Codes
See Error Codes.
What is your overall rating for this page?
Thank 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