Users: RemoveUserFromRegion

Removes a user from a single region. You specify the region from which you want to remove the user in the designatedRegion request body.

The user still maintains their other region, company, and account associations.

Permissions

You must 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) from a region or office.
  • 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) from a region or office.

Note: You cannot remove a user from the region that contains their default office. You must first change the user's default office by using the Users::UpdateUser method.

Request

HTTP request

POST /v2/accounts/{accountId}/users/{userId}/remove_from_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 removed from the region.

400

Bad request. See ErrorCode and Message for details

ApiError
401

Not authorized to make this request.

ApiError

SDK Method

Users::RemoveUserFromRegion

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.

}} />