A command-line tool for managing Solana token accounts. Uses your local Solana CLI config for wallet and RPC settings.
bun install
Display your wallet's public key:
bun run index.ts address
Show token accounts sorted by USD value:
bun run index.ts balances [--limit <number>]
Options:
--limit, -l
: Number of accounts to display (default: 20, use 0 for all)
Send tokens to another wallet:
bun run index.ts transfer --mint <address> --to <address> --amount <number>
Options:
--mint, -m
: Token mint address--to, -t
: Destination wallet address--amount, -a
: Amount to transfer (use 'max' for full balance)
Transfer multiple token accounts to another wallet based on USD value:
bun run index.ts sweep --to <address> [--limit <number>]
Options:
--to, -t
: Destination wallet address--limit, -l
: Number of top token accounts to transfer (default: 5)
- Real-time token pricing via Jupiter API
- Automatic compute unit estimation
- Handles token account creation
- Reliable transaction confirmation with retries
- Support for max balance transfers
- USD value-based sorting and filtering
- Bun runtime
- Solana CLI config file (
~/.config/solana/cli/config.yml
) - Valid keypair file