Update an Organization Member's Roles

PUT /api/0/organizations/{organization_id_or_slug}/members/{member_id}/

Update a member's organization and team-level roles.

Path Parameters

organization_id_or_slug (string)
REQUIRED

The id or slug of the organization the resource belongs to.

member_id (string)
REQUIRED

The ID of the member to update.

Body Parameters

orgRole (string)

The organization role of the member. The options are:

  • billing - Can manage payment and compliance details.
  • member - Can view and act on events, as well as view most other data within the organization.
  • manager - Has full management access to all teams and projects. Can also manage the organization's membership.
  • owner - Has unrestricted access to the organization, its data, and its settings. Can add, modify, and delete projects and members, as well as make billing and plan changes.
  • admin - Can edit global integrations, manage projects, and add/remove teams. They automatically assume the Team Admin role for teams they join. Note: This role can no longer be assigned in Business and Enterprise plans. Use TeamRoles instead.
teamRoles (array(object))

Configures the team role of the member. The two roles are:

  • contributor - Can view and act on issues. Depending on organization settings, they can also add team members.
  • admin - Has full management access to their team's membership and projects.
Copied
{
    "teamRoles": [
        {
            "teamSlug": "ancient-gabelers",
            "role": "admin"
        },
        {
            "teamSlug": "powerful-abolitionist",
            "role": "contributor"
        }
    ]
}

Scopes

<auth_token> requires one of the following scopes:
  • member:admin
  • member:write
curl https://sentry.io/api/0/organizations/{organization_id_or_slug}/members/{member_id}/ \
 -H 'Authorization: Bearer <auth_token>' \
 -X PUT \
 -H 'Content-Type: application/json' \
 -d '{}'
