This guide helps you get test tokens for trading on the DEX.
- Connect your wallet to the app and copy your wallet address
- Run the airdrop script:
cd scripts
npx ts-node airdrop-tokens.ts <YOUR_WALLET_ADDRESS>- Copy the commands shown in the output and run them in your terminal
- Base Token (9 decimals):
DeRQ3edcNvwH8XjEVtFiqLN8uiABcojbyjxhcE5LLj8x - Quote Token (6 decimals):
D3VykNoT3ne9Rkn6tSy7ssGvhSq3NGN7mWtqQss4jADM
# Create account for Base token
spl-token create-account DeRQ3edcNvwH8XjEVtFiqLN8uiABcojbyjxhcE5LLj8x
# Create account for Quote token
spl-token create-account D3VykNoT3ne9Rkn6tSy7ssGvhSq3NGN7mWtqQss4jADMNote: You need to be the mint authority to mint tokens. If you're not the mint authority, contact the market creator.
# Mint 1000 Base tokens (9 decimals)
spl-token mint DeRQ3edcNvwH8XjEVtFiqLN8uiABcojbyjxhcE5LLj8x 1000
# Mint 10000 Quote tokens (6 decimals)
spl-token mint D3VykNoT3ne9Rkn6tSy7ssGvhSq3NGN7mWtqQss4jADM 10000# Check Base token balance
spl-token balance DeRQ3edcNvwH8XjEVtFiqLN8uiABcojbyjxhcE5LLj8x
# Check Quote token balance
spl-token balance D3VykNoT3ne9Rkn6tSy7ssGvhSq3NGN7mWtqQss4jADMIf you're demoing this to potential users or investors, here's the best UX flow:
- Create 2-3 demo wallet keypairs
- Fund them with test tokens ahead of time
- Import them into Phantom/Solflare for the demo
- Show smooth trading without setup friction
# Create demo wallet
solana-keygen new -o demo-wallet-1.json
# Airdrop SOL for transaction fees
solana airdrop 2 <DEMO_WALLET_ADDRESS> --url devnet
# Follow steps above to mint tokensFor a production-ready demo, consider building a simple faucet page:
// app/faucet/page.tsx
// Users click "Get Test Tokens" button
// Backend service with mint authority airdrops tokens
// Much better UX than manual CLI commands- Cause: You don't have enough tokens in your wallet
- Solution: Follow the airdrop steps above
- Cause: Token account (ATA) doesn't exist
- Solution: Run
spl-token create-account <MINT_ADDRESS>first
- Cause: You're not the mint authority
- Solution: Contact the market creator or use a different wallet
- Solution: Click the refresh button or wait 5-10 seconds for the UI to update
For a professional demo or mainnet deployment:
- Build a faucet service - Backend API that airdrops small amounts
- Welcome modal - Detect new users and offer auto-airdrop
- Better error messages - Show "Get Tokens" button instead of raw errors
- Demo mode - Allow users to try without connecting wallet
For issues or questions about getting test tokens, please open an issue on GitHub.