Sub-Accounts

Create sub-account

Changed on

Create a new sub-account (project) with its own API key. All charges are billed to the parent team's balance. Use creditLimit to set a spending cap. The sub-account's API key is returned only in the creation response. Requires a parent project API key; sub-account API keys receive HTTP 403.

post/v1/sub-accounts

Request

  • Base URL
    https://api.zavu.dev
  • URL
    https://api.zavu.dev/v1/sub-accounts
  • Auth
    HTTP bearer

Request body

namestring required

Name of the sub-account.

externalIdstring

External reference ID for your own tracking.

creditLimitinteger

Spending cap in cents. When reached, messages from this sub-account will be blocked. Omit or set to 0 for no limit.

metadataobject

Example request

{
  "name": "Client ABC"
}

Response

Sub-account created.

Example response

{
  "subAccount": {
    "name": "Client ABC"
  }
}

Changes