Skip to main content

Overview

GLAM vaults maintain an asset allowlist that controls which tokens can be held in the vault. This guide covers how to manage this allowlist, check token balances, and perform essential asset operations.

Asset Allowlist

The asset allowlist is a list of token mint addresses that the vault is permitted to hold. Only assets in this allowlist can be traded or deposited.

Listing Current Assets

View all assets in the vault’s allowlist along with their token accounts:
glam vault list-assets
Example output:
[
  {
    "assetMint": "So11111111111111111111111111111111111111112",
    "decimals": 9,
    "tokenAccount": "5mQ2...3nLw",
    "tokenProgram": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
  },
  {
    "assetMint": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
    "decimals": 6,
    "tokenAccount": "7xR3...2kPm",
    "tokenProgram": "TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA"
  }
]

Adding Assets to Allowlist

Add a new token to the vault’s allowlist:
glam vault allowlist-asset <mint-address>
Example:
# Add USDC to allowlist
glam vault allowlist-asset EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v
With confirmation skip:
glam vault allowlist-asset EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v -y
Assets cannot be added if they’re already in the allowlist. The command will fail with an error message.

Removing Assets from Allowlist

Remove a token from the vault’s allowlist:
glam vault remove-asset <mint-address>
Example:
glam vault remove-asset EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v
  • You cannot remove the base asset (the primary deposit asset) from the allowlist
  • The command will fail if the asset is not currently in the allowlist

Token Balances

View current token holdings in your vault:
glam vault token-balances
Example output:
┌──────────┬────────────────────────────────────────────────┬──────────────┬──────────────┐
│ Token    │ Mint                                           │ Amount       │ Value (USD)  │
├──────────┼────────────────────────────────────────────────┼──────────────┼──────────────┤
│ SOL      │ N/A                                            │ 10.500000000 │ 2100.000000  │
│ wSOL     │ So11111111111111111111111111111111111111112    │ 5.250000000  │ 1050.000000  │
│ USDC     │ EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v  │ 1000.00      │ 1000.000000  │
└──────────┴────────────────────────────────────────────────┴──────────────┴──────────────┘

Show All Assets

Include token accounts with zero balance:
glam vault token-balances --all

JSON Output

Get balances in JSON format for programmatic use:
glam vault token-balances --json
Output:
[
  {
    "token": "SOL",
    "mint": "N/A",
    "amount": 10.5,
    "value": 2100
  },
  {
    "token": "USDC",
    "mint": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
    "amount": 1000,
    "value": 1000
  }
]
Token prices are fetched from Jupiter API. USD values may show “NaN” for tokens without price data.

Wrapping and Unwrapping SOL

SOL needs to be wrapped into wSOL (wrapped SOL) for certain DeFi operations.

Wrap SOL

Convert SOL to wSOL in the vault:
glam vault wrap <amount>
Example:
# Wrap 5 SOL
glam vault wrap 5
Terminal output:
Confirm wrapping 5 SOL? (y/n): y
Wrapped 5 SOL: 2Tx9...4kPq
Wrapping SOL is often required before executing swaps or providing liquidity in DeFi protocols.

Unwrap wSOL

Convert all wSOL back to SOL:
glam vault unwrap
Terminal output:
Confirm unwrapping all wSOL? (y/n): y
wSOL unwrapped: 3Yz8...5mNq
The unwrap command unwraps all wSOL in the vault. You cannot specify a partial amount.

Managing Token Accounts

Token accounts consume rent on Solana. You can close empty token accounts to reclaim rent.

Close Specific Token Accounts

Close token accounts for specific mints:
glam vault close-token-accounts <mint1> <mint2> ...
Example:
glam vault close-token-accounts EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v

Close All Empty Token Accounts

Automatically close all token accounts with zero balance:
glam vault close-token-accounts --empty
Terminal output:
Confirm closing 3 token account(s)? (y/n): y
Closed 3 token account(s): 4Bx7...6pQr
Closing unused token accounts reclaims rent (approximately 0.00203928 SOL per account).

Vault Holdings

Get a comprehensive view of all vault holdings including positions in DeFi protocols:
glam vault holdings
This command returns detailed information about:
  • Token balances
  • Staked positions
  • Liquidity pool positions
  • Lending/borrowing positions
  • Total vault value

Common Workflows

Setting Up a New Trading Vault

1

Create vault with base asset

glam vault create my-vault.json
2

Add trading assets to allowlist

glam vault allowlist-asset EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v  # USDC
glam vault allowlist-asset Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB  # USDT
3

Verify allowlist

glam vault list-assets
4

Check initial balances

glam vault token-balances

Preparing for DeFi Operations

1

Wrap SOL for trading

glam vault wrap 10
2

Verify wrapped balance

glam vault token-balances
3

Execute DeFi operations

Use integration commands (Jupiter swap, Kamino deposit, etc.)
4

Unwrap unused wSOL

glam vault unwrap

Cleanup Unused Token Accounts

1

Check current balances

glam vault token-balances --all
2

Close empty accounts

glam vault close-token-accounts --empty -y
3

Verify accounts closed

glam vault list-assets

Command Reference

CommandDescriptionOptions
list-assetsList vault asset allowlistNone
allowlist-asset <mint>Add asset to allowlist-y skip confirmation
remove-asset <mint>Remove asset from allowlist-y skip confirmation
token-balancesShow token balances-a, --all include zero balances
-j, --json JSON output
wrap <amount>Wrap SOL to wSOL-y skip confirmation
unwrapUnwrap all wSOL to SOL-y skip confirmation
close-token-accounts [mints...]Close token accounts--empty close all empty accounts
-y skip confirmation
holdingsGet all vault holdingsNone

Next Steps

Delegate Permissions

Grant delegates permission to manage vault assets

Jupiter Commands

Execute token swaps using Jupiter

Kamino Commands

Deposit assets into Kamino vaults

Build docs developers (and LLMs) love