Skip to main content
Both methods create an Associated Token Account (ATA) — the standard account type that holds tokens for a wallet. Choose the method matching your mint’s token program.
These methods return instruction lists. Add them to a transaction and use the Transaction Service to compile, sign, and submit. See Instructions & Transactions.

CreateToken2022HoldingAccount

Creates a Token-2022 Associated Token Account with optional extensions. Returns the ATA creation instruction plus reallocate and extension-init instructions for each requested extension.

Request

Base58-encoded public key (string)
required
Pays for ATA creation. Must be a signer.
Base58-encoded public key (string)
required
The wallet that will own this token account.
Base58-encoded public key (string)
required
The Token-2022 mint this account will hold tokens for.
Token2022HoldingAccountExtension[] (repeated)
Optional. Extensions to enable on the ATA. Currently supported: MemoTransfer (requires a memo on all incoming transfers).

Response

SolanaInstruction[] (repeated)
required
Ordered instructions. Includes ATA creation plus reallocate and init for each extension.
uint64
Rent-exempt minimum for the final account size including all extensions.

Code Examples


CreateSPLTokenHoldingAccount

Creates a legacy SPL Token Associated Token Account. Returns a single ATA creation instruction.

Request

Base58-encoded public key (string)
required
Pays for ATA creation. Must be a signer.
Base58-encoded public key (string)
required
The wallet that will own this token account.
Base58-encoded public key (string)
required
The SPL Token mint this account will hold tokens for.

Response

SolanaInstruction[] (repeated)
required
A single ATA creation instruction.
uint64
Rent-exempt minimum for the ATA.

Code Examples