I've started getting seemingly random Bad Request and Forbidden responses from Graph. The overall execution of the code does the following:
1) Create a MS Teams Team be calling POST - https://graph.microsoft.com/v1.0/teams
2) Add guests to that Team
3) Create folders for all guests under the main channel
4) Remove all permissions from folders (aside from "owner" role) and re-add the appropriate guest as the manager of that folder
5) Create a meeting related to the created Team.
Everything was working fine until today.
1) I started getting Forbidden responses from POST - groups/{team-id}/events. This was fixed by tweaking the date format. But then
2) I started getting Bad Request or Forbidden responses from DELETE - groups/{team-id}/drive/items/{item-id}/permissions/{permission-id}
3) I also began getting Forbidden responses from POST teams/{team-id}/members
These errors are all random. Sometimes I'll get lucky and the request will go through with identical parameters. Error 3 appears to go away if I manually get a new OAuth token before trying the request.