---
title: "Change the role of an existing team member of an organization. Only the organization owner or a delegated team member with the manageTeamMembers permission may call this; nobody may change their own role this way, not even a delegate who holds manageTeamMembers."
method: PATCH
path: "/v2/organizations/{organizationId}/team-members/{userId}"
tags: ["Organization Team Members Api Service"]
---

# Change the role of an existing team member of an organization. Only the organization owner or a delegated team member with the manageTeamMembers permission may call this; nobody may change their own role this way, not even a delegate who holds manageTeamMembers.

`PATCH /v2/organizations/{organizationId}/team-members/{userId}`

## Request

- Base URL: `https://app.metricool.com/api`
- URL: `https://app.metricool.com/api/v2/organizations/{organizationId}/team-members/{userId}`
- Auth: none declared

## Path parameters

- `organizationId` integer, required
- `userId` integer, required

## Request body

- UpdateOrganizationTeamMemberRequest: Request body to change the role of an existing team member of an organization.
  - `roleId` integer, required: Id of the new role to assign to this team member. Must belong to the organization owner.

## Response `200`

Role updated.

- JsonOkResponseOrganizationTeamMemberDto
  - `metadata` object
  - `page` JsonPaging
    - `next` string
  - `data` OrganizationTeamMemberDto: A team member of an organization.
    - `id` integer: Id of this team member row.
    - `userId` integer: Metricool user id of the team member.
    - `email` string: Email of the team member.
    - `fullName` string, nullable: First and last name of the team member's account, as collaborators carry it. Null when the account has no name: the front then shows the email.
    - `profilePicture` string, nullable: URL of the team member's profile picture. Null when they have none, and the front shows their initials instead.
    - `roleId` integer: Id of the role assigned to this team member.
    - `enabled` boolean: Whether this team member ROW (the organization membership) is currently active, not whether the underlying Metricool account is enabled. Always true: every read query already filters on enabled = 1, so a removed team member never shows up here with false instead.
    - `lastInvitationSent` DateTimeInfo
      - `dateTime` string, required: Local Date-time represented with a certain timezone
      - `timezone` string: Timezone applied to the datetime
    - `createdAt` DateTimeInfo
      - `dateTime` string, required: Local Date-time represented with a certain timezone
      - `timezone` string: Timezone applied to the datetime

## Other responses

- `400`: roleId is neither a system role nor one of the organization owner's own.
- `403`: Caller is not a regular-user session, the organization permissions feature is disabled for the organization's owner, the organization's owner's plan does not qualify for an organization, the caller cannot manage team members of this organization, or userId is the caller's own user id.
- `404`: Organization not found, its owner account could no longer be resolved, or userId is not a team member of it.

---

[API](https://skmtc.dev/metricool/apis/metricool-api.md) · [All operations](https://skmtc.dev/metricool/apis/metricool-api/llms.txt) · [OpenAPI document](https://skmtc.dev/metricool/apis/metricool-api/revisions/aea9d9a8415a?raw)
