Organizations

Update a member's role (owner/admin)

Changed on

Sets a member's role and returns the updated membership. Custom roles need permissions enabled. Setting owner adds an owner, and only an owner can grant it.

Checked against the member.manage permission for the resource it acts on. See Permissions for the roles and API key permissions that include it.

patch/v1/orgs/{orgId}/members/{userId}

Request

  • Base URL
    https://api.openrelay.inc
  • URL
    https://api.openrelay.inc/v1/orgs/{orgId}/members/{userId}
  • Auth
    HTTP bearer

Path parameters

orgIdstring required
userIdstring required

Request body

role'owner' | 'admin' | 'member' | 'viewer' | 'billing' | 'inference'

A built-in role. billing and inference need permissions enabled. Only an owner grants owner.

roleIdstring

A custom role's id (role_...), for an organization with permissions enabled.

Response

Updated

avatarUrlstring
emailstring
fullNamestring
invitedAtstring
joinedAtstring
rolestring required
roleNamestring

The role's display name (permissions enabled only).

status'active' | 'invited'

Set only on the addOrgMember response, where it is "invited": the invite is recorded and emailed, and the user becomes a member only after accepting it. Listed and updated members omit it, and "active" is not returned.

userIdstring required

Changes

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the non-success response with the status