---
title: "Delete mailbox folder"
method: DELETE
path: "/mailboxes/{id}/folders/{folder_id}"
tags: ["Mailboxes"]
---

# Delete mailbox folder

`DELETE /mailboxes/{id}/folders/{folder_id}`

## Request

- Base URL: `https://shipmail.to/api/v1`
- URL: `https://shipmail.to/api/v1/mailboxes/{id}/folders/{folder_id}`
- Auth: one of:
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://shipmail.to/api/auth/oauth2/authorize`, token URL `https://shipmail.to/api/auth/oauth2/token`)

Delete a custom mailbox folder and its subfolders after moving their messages to Trash. Folders referenced by rules must be removed from rules first.

## Headers

- `X-Shipmail-Organization` string

## Response `204`

Mailbox folder deleted.

## Other responses

- `401`: Authentication failed.
- `403`: Insufficient permissions.
- `404`: Resource not found.
- `409`: Resource conflict.
- `422`: Validation failed.
- `429`: Rate limit exceeded.

---

[API](https://skmtc.dev/shipmail/apis/shipmail-api.md) · [All operations](https://skmtc.dev/shipmail/apis/shipmail-api/llms.txt) · [OpenAPI document](https://skmtc.dev/shipmail/apis/shipmail-api/revisions/2c23e59d7e30?raw)
