Replace the teams a file is shared with
PUT/v1/files/:fileId/teams
Requires the Teams.ShareFiles scope and, as in the web portal, sharing rights on the file
(file owner, a manager of a team the file is shared with, or an org admin).
The list replaces the current teams: teams not in the list are removed and new teams are added.
Send "teamIds": [] to stop sharing the file with any team. Every team must be an active
team of the caller's organization (see GET /v1/teams).
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 429
- 500
- 503
File teams updated
Validation failed, or a team is not an active team of the organization
Unauthorized
The sender cannot change the sharing of this file, or the token lacks Teams.ShareFiles
The file does not exist in the caller's organization
The file is archived and read-only
Too Many Requests
Internal Server Error
Service Unavailable