AddUserToGroup

Last updated: 2019-09-09 21:43:50

PDF

1. API Description

API domain name: cam.tencentcloudapi.com.

This API adds a user to a user group

Default API request rate limit: 20 requests/sec.

2. Input Parameters

The following parameters are required for requesting this API, including action-specific parameters and common parameters. For more information about common parameters for all requests, see Common Request Parameters.

Parameter name Required Type Description
Action Yes String Common parameter; the name of this API: AddUserToGroup
Version Yes String Common parameter; the version of this API: 2019-01-16
Region No String Common parameter; optional for this API.
Info.N Yes Array of GroupIdOfUidInfo The relationship between sub-user’s UID and the ID of the user group that this sub-user is added to.

3. Output Parameters

Parameter name Type Description
RequestId String The ID of the request. Each request returns a unique ID. The RequestId is required to troubleshoot issues.

4. Sample

Sample 1. Adding a User to a User Group

Input Sample Code

https://cam.tencentcloudapi.com/?Action=AddUserToGroup
&Info.0.Uid=1001408
&Info.0.GroupId=2020
&<Common request parameter>

Output Sample Code

{
  "Response": {
    "RequestId": "47c4a570-17fa-44a3-8ff6-fe006170c104"
  }
}

5. Developer Resources

API Explorer

This tool provides various capabilities such as online call, signature verification, SDK code generation, and quick API retrieval that significantly reduce the difficulty of using TencentCloud API.

SDK

TencentCloud API 3.0 integrates software development toolkits (SDKs) that support various programming languages to make it easier for you to call the APIs.

TCCLI

6. Error Codes

The following error codes are API business logic-related. For other error codes, see Common Error Codes.

Error Code Description
InvalidParameter.GroupNotExist The user group does not exist.
InvalidParameter.GroupUserFull The number of sub-users in the user group has reached the upper limit.
InvalidParameter.UserGroupFull The number of user groups to which the sub-user is added has reached the upper limit.
ResourceNotFound.UserNotExist The user does not exist.