For the complete documentation index, see llms.txt. This page is also available as Markdown.

Creating subaccount

POST /api/public/v1/accounts/:account_id/subaccounts

Creates a subaccount under the specified master account. The subaccount inherits the master account's currency.

Headers

Name
Value

Content-Type

application/vnd.api+json

Authorization

Bearer <api_key>

Path Parameters

Name
Type
Description

account_id

string

Master account ID.

Body

Name
Type
Description

data

object

Request data object.

data.type

string

Resource type. Always accounts.

data.attributes

object

Subaccount attributes.

data.attributes.label

string

Subaccount label. Use a human-readable value so you can recognize it later.

Request JSON

{
  "data": {
    "type": "accounts",
    "attributes": {
      "label": "Sub-account Adam Goodman"
    }
  }
}

Response

The master account in the path does not exist.

Response Body

Name
Type
Description

data.id

string

Subaccount ID.

data.type

string

Entity type returned. Always accounts.

data.attributes.master

boolean

Always false for a subaccount.

data.attributes.currencyCode

string

Currency code, inherited from the master account.

data.attributes.label

string

Subaccount label, as set in the request.

data.attributes.bankReference

string

Unique bank deposit reference assigned to the subaccount.

data.attributes.balance

string

Subaccount balance. A new subaccount starts at zero.

data.attributes.totalBalance

string

Matches balance for subaccounts.

data.attributes.bankWithdrawalAvailable

boolean

If true, bank withdrawals can be initiated from this account.

data.attributes.currencyType

string

Currency type. Either fiat or crypto.

Last updated