Docs

Sub-accounts

Irisend-only: a parent team can create isolated sub-accounts with their own domains, quotas, and suspension state, one level deep. Full /accounts API reference.

POST/accountsCreate a sub-account

daily_email_limit/monthly_email_limit cap the sub-account's own sending, on top of the parent team's own caps. A sub-account can't create its own sub-accounts — one level only. external_id must be unique per parent team if provided.

curl -X POST https://api.irisend.com/accounts \
  -H "Authorization: Bearer $IRISEND_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Acme Merchant #182",
    "external_id": "cus_182",
    "daily_email_limit": 500
  }'
ResponseJSON
{
  "object": "account",
  "id": "7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df",
  "name": "Acme Merchant #182",
  "external_id": "cus_182",
  "status": "active",
  "parent_team_id": "a1b2c3d4-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
  "daily_email_limit": 500,
  "monthly_email_limit": null,
  "suspended_at": null,
  "suspended_reason": null,
  "created_at": "2026-09-25T09:00:12.481Z"
}
GET/accountsList sub-accounts

Optional ?external_id= filters to one sub-account by its external id.

curl https://api.irisend.com/accounts \
  -H "Authorization: Bearer $IRISEND_API_KEY"
GET/accounts/:idRetrieve a sub-account
curl https://api.irisend.com/accounts/7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df \
  -H "Authorization: Bearer $IRISEND_API_KEY"
PATCH/accounts/:idUpdate a sub-account

Pass null for either limit to clear it; omit a field to leave it untouched.

curl -X PATCH https://api.irisend.com/accounts/7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df \
  -H "Authorization: Bearer $IRISEND_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "daily_email_limit": 1000 }'
ResponseJSON
{ "object": "account", "id": "7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df" }
POST/accounts/:id/suspendSuspend a sub-account

A suspended sub-account's own API key stops working immediately, even mid-request.

curl -X POST https://api.irisend.com/accounts/7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df/suspend \
  -H "Authorization: Bearer $IRISEND_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "reason": "Chargeback investigation" }'
ResponseJSON
{ "object": "account", "id": "7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df", "status": "suspended" }
POST/accounts/:id/resumeResume a sub-account
curl -X POST https://api.irisend.com/accounts/7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df/resume \
  -H "Authorization: Bearer $IRISEND_API_KEY"
DELETE/accounts/:idDelete a sub-account

Deregisters every domain the sub-account owned from the provider, folds its usage into the parent team, then deletes it.

curl -X DELETE https://api.irisend.com/accounts/7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df \
  -H "Authorization: Bearer $IRISEND_API_KEY"
ResponseJSON
{ "object": "account", "id": "7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df", "deleted": true }
GET/accounts/:id/usageDaily sending usage

from/to are YYYY-MM-DD, defaulting to the trailing 30 days. Ordered ascending by day.

curl https://api.irisend.com/accounts/7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df/usage \
  -H "Authorization: Bearer $IRISEND_API_KEY"
ResponseJSON
{
  "object": "list",
  "has_more": false,
  "data": [
    { "day": "2026-09-24", "emails_sent": 182, "recipients": 190, "attachment_bytes": 0 },
    { "day": "2026-09-25", "emails_sent": 204, "recipients": 211, "attachment_bytes": 51200 }
  ]
}

Sending on a sub-account's behalf

Add an Irisend-Account header with the sub-account's id to any request made with the parent's own non-domain-restricted full_access key — every quota, domain, and suppression check then applies to the sub-account, not the parent. A sub-account's own key can never use this header to reach another account.

curl -X POST https://api.irisend.com/emails \
  -H "Authorization: Bearer $IRISEND_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Irisend-Account: 7a3dd4a5-03a6-4cc9-bac7-9a6f56f8d9df" \
  -d '{
    "from": "[email protected]",
    "to": "[email protected]",
    "subject": "Order confirmed",
    "html": "<p>Thanks!</p>"
  }'