RESPONSESCHEMA
{
  "id": "57377908164",
  "email": "sirpenguin@antarcticarocks.com",
  "name": "Sir Penguin",
  "user": {
    "id": "280094367316",
    "name": "Sir Penguin",
    "username": "sirpenguin@antarcticarocks.com",
    "email": "sirpenguin@antarcticarocks.com",
    "avatarUrl": "https://secure.gravatar.com/avatar/16aeb26c5fdba335c7078e9e9ddb5149?s=32&d=mm",
    "isActive": true,
    "hasPasswordAuth": true,
    "isManaged": false,
    "dateJoined": "2021-07-06T21:13:58.375239Z",
    "lastLogin": "2021-08-02T18:25:00.051182Z",
    "has2fa": false,
    "lastActive": "2021-08-02T21:32:18.836829Z",
    "isSuperuser": false,
    "isStaff": false,
    "experiments": {},
    "emails": [
      {
        "id": "2153450836",
        "email": "sirpenguin@antarcticarocks.com",
        "is_verified": true
      }
    ],
    "avatar": {
      "avatarType": "letter_avatar",
      "avatarUuid": null
    },
    "authenticators": [],
    "canReset2fa": true
  },
  "role": "member",
  "orgRole": "member",
  "roleName": "Member",
  "pending": false,
  "expired": false,
  "flags": {
    "idp:provisioned": false,
    "idp:role-restricted": false,
    "sso:linked": false,
    "sso:invalid": false,
    "member-limit:restricted": false,
    "partnership:restricted": false
  },
  "dateCreated": "2021-07-06T21:13:01.120263Z",
  "inviteStatus": "approved",
  "inviterName": "maininviter@antarcticarocks.com",
  "teams": [
    "cool-team",
    "ancient-gabelers"
  ],
  "teamRoles": [
    {
      "teamSlug": "ancient-gabelers",
      "role": "admin"
    },
    {
      "teamSlug": "powerful-abolitionist",
      "role": "contributor"
    }
  ],
  "invite_link": null,
  "isOnlyOwner": false,
  "orgRoleList": [
    {
      "id": "billing",
      "name": "Billing",
      "desc": "Can manage subscription and billing details.",
      "scopes": [
        "org:billing"
      ],
      "allowed": true,
      "isAllowed": true,
      "isRetired": false,
      "is_global": false,
      "isGlobal": false,
      "minimumTeamRole": "contributor"
    },
    {
      "id": "member",
      "name": "Member",
      "desc": "Members can view and act on events, as well as view most other data within the organization.",
      "scopes": [
        "team:read",
        "project:releases",
        "org:read",
        "event:read",
        "alerts:write",
        "member:read",
        "alerts:read",
        "event:admin",
        "project:read",
        "event:write"
      ],
      "allowed": true,
      "isAllowed": true,
      "isRetired": false,
      "is_global": false,
      "isGlobal": false,
      "minimumTeamRole": "contributor"
    },
    {
      "id": "admin",
      "name": "Admin",
      "desc": "Admin privileges on any teams of which they're a member. They can create new teams and projects, as well as remove teams and projects on which they already hold membership (or all teams, if open membership is enabled). Additionally, they can manage memberships of teams that they are members of. They cannot invite members to the organization.",
      "scopes": [
        "team:admin",
        "org:integrations",
        "project:admin",
        "team:read",
        "project:releases",
        "org:read",
        "team:write",
        "event:read",
        "alerts:write",
        "member:read",
        "alerts:read",
        "event:admin",
        "project:read",
        "event:write",
        "project:write"
      ],
      "allowed": true,
      "isAllowed": true,
      "isRetired": true,
      "is_global": false,
      "isGlobal": false,
      "minimumTeamRole": "admin"
    },
    {
      "id": "manager",
      "name": "Manager",
      "desc": "Gains admin access on all teams as well as the ability to add and remove members.",
      "scopes": [
        "team:admin",
        "org:integrations",
        "project:releases",
        "team:write",
        "member:read",
        "org:write",
        "project:write",
        "project:admin",
        "team:read",
        "org:read",
        "event:read",
        "member:write",
        "alerts:write",
        "alerts:read",
        "event:admin",
        "project:read",
        "event:write",
        "member:admin"
      ],
      "allowed": true,
      "isAllowed": true,
      "isRetired": false,
      "is_global": true,
      "isGlobal": true,
      "minimumTeamRole": "admin"
    },
    {
      "id": "owner",
      "name": "Owner",
      "desc": "Unrestricted access to the organization, its data, and its settings. Can add, modify, and delete projects and members, as well as make billing and plan changes.",
      "scopes": [
        "team:admin",
        "org:integrations",
        "project:releases",
        "org:admin",
        "team:write",
        "member:read",
        "org:write",
        "project:write",
        "project:admin",
        "team:read",
        "org:read",
        "event:read",
        "member:write",
        "alerts:write",
        "org:billing",
        "alerts:read",
        "event:admin",
        "project:read",
        "event:write",
        "member:admin"
      ],
      "allowed": true,
      "isAllowed": true,
      "isRetired": false,
      "is_global": true,
      "isGlobal": true,
      "minimumTeamRole": "admin"
    }
  ],
  "teamRoleList": [
    {
      "id": "contributor",
      "name": "Contributor",
      "desc": "Contributors can view and act on events, as well as view most other data within the team's projects.",
      "scopes": [
        "team:read",
        "project:releases",
        "org:read",
        "event:read",
        "member:read",
        "alerts:read",
        "project:read",
        "event:write"
      ],
      "allowed": false,
      "isAllowed": false,
      "isRetired": false,
      "isMinimumRoleFor": null
    },
    {
      "id": "admin",
      "name": "Team Admin",
      "desc": "Admin privileges on the team. They can create and remove projects, and can manage the team's memberships. They cannot invite members to the organization.",
      "scopes": [
        "team:admin",
        "org:integrations",
        "project:admin",
        "team:read",
        "project:releases",
        "org:read",
        "team:write",
        "event:read",
        "alerts:write",
        "member:read",
        "alerts:read",
        "event:admin",
        "project:read",
        "event:write",
        "project:write"
      ],
      "allowed": false,
      "isAllowed": false,
      "isRetired": false,
      "isMinimumRoleFor": "admin"
    }
  ]
}