Skip to main content
POST
Create an account

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-Device-Authorization
string

Compact ES256 JWS that the Digital Asset Accounts SDK creates on the end user's device. It signs this request's method, path, and exact body bytes with the authorization key the end user registered. The SDK creates a new value for every call. To retry a request, resend the original body and header unchanged when you can. Operations where a retry with a new header returns 409 (error code 420034) explain in that response how to find the original request.

Required when the request acts on a non-custodial account (custodyType self), and not used for other accounts. A missing value on a non-custodial request returns 400 (error code 420031). A value that isn't a well-formed compact JWS returns 401 (error code 420031) on any account.

The SDK gives each value an expiry at most 5 minutes after it signs it. Circle rejects a value whose expiry has passed or whose signing time is in the future, allowing 60 seconds of clock difference either way, with 400 (error code 420031). A device clock that's off by more than 60 seconds causes the same error. Retry within the value's lifetime, or let the SDK sign the request again.

Your backend relay must forward this header, and the request body, exactly as the SDK sent them. Don't parse, reformat, or re-serialize the body. If the bytes change, Circle rejects the request.

Compact ES256 JWS created by the Digital Asset Accounts SDK on the end user's device.

Required string length: 64 - 8192
Example:

"eyJhbGciOiJFUzI1NiJ9.e30.AAECAwQFBgcICQoLDA0ODxAREhMUFRYXGBkaGxwdHh8gISIjJCUmJygpKissLS4vMDEyMzQ1Njc4OTo7PD0-Pw"

Body

application/json

Create a Mint account

idempotencyKey
string<uuid>
required

Universally unique identifier (UUID v4) idempotency key. This key is utilized to ensure exactly-once execution of mutating requests.

Example:

"ba943ff1-ca16-49b2-ba55-1057e70ca5c7"

description
string
required

Human-readable description of the account.

Example:

"My account"

type
enum<string>
required

External account type.

  • first_party: the calling entity itself owns the account.
  • third_party: a sub-entity or end user owns the account.
Available options:
first_party,
third_party
Example:

"first_party"

purpose
enum<string>
required

Intended use of the account. Digital asset (Mint) accounts always hold stablecoin balances for the owning entity, so the only supported value is custody.

Available options:
custody
Example:

"custody"

clientEntityId
string<uuid>

Optional identifier of the client entity whose account should be created. If omitted, the account is owned by the caller and type must be first_party. If provided, the account is owned by a sub-entity and type must be third_party.

Example:

"a3f1b2c4-d5e6-7890-abcd-ef1234567890"

Response

Successfully created an account.

data
object

An account returned by the create account endpoint.