Users: AddUserToRegion

Adds an existing user to a region. You specify the region to which you want to add the user in the designatedRegion request body.

To add a user to multiple regions, you must make this call separately for each region.

Note: The accessLevel of the user that you are adding must be region.

Permissions

You must also have the correct Member Management permissions.

Rooms Version 5: canManageCompanyMembers must be set to true.

Rooms Version 6: You must have at least one of the following permissions set to true, depending on the level of the user that you want to add or remove:

  • canManageMemberLowerAccessLevel: Users can add or remove other users who have a lower access level than their own (in offices or regions that they oversee).
  • canManageMemberSameAccessLevel: Users can modify other users who have the same access level as their own (in offices or regions that they oversee or belong to).

Request

HTTP request

POST /restapi/v2/accounts/{accountId}/users/{userId}/add_to_region

Parameters

Parameter NameValueDescription
Path Parameters
userIdinteger

(Required) The id of the user.

accountIdstring

(Required) The id of the account.

Request Body

designatedRegion

Responses

CodeDescriptionReference
204

User successfully added to the region.

400

Bad request. See ErrorCode and Message for details

ApiError
401

Not authorized to make this request.

ApiError

SDK Method

Users::AddUserToRegion

Definitions

ApiError

This object describes errors that occur. It is valid only for responses and ignored in requests.

errorCodestring

The code associated with the error condition.

messagestring

A brief message describing the error condition.

DesignatedRegion

This object contains information about the region associated with the member.

regionIdinteger

(Required) The id of the region. This is the id that the system generated when you created the region.

}} />