You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
However, it is described in the parameter description that an array is expected. That's why you end up with the following error message if you follow the code sample:
{ "message": "Invalid request.\n\nFor 'links/9/schema', {\"teams\"=>[\"justice-league\"]} is not an array.", "documentation_url": "https://docs.github.com/rest/branches/branch-protection#add-team-access-restrictions" }
Thanks for opening this issue. A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines.
Thank you for opening this issue! Changes to the REST API schema can be requested in github/rest-api-description. I will transfer your issue over to that open source repo.
Code of Conduct
What article on docs.github.com is affected?
Add team access restrictions
What part(s) of the article would you like to see updated?
The code sample is not working.
Currently it suggests to add a JSON object
'{"teams":["justice-league"]}'
in the body of the HTTP Request:However, it is described in the parameter description that an array is expected. That's why you end up with the following error message if you follow the code sample:
The correct code sample would be:
Additional information
No response
The text was updated successfully, but these errors were encountered: