curl -X POST "https://mail.example.com/api/v1/edit/mailbox" -H "X-API-Key: $MAILCOW_API_KEY" -H "Content-Type: application/json" -d '{"attr":"active","items":["jane@example.com"]}'

Category: Mail Servers & Postfix

curl -X POST "https://mail.example.com/api/v1/edit/mailbox" -H "X-API-Key: $MAILCOW_API_KEY" -H "Content-Type: application/json" -d '{"attr":"active","items":["jane@example.com"]}'

Toggle a mailbox attribute via the API

The attr field selects which mailbox property to change, here active, applied to every address in items. Setting active disables login and delivery while keeping the maildir intact. Other attrs such as password or quota follow the same pattern.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.