Function: addUserToGroup()
ts
function addUserToGroup(
client,
parameters,
options?
): Promise<{
[key: string]: unknown;
expand?: string;
groupId?: string | null;
name?: string;
self?: string;
users?: {
[key: string]: unknown;
end-index?: number;
items?: object[];
max-results?: number;
size?: number;
start-index?: number;
};
}>;Defined in: src/cloud/api/groups.ts:95
Adds a user to a group.
Permissions required: Site administration (that is, member of the site-admin group).
Parameters
| Parameter | Type | Description |
|---|---|---|
client | Client | - |
parameters | { accountId?: string; groupId?: string; groupname?: string; } | - |
parameters.accountId? | string | The account ID of the user, which uniquely identifies the user across all Atlassian products. For example, 5b10ac8d82e05b22cc7d4ef5. |
parameters.groupId? | string | The ID of the group. This parameter cannot be used with the groupName parameter. |
parameters.groupname? | string | As a group's name can change, use of groupId is recommended to identify a group. The name of the group. This parameter cannot be used with the groupId parameter. |
options? | RequestOptions | - |
Returns
Promise<{ [key: string]: unknown; expand?: string; groupId?: string | null; name?: string; self?: string; users?: { [key: string]: unknown; end-index?: number; items?: object[]; max-results?: number; size?: number; start-index?: number; }; }>