Add the power of the Box AI API to your custom apps at Content Cloud Summit on May 15

Learn more and register!

Update group membership


Updates a user's group membership. Only admins of this group or users with admin-level permissions will be able to use this API.



Path Parameters

stringin pathrequired

The ID of the group membership.

Query Parameters

string arrayin queryoptional

A comma-separated list of attributes to include in the response. This can be used to request fields that are not normally returned in a standard response.

Be aware that specifying this parameter will have the effect that none of the standard fields are returned in the response unless explicitly specified, instead only fields for the mini representation are returned, additional to the fields requested.

Request Body

associative arrayin body

Custom configuration for the permissions an admin if a group will receive. This option has no effect on members with a role of member.

Setting these permissions overwrites the default access levels of an admin.

Specifying a value of "null" for this object will disable all configurable permissions. Specifying permissions will set them accordingly, omitted permissions will be enabled by default.

booleanin bodyoptional

A key value pair of custom permissions.

stringin bodyoptional

The role of the user in the group.

Value is one of member,admin


application/jsonGroup membership

Returns a new group membership object.

application/jsonClient error

An unexpected client error.

Update group membership
You can now try out some of our APIs live, right here in the documentation.
Log in

Request Example

curl -i -X PUT "" \
     -H "authorization: Bearer <ACCESS_TOKEN>" \
     -H "content-type: application/json" \
     -d '{
       "role": "admin"
var updates = new BoxGroupMembershipRequest()
    Role = "admin"
BoxGroupMembership updatedMembership = await client.GroupsManager
    .UpdateGroupMembershipAsync("33333", updates);
BoxGroupMembership membership = new BoxGroupMembership(api, id);
BoxGroupMembership.Info info = Info();
membership_id = '1234'
membership_update = {'role': 'admin'}
updated_membership = client.group_membership(membership_id).update_info(data=membership_update)
print(f'Updated {}\'s group role to {updated_membership.role}')
// Promote a user to group admin
client.groups.updateMembership('12345', {role: client.groups.userRoles.ADMIN})
	.then(membership => {
		/* membership -> {
			type: 'group_membership',
			id: '33333',
			{ type: 'user',
				id: '22222',
				name: 'Alison Wonderland',
				login: '' },
			group: { type: 'group', id: '11111', name: 'Employees' },
			role: 'admin',
			{ can_run_reports: false,
				can_instant_login: false,
				can_create_accounts: false,
				can_edit_accounts: false },
			created_at: '2013-05-16T15:27:57-07:00',
			modified_at: '2013-05-16T15:27:57-07:00' }
client.groups.updateMembership(membershipId: "12345", role: .admin, configurablePermission: .value(ConfigurablePermissionData(canRunReports: true, canInstantLogin: true, canCreateAccounts: false, canEditAccounts: true))) { 
(result: Result<GroupMembership, BoxSDKError>) in
    guard case let .success(membership) = result else {
        print("Error updating group membership")

    print("Group membership with ID \( was updated")
TypeScript (Beta)
await client.memberships.updateGroupMembershipById(!, {
  role: 'admin' as UpdateGroupMembershipByIdRequestBodyRoleField,
} satisfies UpdateGroupMembershipByIdRequestBody);
Python (Beta)
client.memberships.update_group_membership_by_id(, role=UpdateGroupMembershipByIdRole.ADMIN.value)
.NET (Beta)
await client.Memberships.UpdateGroupMembershipByIdAsync(groupMembershipId: NullableUtils.Unwrap(groupMembership.Id), requestBody: new UpdateGroupMembershipByIdRequestBody(role: UpdateGroupMembershipByIdRequestBodyRoleField.Admin));

Response Example

  "id": "11446498",
  "type": "group_membership",
  "created_at": "2012-12-12T10:53:43-08:00",
  "group": {
    "id": "11446498",
    "type": "group",
    "group_type": "managed_group",
    "name": "Support"
  "modified_at": "2012-12-12T10:53:43-08:00",
  "role": "member",
  "user": {
    "id": "11446498",
    "type": "user",
    "login": "",
    "name": "Aaron Levie"