mail

GET /v1/mail/allowance

What the caller's plan grants for mailboxes.

所有 mail 端点

身份验证

请将 API 密钥作为 bearer 令牌发送。该密钥必须具有 mail.view 权限;缺少该权限的密钥将被拒绝并返回 403 状态码,而非 404。

您的组织 ID 应填在此处

此端点将 org_id 作为查询参数。不填则调用涵盖您的整个租户子树;发送该参数则将调用范围缩小到一个组织。

您的组织ID位于控制面板的API密钥屏幕上,就在密钥本身的旁边。这是您在每次调用时使用的相同ID。

免费试用

将尖括号中的内容替换为您自己的值,并将键占位符替换为您仪表板中的一个键。

curl -X GET https://api.zinndigital.com/v1/mail/allowance \
  -H "Authorization: Bearer zdk_live_…"

已登录?您仪表板中的 API 控制台会自动填入您真实的组织 ID 和您自己的密钥,并针对实时 API 运行请求,以便您查看实际的响应。 在 API 控制台中打开此端点

详细信息

The preflight the "set up email" screen reads: whether the governing plan includes mailboxes, how large each one is, and how many a domain may have. **Reports rather than refuses** — an organization with no plan gets `included: false` and an upgrade prompt, not an error, because this is a read screen. Resolution walks **up** the `parent_org` chain, so a reseller's client organization inherits the reseller's plan (CLAUDE.md §2.3). `source` names where the answer came from. `mailbox_limit` is the **smaller of the plan's `mailboxes` grant and the platform abuse ceiling**, so it does vary by plan; `-1` means both are uncapped. Requires `mail.view`. ⭐ **Pass `fqdn` whenever the question is about one domain, which is nearly always.** Since the owner's ruling of 2026-08-16 a domain registered with us — or transferred in — grants free mailboxes **on itself**, whatever the organization's hosting plan says, and that grant is only reachable when the hostname is supplied. Without `fqdn` this endpoint answers the narrower question "does anything the organization owns include mail at all", and a customer whose only product is a domain gets `included: false` followed by a successful mailbox creation — a screen disagreeing with its own API.

参数

名称类型必填内容简介
org_id (query)UuidThe organization to resolve for; defaults to the caller's own when unambiguous.
fqdn (query)stringResolve for this hostname. Adds the `domain` source — free mailboxes on a domain we hold the registration for.

响应

名称类型必填内容简介
offered_providersMailProvider[]The providers this organization may set a domain up on, in picker order — **the one producer of the white-label rule** (W40-MAIL). `zinn` is absent, not disabled, for an organiz…
includedbooleanWhether the plan includes mailboxes at an operable size.
box_quota_mbintegerPer-mailbox size in MB. `0` means no per-mailbox cap.
mailbox_limitintegerMailboxes allowed per domain; `-1` is uncapped. The **smaller** of the plan's `mailboxes` grant and the platform abuse ceiling: a plan may lower it, and a generous plan can neve…
sourcestring<staff, subscription, trial, domain, none>Where the allowance came from. `domain` means **the domain itself grants it** — it is registered with us or was transferred in, so its mailboxes are free whatever the organizati…

此端点可能返回的错误

401 · 403 · 422 · 429