v51

latestOpenAPI 3.1.0raw.githubusercontent.com2026-08-01960201.2 KB
Mailboxes

Create mailbox

You may create your own mailbox using this action. It takes a JSON object containing a domain informations.

post/api/v1/add/mailbox

Request body

activeboolean

is mailbox active or not

domainstring

domain name

local_partstring

left part of email address

namestring

Full name of the mailbox user

authsource'mailcow' | 'ldap' | 'keycloak' | 'generic-oidc'

Specifies the authentication source for the mailbox.

password2string

mailbox password for confirmation

passwordstring

mailbox password when using mailcow as the authentication source.

quotanumber

mailbox quota

force_pw_updateboolean

forces the user to update its password on first login

force_tfaboolean

force 2FA enrollment at login

tls_enforce_inboolean

force inbound email tls encryption

tls_enforce_outboolean

force oubound tmail tls encryption

Example request

{
  "active": "1",
  "domain": "domain.tld",
  "local_part": "info",
  "name": "Full name",
  "authsource": "mailcow",
  "password": "atedismonsin",
  "password2": "atedismonsin",
  "quota": "3072",
  "force_pw_update": "1",
  "force_tfa": "1",
  "tls_enforce_in": "1",
  "tls_enforce_out": "1",
  "tags": [
    "tag1",
    "tag2"
  ]
}

Response

OK

type'success' | 'danger' | 'error'