tencent cloud



最后更新时间:2023-03-15 10:24:59

1. API Description

Domain name for API request: cam.tencentcloudapi.com.

This API is used to delete a sub-user.

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: DeleteUser.
Version Yes String Common Params. The value used for this API: 2019-01-16.
Region No String Common Params. This parameter is not required for this API.
Name Yes String Sub-user username
Force No Integer Whether to forcibly delete the sub-user. The default input parameter is 0. 0: do not delete the user if the user has undeleted API keys; 1: first delete the API keys then delete the user if the user has undeleted API keys. To delete API keys, you need to have cam:DeleteApiKey permission, which enables you to delete both enabled and disabled API keys. If you do not have this permission, you will not be able to delete API keys and the user.

3. Output Parameters

Parameter Name Type Description
RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

4. Example

Example1 Deleting a sub-user

This example shows you how to delete a sub-user.

Input Example

Host: cam.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DeleteUser
<Common request parameters>

    "Name": "test124"

Output Example

    "Response": {
        "RequestId": "b46d2afe-6893-4529-bc96-2c82d9214957"

5. Developer Resources


TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
AuthFailure.UnauthorizedOperation No permission.
FailedOperation Operation failed.
OperationDenied.HaveKeys There are undeleted API keys.
RequestLimitExceeded.UinLimitExceeded The user account limit has been reached.
ResourceNotFound.UserNotExist User does not exist.
UnauthorizedOperation.DeleteApiKey User do not have the authorization to delete API keys.




7x24 电话支持