delete_mailbox
Remove a mailbox (soft delete). Required: mailbox_id. By DEFAULT the already-fetched mails are KEPT and stay readable via list_emails/get_email — they belong to the tenant, not to the connection they arrived through; their triage state and links to leads and drafts stay. The mailbox is marked removed and no longer syncs or appears in list_mailboxes. The answer reports kept_emails. Pass delete_emails=true to ALSO delete every already-fetched mail of this mailbox (irreversible) — only then is anything deleted. Refuses while the mailbox is the default sender unless force=true, because removing it silently sends the next unmatched mail through the shared address.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"mailbox_id": "<mailbox_id>"
},
"name": "delete_mailbox"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | Remove even if the mailbox is the default sender | |
| mailbox_id | Yes | ID of the mailbox to delete | |
| delete_emails | No | Also delete all fetched mails of this mailbox (irreversible) |