/trading-solana
Trade tokens on Solana DEXes - Jupiter, Raydium, Orca, Meteora, Pump.fun
$ npx -y skills add alsk1992/CloddsBot --skill trading-solana --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
- You can call itInvoke it directly when you want it.
- Slash command
/trading-solana
Context preview
The summary Claude sees to decide when to auto-load this skill.
Trade tokens on Solana DEXes - Jupiter, Raydium, Orca, Meteora, Pump.fun
SKILL.md
trading-solana.SKILL.mdname: trading-solana
description: "Trade tokens on Solana DEXes - Jupiter, Raydium, Orca, Meteora, Pump.fun"
emoji: "☀️"
gates:
envs:
- SOLANA_PRIVATE_KEYSolana DEX Trading - Complete API Reference
Trade any token on Solana using Jupiter aggregator, Raydium, Orca Whirlpools, Meteora DLMM, and Pump.fun.
Required Environment Variables
SOLANA_PRIVATE_KEY=base58_or_json_array # Your Solana wallet private key
SOLANA_RPC_URL=https://api.mainnet-beta.solana.com # Optional: custom RPC
---
Chat Commands
Swaps
/sol swap <amount> <from> to <to> # Swap tokens on Solana
/sol swap 1 SOL to USDC # Swap 1 SOL to USDC
/sol swap 100 USDC to JUP # Swap 100 USDC to JUP
/sol swap 0.5 SOL to BONK # Swap 0.5 SOL to BONK
Quotes
/sol quote <amount> <from> to <to> # Get swap quote without executing
/sol quote 1 SOL to USDC # Quote 1 SOL → USDC
Pool Discovery
/sol pools <token> # List liquidity pools for token
/sol pools SOL # All SOL pools
/sol pools BONK # All BONK pools
Balances & Wallet
/sol balance # Check SOL and token balances
/sol address # Show wallet address
---
Supported DEXes
| DEX | Type | Features | |-----|------|----------| | Jupiter | Aggregator | Best route across all DEXes, limit orders, DCA | | Raydium | AMM | Concentrated liquidity, high volume | | Orca | Whirlpool | Concentrated liquidity pools, LP management | | Meteora | DLMM | Dynamic liquidity market maker, LP management | | Pump.fun | Launchpad | New token launches |
---
TypeScript API Reference
Jupiter (Aggregator - Recommended)
import {
executeJupiterSwap,
getJupiterQuote,
createJupiterLimitOrder,
cancelJupiterLimitOrder,
listJupiterLimitOrders,
createJupiterDCA,
closeJupiterDCA,
listJupiterDCAs,
} from 'clodds/solana/jupiter';
// Execute swap via Jupiter (best route)
const result = await executeJupiterSwap(connection, keypair, {
inputMint: 'So11111111111111111111111111111111111111112', // SOL
outputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v', // USDC
amount: '1000000000', // 1 SOL in lamports
slippageBps: 50, // 0.5% slippage
});
console.log(`Swapped: ${result.inAmount} → ${result.outAmount}`);
console.log(`TX: ${result.signature}`);Jupiter Limit Orders
// Create limit order - sell 1 SOL for minimum 250 USDC
const order = await createJupiterLimitOrder(connection, keypair, {
inputMint: 'So11111111111111111111111111111111111111112',
outputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
inAmount: '1000000000', // 1 SOL
outAmount: '250000000', // 250 USDC
expiredAtMs: Date.now() + 7 * 24 * 60 * 60 * 1000, // 1 week expiry
});
console.log(`Order created: ${order.orderPubKey}`);
// List open orders
const orders = await listJupiterLimitOrders(connection, keypair.publicKey.toBase58());
console.log(`Open orders: ${orders.length}`);
// Cancel order
await cancelJupiterLimitOrder(connection, keypair, order.orderPubKey);Jupiter DCA (Dollar Cost Averaging)
// Create DCA - swap 100 USDC to JUP, 10 USDC every hour
const dca = await createJupiterDCA(connection, keypair, {
inputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v', // USDC
outputMint: 'JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN', // JUP
inAmount: '100000000', // Total 100 USDC
inAmountPerCycle: '10000000', // 10 USDC per swap
cycleSecondsApart: 3600, // Every hour (min 30 seconds)
});
console.log(`DCA created: ${dca.dcaPubKey}`);
// List active DCAs
const dcas = await listJupiterDCAs(connection, keypair.publicKey.toBase58());
// Close DCA and withdraw remaining funds
await closeJupiterDCA(connection, keypair, dca.dcaPubKey);Raydium
import {
executeRaydiumSwap,
getRaydiumQuote,
listRaydiumPools,
getClmmPositions,
createClmmPosition,
increaseClmmLiquidity,
decreaseClmmLiquidity,
closeClmmPosition,
harvestClmmRewards,
addAmmLiquidity,
removeAmmLiquidity,
} from 'clodds/solana/raydium';
// Get quote
const quote = await getRaydiumQuote({
inputMint: 'SOL',
outputMint: 'USDC',
amount: 1_000_000_000,
});
console.log(`Expected output: ${quote.outAmount}`);
// Execute swap
const result = await executeRaydiumSwap(connection, keypair, {
inputMint: 'So11111111111111111111111111111111111111112',
outputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
amount: '1000000000',
slippageBps: 50,
});
// List pools
const pools = await listRaydiumPools({ tokenMints: ['So11111111111111111111111111111111111111112'] });
// CLMM: Open concentrated liquidity position
const position = await createClmmPosition(connection, keypair, {
poolId: 'POOL_ID_HERE',
priceLower: 100,
priceUpper: 200,
baseAmount: '1000000000',
});
// CLMM: List positions
const positions = await getClmmPositions(connection, keypair);
// CLMM: Harvest rewards
const rewards = await harvestClmmRewards(connection, keypair);
// AMM: Add liquidity
await addAmmLiquidity(connection, keypair, {
poolId: 'AMM_POOL_ID',
amountA: '1000000000',
fixedSide: 'a',
});Orca Whirlpools
import { executeOrcaWhirlpoolSwap, getOrcaWhirlpoolQuote, listOrcaWhirlpoolPools } from 'clodds/solana/orca';
// Get quote
const quote = await getOrcaWhirlpoolQuote({
inputMint: 'SOL',
outputMint: 'USDC',
amount: 1_000_000_000,
});
// Execute swap
const result = await executeOrcaWhirlpoolSwap({
inputMint: 'SOL',
outputMint: 'USDC',
amount: 1_000_000_000,
slippage: 0.5,
});
// List pools
const pools = await listOrcaWhirlpoolPools({ token: 'SOL' });Meteora DLMM
import { executeMeteoraDlmmSwap, getMeteoraDlmmQuote, listMeteoraDlmmPools } fRead more
name: trading-solana
description: "Trade tokens on Solana DEXes - Jupiter, Raydium, Orca, Meteora, Pump.fun"
emoji: "☀️"
gates:
envs:
- SOLANA_PRIVATE_KEYSolana DEX Trading - Complete API Reference
Trade any token on Solana using Jupiter aggregator, Raydium, Orca Whirlpools, Meteora DLMM, and Pump.fun.
Required Environment Variables
SOLANA_PRIVATE_KEY=base58_or_json_array # Your Solana wallet private key SOLANA_RPC_URL=https://api.mainnet-beta.solana.com # Optional: custom RPC
---
Chat Commands
Swaps
/sol swap <amount> <from> to <to> # Swap tokens on Solana /sol swap 1 SOL to USDC # Swap 1 SOL to USDC /sol swap 100 USDC to JUP # Swap 100 USDC to JUP /sol swap 0.5 SOL to BONK # Swap 0.5 SOL to BONK
Quotes
/sol quote <amount> <from> to <to> # Get swap quote without executing /sol quote 1 SOL to USDC # Quote 1 SOL → USDC
Pool Discovery
/sol pools <token> # List liquidity pools for token /sol pools SOL # All SOL pools /sol pools BONK # All BONK pools
Balances & Wallet
/sol balance # Check SOL and token balances /sol address # Show wallet address
---
Supported DEXes
| DEX | Type | Features | |-----|------|----------| | Jupiter | Aggregator | Best route across all DEXes, limit orders, DCA | | Raydium | AMM | Concentrated liquidity, high volume | | Orca | Whirlpool | Concentrated liquidity pools, LP management | | Meteora | DLMM | Dynamic liquidity market maker, LP management | | Pump.fun | Launchpad | New token launches |
---
TypeScript API Reference
Jupiter (Aggregator - Recommended)
import {
executeJupiterSwap,
getJupiterQuote,
createJupiterLimitOrder,
cancelJupiterLimitOrder,
listJupiterLimitOrders,
createJupiterDCA,
closeJupiterDCA,
listJupiterDCAs,
} from 'clodds/solana/jupiter';
// Execute swap via Jupiter (best route)
const result = await executeJupiterSwap(connection, keypair, {
inputMint: 'So11111111111111111111111111111111111111112', // SOL
outputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v', // USDC
amount: '1000000000', // 1 SOL in lamports
slippageBps: 50, // 0.5% slippage
});
console.log(`Swapped: ${result.inAmount} → ${result.outAmount}`);
console.log(`TX: ${result.signature}`);Jupiter Limit Orders
// Create limit order - sell 1 SOL for minimum 250 USDC
const order = await createJupiterLimitOrder(connection, keypair, {
inputMint: 'So11111111111111111111111111111111111111112',
outputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
inAmount: '1000000000', // 1 SOL
outAmount: '250000000', // 250 USDC
expiredAtMs: Date.now() + 7 * 24 * 60 * 60 * 1000, // 1 week expiry
});
console.log(`Order created: ${order.orderPubKey}`);
// List open orders
const orders = await listJupiterLimitOrders(connection, keypair.publicKey.toBase58());
console.log(`Open orders: ${orders.length}`);
// Cancel order
await cancelJupiterLimitOrder(connection, keypair, order.orderPubKey);Jupiter DCA (Dollar Cost Averaging)
// Create DCA - swap 100 USDC to JUP, 10 USDC every hour
const dca = await createJupiterDCA(connection, keypair, {
inputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v', // USDC
outputMint: 'JUPyiwrYJFskUPiHa7hkeR8VUtAeFoSYbKedZNsDvCN', // JUP
inAmount: '100000000', // Total 100 USDC
inAmountPerCycle: '10000000', // 10 USDC per swap
cycleSecondsApart: 3600, // Every hour (min 30 seconds)
});
console.log(`DCA created: ${dca.dcaPubKey}`);
// List active DCAs
const dcas = await listJupiterDCAs(connection, keypair.publicKey.toBase58());
// Close DCA and withdraw remaining funds
await closeJupiterDCA(connection, keypair, dca.dcaPubKey);Raydium
import {
executeRaydiumSwap,
getRaydiumQuote,
listRaydiumPools,
getClmmPositions,
createClmmPosition,
increaseClmmLiquidity,
decreaseClmmLiquidity,
closeClmmPosition,
harvestClmmRewards,
addAmmLiquidity,
removeAmmLiquidity,
} from 'clodds/solana/raydium';
// Get quote
const quote = await getRaydiumQuote({
inputMint: 'SOL',
outputMint: 'USDC',
amount: 1_000_000_000,
});
console.log(`Expected output: ${quote.outAmount}`);
// Execute swap
const result = await executeRaydiumSwap(connection, keypair, {
inputMint: 'So11111111111111111111111111111111111111112',
outputMint: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
amount: '1000000000',
slippageBps: 50,
});
// List pools
const pools = await listRaydiumPools({ tokenMints: ['So11111111111111111111111111111111111111112'] });
// CLMM: Open concentrated liquidity position
const position = await createClmmPosition(connection, keypair, {
poolId: 'POOL_ID_HERE',
priceLower: 100,
priceUpper: 200,
baseAmount: '1000000000',
});
// CLMM: List positions
const positions = await getClmmPositions(connection, keypair);
// CLMM: Harvest rewards
const rewards = await harvestClmmRewards(connection, keypair);
// AMM: Add liquidity
await addAmmLiquidity(connection, keypair, {
poolId: 'AMM_POOL_ID',
amountA: '1000000000',
fixedSide: 'a',
});Orca Whirlpools
import { executeOrcaWhirlpoolSwap, getOrcaWhirlpoolQuote, listOrcaWhirlpoolPools } from 'clodds/solana/orca';
// Get quote
const quote = await getOrcaWhirlpoolQuote({
inputMint: 'SOL',
outputMint: 'USDC',
amount: 1_000_000_000,
});
// Execute swap
const result = await executeOrcaWhirlpoolSwap({
inputMint: 'SOL',
outputMint: 'USDC',
amount: 1_000_000_000,
slippage: 0.5,
});
// List pools
const pools = await listOrcaWhirlpoolPools({ token: 'SOL' });Meteora DLMM
import { executeMeteoraDlmmSwap, getMeteoraDlmmQuote, listMeteoraDlmmPools } fOpen Source AI trading agent that operates autonomously across 1000+ markets - Polymarket, Kalshi, Binance, Hyperliquid, Solana DEXs, 5 EVM chains. Scans for edge, executes instantly, manages risk while you sleep. Agent commerce protocol for machine-to-machine payments. Self-hosted. Built on Claude.
Repo: alsk1992/CloddsBot
Other skills on cloddsbot.
- /acp
Enable agent-to-agent commerce with on-chain escrow, cryptographic agreements, and service discovery.
Open skill - /agentbets
AgentBets - AI-native prediction markets on Solana
Open skill - /ai-strategy
AI Strategy - natural language to trades
Open skill - /alerts
Create and manage price alerts for prediction markets
Open skill - /analytics
Performance attribution, trade analytics, and strategy optimization
Open skill - /arbitrage
Automated cross-platform arbitrage detection and monitoring
Open skill

