GDEX Trading Skills
Deep dive on the GDEX trading, copy-trading, and discovery skills — capabilities, real SDK method signatures, and the managed-custody auth flow
The trading skills give any agent full-stack DeFi capability through the @gdexsdk/gdex-skill package — spot swaps, HyperLiquid perpetual futures, limit orders, copy trading, bridging, portfolio analytics, and token discovery. Every example below uses the actual SDK method names and parameters from GemachDAO/gdex-skill.
Supported Chains
Ethereum
1
ETH
Optimism
10
ETH
BNB Smart Chain
56
BNB
Sonic
146
S
Fraxtal
252
frxETH
Nibiru
6900
NIBI
Base
8453
ETH
Arbitrum One
42161
ETH
Berachain
80094
BERA
Solana
622112261
SOL
Sui
1313131213
SUI
HyperLiquid
perps only
USDC
The Solana numeric chainId is 622112261 (ChainId.SOLANA), not 900. Using 900 returns the EVM managed wallet with a null balance.
Authentication
Shared API keys (recommended for agents)
Two shared keys are pre-configured in the package, so agents can read data and submit managed trades without handling a user's private key:
Read-only endpoints (getTrendingTokens, getTokenDetails, getOHLCV, getTopTraders) require no authentication.
Managed-custody session keys
All trading runs through server-side managed wallets. The user's control wallet signs once (the sign-in message); on-chain execution is performed by GDEX backend trade workers. Write operations use a secp256k1 session keypair plus AES-256-CBC encrypted computedData:
Skill Reference
gdex-spot-trading
Buy and sell tokens across Solana, Sui, and EVM chains with automatic DEX routing.
Example prompts: "Buy 0.1 SOL of USDC", "Sell 50% of my BONK", "Buy $50 of ARB on Arbitrum".
gdex-perp-trading
HyperLiquid perpetual futures — open/close positions, set leverage, place market and limit orders with TP/SL.
Example prompts: "Open a 5x long on ETH with $200", "Close half my BTC short", "Set BTC leverage to 20x".
gdex-perp-funding
Deposit and withdraw USDC to/from HyperLiquid (human-readable amounts, converted internally; 10 USDC minimum deposit).
Example prompts: "Deposit 25 USDC to HyperLiquid", "Withdraw 10 USDC from my perp account".
gdex-limit-orders
Create, update/delete, and list limit orders via managed-custody encrypted payloads. Endpoints are limit_buy / limit_sell / update_order / orders.
Example prompts: "Buy TOKEN when it drops to $0.50", "Set a take-profit sell at $999", "Cancel my open limit order".
gdex-copy-trading
Discover top wallets and create/manage Solana copy trades. Discovery is read-only; writes are Solana-only and sign in with chainId: 622112261.
There is no pause/toggle on the backend — both isDelete: true and isChangeStatus: true permanently delete a copy trade.
Example prompts: "Show the top Solana wallets by PnL", "Copy 0xLeader with 0.001 SOL per trade", "Delete my Alpha Trader copy trade".
gdex-perp-copy-trading
Copy HyperLiquid perpetual-futures traders. Completely separate from Solana copy trading; sign-in uses chainId: 1 and all ABI fields are strings.
Example prompts: "Who are the top HyperLiquid traders this week?", "Copy 0xWhale's perps at $50 per order", "Copy 0xTrader but inverted".
gdex-bridge
Cross-chain bridging of native tokens between EVM chains, Solana, and Sui (via ChangeNow). Always quote first, then execute.
Example prompts: "Bridge 100 USDC from Solana to Ethereum", "What does it cost to bridge 0.5 ETH to Arbitrum?".
gdex-portfolio
Cross-chain portfolio overview, chain-specific balances, and paginated trade history.
Example prompts: "Show my portfolio across all chains", "What's my ETH balance on Base?", "List my last 20 trades".
gdex-token-discovery
Token details, trending tokens, OHLCV candles, and top traders.
Example prompts: "What's trending on Solana?", "Get the 1h candles for SOL", "Show the top traders this week".
gdex-livestream-discovery
Solana livestream-token discovery — currently-live streams, per-token live status, and big-buy alert feeds. Useful for surfacing tokens with active community livestreams before momentum trades.
Example prompts: "Which Solana tokens are livestreaming right now?", "Is this token live?", "Show me the big-buy alert feed".
Error Handling
The SDK throws typed errors so agents can recover gracefully:
When something goes wrong, hand off to gdex-sdk-debugging, which maps error codes, encryption issues, and chain-specific gotchas to fixes.
See also:
🛠️ Platform & UI Skills — onboarding, transfers, social, HyperLiquid extras, React UI, and debugging
✏️ Creating Custom Skills — build your own trading skill
🧩 Agent Skills Overview — the complete catalog and install options
Last updated