Skip to main content
POST
/
mailboxes
/
{public_id}
/
keys
Create a mailbox API key
curl --request POST \
  --url https://app.sendmux.ai/api/v1/mailboxes/{public_id}/keys \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "app_name": "<string>"
}
'
{
  "ok": true,
  "meta": {
    "request_id": "req_clxxxxxxxxxxxxxxxxxxxxxxxxx"
  },
  "data": {
    "credential": {
      "public_id": "smx_clxxxxxxxxxxxxxxxxxxxxxxxxx",
      "secret": "<string>",
      "key_prefix": "<string>",
      "key_suffix": "<string>",
      "server": "mail.sendmux.ai",
      "imap_port": 993,
      "smtp_port": 587,
      "username": "<string>"
    }
  }
}

Authorizations

Authorization
string
header
required

Sendmux API key. Use a root API key for Management API routes, or a mailbox credential for Mailbox API routes. Obtain keys from the dashboard under API Keys.

Headers

Idempotency-Key
string

Client-chosen unique key to safely retry the request. Cached for 24h per (team, endpoint, key). Different body with same key returns 409 idempotency_conflict.

Maximum string length: 255
Example:

"mailbox-keys-create-20260424-001"

Path Parameters

public_id
string
required

Mailbox public ID

Body

application/json
app_name
string
required
Required string length: 1 - 255

Response

Mailbox API key created. The response carries a Location header pointing at the canonical URL for the new key.

ok
enum<boolean>
required
Available options:
true
meta
object
required
data
object
required