I am trying to add a repo to a team on github, thus:
curl -i -u username:password -X PUT -d "" https://api.github.com/teams/:team/repos/:user/:repo
"The documents on github prescribe this:"
Add team repo
In order to add a repo to a team, the authenticated user must be an owner of the org that the team is associated with.
PUT /teams/:id/repos/:user/:repo
Does not work. What does work is this:
PUT /teams/:id/repos/:org/:repo
Replacing ":user" with ":org" (the name of the "organization" that the team belongs to.
For anyone coming across this again... it looks like :org is now the full name and not the ID
You also need to make sure that the :repo is the repo["name"]
field, NOT the repo["id"]
field.