- API >
- Public API Resources >
- Organizations and Teams >
- Teams >
- Update Team Roles in One Project
Update Team Roles in One Project¶
On this page
Note
Groups and projects are synonymous terms. Your {PROJECT-ID}
is the
same as your project id. For existing groups, your group/project id
remains the same. This page uses the more familiar term group when
referring to descriptions. The endpoint remains as stated in the
document.
Base URL: https://cloud.mongodb.com/api/public/v1.0
Syntax¶
Request Path Parameters¶
Path Parameter | Type | Necessity | Description |
---|---|---|---|
PROJECT-ID |
string | Required | Unique identifier of the project associated with this team. |
TEAM-ID |
string | Required | Unique identifier of the team for which you want to update roles. |
Request Query Parameters¶
Query Parameter | Type | Necessity | Description |
---|---|---|---|
envelope |
boolean | Optional | Flag that specifies whether or not to wrap the response in an envelope. Defaults to |
pretty |
boolean | Optional | Flag that specifies whether or not to return a “pretty-printed” JSON document. Defaults to |
Request Body Parameters¶
Specify an array of strings, where each string represents one role you want to add to the team. You must specify an array even if you are only associating a single role to the team.
Body Parameter | Type | Necessity | Description |
---|---|---|---|
roleNames |
array | Required | Project roles you want to assign the given team. |
Response¶
Response Document¶
The response JSON document includes an array of result objects, an array of link objects and a count of the total number of result objects retrieved.
Name | Type | Description |
---|---|---|
results |
array | Array includes one object for each item detailed in the results Embedded Document section. |
links |
array | Array includes one or more links to sub-resources and/or related resources. The relations between URLs are explained in the Web Linking Specification. |
totalCount |
number | Integer count of the total number of items in the result set. It may be greater than the number of objects in the results array if the entire result set is paginated. |
results Embedded Document¶
Each element in the result
array is one set of roles specified for
one team.
Response Parameter | Type | Description |
---|---|---|
roleNames |
array | Project roles assigned to
the team for the specified teamsId . |
teamsId |
string | Unique identifier of the team assigned the listed roles. |