Users > User team roles

The following endpoints update and retrieve data about user team roles of a user in a team. Check out the overview of user team roles and the associated permissions.

List user roles

get

Gets team roles of the user with the specified userId. The response contains user's team role ID for all teams the user is part of. Get the mapping of the userRoleId and the user role name with the API call GET /users/roles.

Authorizations
Path parameters
userIdstringRequired

The ID of the user.

Example: 111
Responses
200
Successful response
application/json
get
GET /api/v2/users/{userId}/user-team-roles HTTP/1.1
Host: eu1.make.com
Authorization: YOUR_API_KEY
Accept: */*
200

Successful response

{
  "userTeamRoles": [
    {
      "usersRoleId": 3,
      "userId": 13,
      "teamId": 1,
      "changeable": true
    },
    {
      "usersRoleId": 1,
      "userId": 13,
      "teamId": 21,
      "changeable": true
    }
  ]
}

Get user team role detail

get

Gets user role detail in the team with the specified teamId. Get the mapping of the userRoleId and the user role name with the API call GET /users/roles.

Authorizations
Path parameters
userIdstringRequired

The ID of the user.

Example: 111
teamIdstringRequired

The ID of the team.

Example: 22
Responses
200
Successful response
application/json
get
GET /api/v2/users/{userId}/user-team-roles/{teamId} HTTP/1.1
Host: eu1.make.com
Authorization: YOUR_API_KEY
Accept: */*
200

Successful response

{
  "userTeamRole": {
    "usersRoleId": 3,
    "userId": 13,
    "teamId": 1,
    "changeable": true
  }
}

Update user role

post

Updates the user role in the team with the specified teamId. Get the mapping of the userRoleId and the user role name with the API call GET /users/roles.

Authorizations
Path parameters
userIdintegerRequired

The ID of the user.

Example: 111
teamIdintegerRequired

The ID of the team.

Example: 22
Body
usersRoleIdintegerOptional

The ID of the user role. Check the GET /users/roles API call for the available usersRoleId values.

Responses
200
Successful response
application/json
post
POST /api/v2/users/{userId}/user-team-roles/{teamId} HTTP/1.1
Host: eu1.make.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 17

{
  "usersRoleId": 3
}
200

Successful response

{
  "userTeamRole": {
    "usersRoleId": 3,
    "userId": 13,
    "teamId": 1,
    "changeable": true
  }
}