emblem-token-swap
emblemcompany/agent-skills
Swap and bridge crypto tokens across 6 blockchains with quote-then-confirm safety via EmblemAI.
What is emblem-token-swap?
This skill enables an AI agent to execute token swaps across Solana, Ethereum, Base, BSC, Polygon, and Hedera, plus cross-chain bridging via ChangeNow, using the EmblemAI agent wallet CLI. Use it when a user asks to swap tokens, exchange crypto, convert currencies, or bridge assets between chains.
- Provides quote and swap tools for Solana, Ethereum, Base, BSC, Polygon, and Hedera
- Performs automatic DEX route optimization on EVM chains
- Executes cross-chain bridging through ChangeNow supporting 500+ currencies
- Looks up token balances per chain (e.g. solanaBalances, ethGetBalances, hederaGetBalances)
- Searches/finds tokens by name, symbol, or contract address across chains
- Requires explicit user confirmation in safe mode before executing any value-moving swap
How to install emblem-token-swap
npx skills add https://github.com/emblemcompany/agent-skills --skill emblem-token-swap- Node.js >= 18.0.0
- @emblemvault/agentwallet CLI installed globally (npm install -g @emblemvault/agentwallet)
- Internet access
- An agent following the Agent Skills spec (e.g. Claude Code, Cursor, Codex, OpenClaw)
How to use emblem-token-swap
- 1.Install the required CLI: npm install -g @emblemvault/agentwallet
- 2.Check your source token balance (e.g. 'Use solanaBalances to show my Solana token balances')
- 3.Request a quote for the swap, specifying the tool name, amount, source token, and target token (e.g. 'Use splBuyIntent to get a quote for swapping 5 SOL to USDC')
- 4.Confirm and execute the swap when prompted by safe mode (e.g. 'Use splBuyIntent to swap 5 SOL for USDC on Solana')
- 5.Verify the updated balance after the swap completes
- 6.For cross-chain bridges, use getChangeNowSwapQuote for a quote and swapUsingChangeNow to execute, or getChangeNowSupportedCurrencies to see available currencies
- 7.Optionally run scripts/swap-helper.sh for an interactive guided swap walkthrough
Use cases
- Swap SOL for USDC or other SPL tokens on Solana by amount, dollar value, or token name
- Exchange tokens on EVM chains (Ethereum, Base, BSC, Polygon) via automatic DEX route aggregation
- Swap HBAR or other tokens on Hedera
- Bridge assets cross-chain (e.g. ETH to SOL) using ChangeNow's 500+ supported currencies
- Check token balances and get swap quotes before executing a transaction
- Crypto users who want to swap or bridge tokens via a conversational agent
- Developers building agent workflows that need on-chain token swap execution
- Agent operators using EmblemAI's agent wallet for multi-chain DeFi operations
emblem-token-swap FAQ
Solana, Ethereum, Base, BSC, Polygon, and Hedera have native swap tools, plus cross-chain bridging via ChangeNow which supports 500+ currencies.
Bitcoin has balance support (getBTCBalances) but no on-chain swap tools; you must use ChangeNow for BTC bridges instead.
No. All swaps run in safe mode, showing swap details and waiting for explicit user confirmation before executing, and never bypasses confirmation for value-moving operations.
Always include the exact tool name, the amount (dollar value or token quantity), the source token, and the target token in your request.
Node.js >= 18.0.0 and the @emblemvault/agentwallet CLI (npm install -g @emblemvault/agentwallet), plus internet access.
Full instructions (SKILL.md)
Source of truth, from emblemcompany/agent-skills.
name: emblem-token-swap description: > Execute token swaps across 6 blockchains via EmblemAI. Automatic route optimization and cross-chain bridging via ChangeNow. Use when the user wants to swap tokens, exchange crypto, convert between currencies, or bridge assets cross-chain. license: MIT compatibility: > Requires Node.js >= 18.0.0, @emblemvault/agentwallet CLI, and internet access. Works on Claude Code, Cursor, Codex, OpenClaw, and other agents following the Agent Skills spec. metadata: author: EmblemAI version: "1.1.0" homepage: https://emblemvault.ai docs: https://emblemvault.ai/docs docs-interactive: https://emblemvault.dev
Emblem Token Swap
Guided token swapping powered by EmblemAI. Swap tokens on Solana, Ethereum, Base, BSC, Polygon, and Hedera with automatic routing. Cross-chain bridging via ChangeNow.
Requires: npm install -g @emblemvault/agentwallet
What This Skill Can Do
| Chain | Quote Tool | Swap Tool | Balance Tool | Token Search |
|---|---|---|---|---|
| Solana | splBuyIntent (quote mode) | splBuyIntent (swap mode) | solanaBalances | findSolanaSwapToken |
| Ethereum | ethSwapQuote | ethSwap | ethGetBalances | searchCryptoByName |
| Base | baseSwapQuote | baseSwap | baseGetBalances | searchEvmTokensBirdeye |
| BSC | bscSwapQuote | bscSwap | bscGetBalances | searchEvmTokensBirdeye |
| Polygon | polygonSwapQuote | polygonSwap | polygonGetBalances | searchEvmTokensBirdeye |
| Hedera | hederaTokensSwapQuote | hederaTokensSwap | hederaGetBalances | hederaFindTokens |
| Cross-chain | getChangeNowSwapQuote | swapUsingChangeNow | — | getChangeNowSupportedCurrencies |
Notes
- Solana uses
splBuyIntentfor both quotes and execution — it handles token lookup by name/symbol/CA and flexible amounts ($USD, SOL, or token quantity) - EVM chains (Ethereum, Base, BSC, Polygon) route through automatic DEX aggregation
- Cross-chain bridges via ChangeNow support 500+ currencies
- Bitcoin has balance support (
getBTCBalances) but no on-chain swap tools — use ChangeNow for BTC bridges
Quick Start
npm install -g @emblemvault/agentwallet
# Solana swap (uses splBuyIntent)
emblemai --agent --profile default -m "Use splBuyIntent to swap 5 SOL for USDC on Solana"
# Cross-chain bridge (uses ChangeNow)
emblemai --agent --profile default -m "Use getChangeNowSwapQuote to get a quote for bridging 0.05 ETH from Ethereum to SOL on Solana"
Trigger phrases:
- "Swap SOL to USDC"
- "Exchange ETH for USDT"
- "Convert my tokens"
- "Bridge tokens to Base"
Workflow: Safe Token Swap
Step 1: Check Balance
Confirm you have enough of the source token.
emblemai --agent --profile default -m "Use solanaBalances to show my Solana token balances"
Step 2: Get a Quote
Preview the swap before executing.
emblemai --agent --profile default -m "Use splBuyIntent to get a quote for swapping 5 SOL to USDC"
Step 3: Execute the Swap
emblemai --agent --profile default -m "Use splBuyIntent to swap 5 SOL for USDC on Solana"
Safe mode requires your confirmation before executing.
Step 4: Verify
Confirm the new balance.
emblemai --agent --profile default -m "Use solanaBalances to show my updated balances"
Swap Patterns
Solana Swaps
# By token amount
emblemai --agent --profile default -m "Use splBuyIntent to swap 0.5 SOL for USDC"
# By dollar amount
emblemai --agent --profile default -m "Use splBuyIntent to swap $20 of SOL for JUP"
# By token name
emblemai --agent --profile default -m "Use splBuyIntent to swap 100 USDC for BONK"
EVM Swaps
# Ethereum
emblemai --agent --profile default -m "Use ethSwapQuote to get a quote for swapping 0.01 ETH to USDC, then use ethSwap to execute"
# Base
emblemai --agent --profile default -m "Use baseSwapQuote to quote 0.005 ETH to USDC on Base"
# BSC
emblemai --agent --profile default -m "Use bscSwapQuote to quote 0.1 BNB to USDT on BSC"
# Polygon
emblemai --agent --profile default -m "Use polygonSwapQuote to quote 10 POL to USDC on Polygon"
Hedera Swaps
emblemai --agent --profile default -m "Use hederaTokensSwapQuote to get a quote for 100 HBAR to USDC, then use hederaTokensSwap to execute"
Cross-Chain Bridge
emblemai --agent --profile default -m "Use getChangeNowSwapQuote to quote bridging 0.1 ETH to SOL"
emblemai --agent --profile default -m "Use getChangeNowSupportedCurrencies to show available bridge currencies"
Communication Rules
Always include these in swap requests:
- Tool name — specify the exact tool for reliable routing
- Amount — dollar value or token quantity
- Source token — what you're swapping from
- Target token — what you're swapping to
| Bad | Good |
|---|---|
"swap sol usdc" | "Use splBuyIntent to swap 5 SOL for USDC" |
"buy eth" | "Use ethSwap to swap 100 USDC to ETH on Ethereum" |
"bridge" | "Use getChangeNowSwapQuote to bridge 0.05 ETH to SOL" |
Safety
All swaps require explicit user confirmation (safe mode). The agent will:
- Show you the swap details (amount, route, estimated output)
- Wait for your approval before executing
- Report the transaction result
Never bypasses confirmation for any value-moving operation.
Helper Script
bash scripts/swap-helper.sh
See scripts/swap-helper.sh for an interactive swap walkthrough.
Links
Related skills
More from emblemcompany/agent-skills and the wider catalog.
emblem-portfolio-tracker
Check crypto balances and trade P&L across 7 blockchains in one agent prompt.
emblem-market-research
Real-time crypto trending, on-chain, and derivatives intelligence from CoinGecko, Birdeye, CoinGlass, and Nansen.
emblem-ai-agent-wallet
Give your coding agent a review-first, multi-chain crypto wallet via EmblemVault/EmblemAI.
emblem-ai-prompt-examples
Curated, safety-conscious prompt examples for EmblemAI trading, NFT, and portfolio workflows.
emblem-ai-react
Add wallet-enabled auth, login, and chat to a React app in one EmblemAI integration.
emblem-ai
Add wallet, email, and social login with wallet-enabled user accounts and an embeddable AI chat assistant in one integration.