[DOCS-13144] [Atlas] "Add Teams to Project" API Endpoint Correction Created: 21/Oct/19  Updated: 29/Oct/23  Resolved: 30/Dec/19

Status: Closed
Project: Documentation
Component/s: Atlas
Affects Version/s: None
Fix Version/s: None

Type: Doc API Priority: Major - P3
Reporter: Falk Oertel Assignee: Jonathan DeStefano
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:
Days since reply: 4 years, 6 weeks, 2 days ago

 Description   

Description

https://docs.atlas.mongodb.com/reference/api/project-add-team/

Currently, the Add Teams to a Project section of the Atlas API documentation states that the request body should include a roles parameter that is an object array:

[ { "teamId" : "

{TEAM-ID}", "roles" : [ { "roleName" : "GROUP_OWNER" } ] } ]

but correct would be:

[ { "teamId" : "{TEAM-ID}

", "roles" : [ "roleName" : "GROUP_OWNER" ] } ]

 

seems to be a regression to:

https://jira.mongodb.org/browse/DOCS-11720

Scope of changes

Impact to Other Docs

MVP (Work and Date)

Resources (Scope or Design Docs, Invision, etc.)



 Comments   
Comment by Jonathan DeStefano [ 30/Dec/19 ]

Hi Falk,

Thanks for filing this DOCS ticket. After some investigation, the request body accepts a roleNames parameter which accepts an array of strings, not an array of objects as the API doc originally suggested. There is also no accepted roles parameter. The request body should resemble the following:

[
  {
    "teamId": "{TEAM-ID}",
    "roleNames": [ "GROUP_OWNER" ]
  }
]

The documentation was updated to reflect the above:
https://docs.atlas.mongodb.com/reference/api/project-add-team/

Feel free to leave a comment or re-open if you have any other feedback. Thanks again for the feedback.

Cheers,
Jon DeStefano
MongoDB Docs Team

Generated at Thu Feb 08 08:07:04 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.