Rename a folder
PUT/api/accounts/:accountId/folders/:folder
Renames the folder with IMAP RENAME, keeping it under the same parent: newName replaces only the last segment of the path, and the folder's messages and subfolders move with it.
The server does not check capabilities; renaming a special folder is left to the IMAP server, and a refusal returns 424.
Request
Responses
- 200
- 400
- 401
- 404
- 424
Renamed.
Request failed.
The session has no mailbox access token. code is mail_token_missing; sign in again.
The account or the folder does not exist.
The IMAP, SMTP or Sieve server, or the platform, refused the request or could not be reached.