Telegram crypto trading bots processed over $190 billion in cumulative volume by early 2025, turning a niche experiment into one of the fastest-growing segments in DeFi. Bots like Maestro, Banana Gun, and Trojan collectively serve millions of wallets, and the market is still expanding: Telegram surpassed 950 million monthly active users in 2025, giving bot developers a captive audience of crypto-native users who prefer executing trades without leaving their chat window.
The bottleneck is rarely the Telegram integration itself. The hard part is token swaps: finding the best route across DEX liquidity pools, encoding the transaction calldata, and submitting it on-chain with proper slippage protection. The swap layer determines your bot's speed, chain coverage, and reliability.
This guide ranks the 5 best token swap solutions for Telegram bot developers in 2026, scored on integration complexity, chain support, cost, and latency. Every solution listed returns executable swap calldata that your bot can submit directly to the blockchain.
What a Telegram Bot Needs from a Swap API
Before comparing solutions, here is what matters for Telegram bot token swap integrations:
- Single-request execution. Users expect one-tap trades. Your swap API should return ready-to-sign calldata in one call, not a multi-step flow.
- Multi-chain support. Ethereum-only bots lose users to competitors. At minimum, cover Ethereum, BSC, Base, Arbitrum, and Polygon.
- No API key requirement. API keys add onboarding friction and create a single point of failure. Keyless APIs let you ship faster and scale without rate-limit negotiations.
- Low latency. Telegram users expect sub-second responses. The swap API should return quotes in 1-5 seconds.
- Slippage and partial fill handling. Meme coin and low-liquidity trades fail often. Your API should handle partial fills instead of returning errors.
1. Swap API (swapapi.dev)
Swap API is a free DEX aggregator that returns executable swap calldata from a single GET request. No API key, no registration, no account required. It supports 46 EVM chains, making it the widest-coverage aggregator available without authentication.
For Telegram bots, the integration is straightforward. When a user sends /swap 1 ETH USDC, your bot parses the command, calls the API, and gets back a complete transaction object ready for on-chain submission.
curl "https://api.swapapi.dev/v1/swap/1?tokenIn=0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE&tokenOut=0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48&amount=1000000000000000000&sender=0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045"
The response includes tx.to, tx.data, and tx.value which you pass directly to eth_sendTransaction. It also returns expectedAmountOut, minAmountOut (slippage-protected), priceImpact, and a list of recommended RPC URLs for the target chain.
A key advantage for bot developers: the API handles partial fills gracefully. Instead of returning an error when full liquidity is unavailable, it returns a Partial status with adjusted amounts. Your bot can present this to the user as "partial fill available" rather than "swap failed."
const res = await fetch(`https://api.swapapi.dev/v1/swap/42161?tokenIn=0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE&tokenOut=0xaf88d065e77c8cC2239327C5EDb3A432268e5831&amount=1000000000000000000&sender=${walletAddress}`);
const { data } = await res.json();
Chains: 46 EVM chains including Ethereum, Arbitrum, Base, BSC, Polygon, Optimism, Avalanche, Monad, MegaETH, Berachain, Sonic, and more.
Cost: Free. No usage limits published.
Best for: Telegram bots that need the fastest integration path with maximum chain coverage and zero operational overhead.
2. 1inch Swap API
1inch is the largest DEX aggregator by market share, routing over $28 billion in Q2 2025. Its Pathfinder algorithm splits trades across 400+ liquidity sources to minimize slippage, which matters for large-volume Telegram bot trades.
The API provides separate quote and swap endpoints. For a Telegram bot, this means two HTTP calls per trade: one to show the user a quote, and another to get the executable calldata.
curl -H "Authorization: Bearer YOUR_API_KEY" "https://api.1inch.dev/swap/v6.0/1/swap?src=0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE&dst=0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48&amount=1000000000000000000&from=0xYourAddress"
The trade-off is friction. 1inch requires API key registration, and rate limits vary by plan. For a Telegram bot handling hundreds of concurrent users, you may need to negotiate higher limits or implement key rotation.
Chains: 12 major blockchains.
Cost: Free tier available with rate limits. Paid plans for higher throughput.
Best for: High-volume Telegram bots on major chains where routing optimization is the priority and API key management is acceptable.
3. 0x (Zero Ex) Swap API
0x aggregates liquidity from on-chain DEXs and professional market makers through its RFQ (Request for Quote) system. The RFQ layer can deliver better prices on large trades by sourcing off-chain liquidity, which benefits Telegram bots serving whale users.
The API requires an API key and has moved to paid pricing tiers. Integration follows a similar pattern: call the quote endpoint, present the price to the user, then call the swap endpoint for calldata.
const res = await fetch("https://api.0x.org/swap/permit2/quote?buyToken=0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48&sellToken=0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE&sellAmount=1000000000000000000", {
headers: { "0x-api-key": process.env.ZRX_API_KEY }
});
0x supports Ethereum, Polygon, BSC, Arbitrum, Optimism, Base, Avalanche, and several other chains. The Permit2 integration simplifies token approvals, which reduces one step in the Telegram bot UX flow.
Chains: 10+ EVM chains.
Cost: Paid tiers. Free developer tier with limited requests.
Best for: Telegram bots that handle large individual trades where RFQ-sourced liquidity can meaningfully improve prices.
4. Paraswap API
Paraswap offers a DEX aggregation API with a focus on gas optimization. Its MultiPath algorithm finds routes that minimize both slippage and gas costs, which is valuable on Ethereum mainnet where gas fees can eat into smaller trades.
The API provides rate and swap endpoints. It supports limit orders and delta pricing (where market makers compete for your order flow). For Telegram bots, the limit order feature enables "set and forget" trades that execute when a target price is hit.
curl "https://api.paraswap.io/swap?srcToken=0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE&destToken=0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48&amount=1000000000000000000&network=1&userAddress=0xYourAddress"
Paraswap does not require an API key for basic usage, which is a plus for rapid prototyping. However, higher-volume usage may require contacting their team for dedicated access.
Chains: 8 major EVM chains.
Cost: Free for standard usage. Enterprise plans available.
Best for: Telegram bots focused on Ethereum mainnet where gas optimization provides the most value.
5. Odos API
Odos differentiates itself with Smart Order Routing (SOR) that can split trades across multiple protocols and token paths simultaneously. Its router supports multi-token input swaps, meaning a user could swap multiple tokens into one output token in a single transaction.
The API uses a two-step flow: first call /sor/quote to get the optimized route, then call /sor/assemble with the returned pathId to get the transaction calldata.
curl -X POST "https://api.odos.xyz/sor/quote/v2" -H "Content-Type: application/json" -d '{"chainId":1,"inputTokens":[{"tokenAddress":"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE","amount":"1000000000000000000"}],"outputTokens":[{"tokenAddress":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48","proportion":1}],"userAddr":"0xYourAddress"}'
The multi-token swap capability is unique. A Telegram bot could implement a "dump all" command that converts a user's entire portfolio into a single stablecoin in one transaction.
Chains: 14 EVM chains.
Cost: Free. No API key required for standard usage.
Best for: Telegram bots that want to offer portfolio-level operations like multi-token swaps or rebalancing.
Comparison Table
| Feature | Swap API | 1inch | 0x | Paraswap | Odos |
|---|---|---|---|---|---|
| API Key Required | No | Yes | Yes | No* | No |
| EVM Chains | 46 | 12 | 10+ | 8 | 14 |
| Request Style | Single GET | Multi-step | Multi-step | Multi-step | Multi-step (POST) |
| Partial Fills | Yes | No | No | No | No |
| RPC URLs Included | Yes | No | No | No | No |
| Cost | Free | Freemium | Paid | Free* | Free |
*Paraswap is free for standard usage but may require enterprise access at scale.
Integrating Swap API into a Telegram Bot
Here is a minimal integration showing how a Telegram bot handles a /swap command using Swap API. The bot parses the user's message, calls the API, and returns a signable transaction.
async function handleSwap(chatId: string, chain: number, tokenIn: string, tokenOut: string, amount: string, sender: string) {
const url = `https://api.swapapi.dev/v1/swap/${chain}?tokenIn=${tokenIn}&tokenOut=${tokenOut}&amount=${amount}&sender=${sender}`;
const res = await fetch(url);
const { success, data, error } = await res.json();
if (!success) return sendMessage(chatId, `Swap failed: ${error.message}`);
const humanAmount = Number(data.expectedAmountOut) / 10 ** data.tokenTo.decimals;
sendMessage(chatId, `Swap quote: ${humanAmount} ${data.tokenTo.symbol}\nPrice impact: ${(data.priceImpact * 100).toFixed(2)}%`);
return data.tx;
}
The response includes everything needed for on-chain execution:
-
tx.to- the DEX router contract address -
tx.data- ABI-encoded swap calldata (treat as opaque, do not modify) -
tx.value- native token amount in wei (for native-to-token swaps) -
rpcUrls- ranked list of public RPCs for the target chain
Your bot submits the transaction using eth_sendTransaction through the user's connected wallet or a custodial key, using the provided RPC URLs as a fallback list.
Handling Edge Cases in Telegram Bots
Telegram bot token swap integrations need to handle several edge cases that browser-based DeFi apps can ignore:
Token approvals. ERC-20 to ERC-20 swaps require the user to approve the router contract before the swap. Your bot should check allowance first and prompt for approval if needed.
Decimal differences. The same token can have different decimals on different chains. USDT uses 6 decimals on Ethereum but 18 decimals on BSC. Always use the decimals field from the API response, never hardcode.
Partial fills. When liquidity is thin, the API may return a Partial status. The amountIn and expectedAmountOut fields reflect the partial fill, not the original requested amount. Present this clearly to the user.
Transaction timing. Quotes are time-sensitive. If a user takes 30 seconds to confirm, the price may have moved. Fetch a fresh quote immediately before signing.
Gas estimation. The API returns gasPrice but not gasLimit. Use eth_estimateGas with the returned tx object to get the gas limit before submitting.
FAQ
What is the best free API for Telegram bot token swaps?
Swap API (swapapi.dev) is the best free option. It requires no API key, supports 46 EVM chains, and returns executable calldata in a single GET request. The zero-setup requirement makes it ideal for Telegram bot developers who need to ship fast.
How many chains do Telegram trading bots typically support?
Most popular Telegram trading bots support 3-5 chains (Ethereum, BSC, Base, Arbitrum, Solana). Using an aggregator API with wider chain coverage like Swap API (46 chains) lets your bot differentiate by supporting niche chains without additional integration work.
Do I need an API key to integrate token swaps in my Telegram bot?
Not with every provider. Swap API and Odos offer keyless access. 1inch and 0x require API key registration. For Telegram bots, keyless APIs reduce deployment complexity and eliminate the risk of key leakage in bot hosting environments.
How fast should a Telegram bot swap API respond?
Telegram users expect near-instant feedback. The swap API should return a quote in 1-5 seconds. Swap API's typical response time falls within this range. Always set an HTTP timeout of 15 seconds to handle edge cases gracefully.
Can Telegram bots handle partial fills?
Yes, if your swap API supports them. Swap API returns a Partial status with adjusted amounts when full liquidity is unavailable. Your bot should detect this status and inform the user that only a portion of their trade can be filled at the current price.
Get Started
Integrate token swaps into your Telegram bot in under 10 minutes:
- Parse user commands (
/swap 1 ETH USDC on arbitrum). - Map token symbols to contract addresses using a token list.
- Call
https://api.swapapi.dev/v1/swap/{chainId}with the parsed parameters. - Present the quote (
expectedAmountOut,priceImpact) to the user. - On confirmation, submit the
txobject on-chain using the providedrpcUrls.
No API key. No registration. Start building at swapapi.dev.
Top comments (0)