universal-trading
Execute cross-chain token trading on EVM and Solana with Particle Network Universal Account SDK. Use when users ask to set up universal-account-example, buy or sell tokens, run convert/swap flows, transfer assets, call custom transactions, query balances/history, or monitor transaction status via WebSocket.
About this skill
The `universal-trading` skill empowers AI agents to manage and execute cross-chain cryptocurrency operations across various EVM networks and Solana, leveraging the Particle Network Universal Account SDK. This comprehensive capability allows agents to handle the full lifecycle of digital asset management, from initial account setup and wallet import to performing complex trading activities like token buying, selling, and swapping. It also supports asset transfers, custom transaction calls, balance inquiries, transaction history retrieval, and real-time status monitoring via WebSocket. Users can utilize this skill when they need to interact with their universal accounts for various financial tasks. This includes setting up new accounts or importing existing ones, executing trades to acquire or divest tokens, facilitating asset conversions between different cryptocurrencies, and moving assets between wallets. The skill is designed to simplify interactions with blockchain infrastructure, enabling users to manage their digital portfolios through natural language prompts to their AI agent, rather than directly engaging with command-line tools or complex SDKs. By integrating the Particle Network Universal Account SDK, the skill provides a robust and secure framework for handling decentralized finance (DeFi) activities. It is particularly valuable for users who wish to automate or streamline their multi-chain trading strategies, offering a unified interface for complex cross-chain operations and reducing the manual effort involved in managing diverse digital assets across different blockchain ecosystems.
Best use case
The primary use case for this skill is to automate and simplify cross-chain cryptocurrency trading and asset management for users operating on both EVM and Solana networks. It is ideal for cryptocurrency traders, DeFi enthusiasts, and blockchain developers who require an AI agent to set up universal accounts, execute token swaps, manage asset transfers, and monitor transaction statuses across diverse blockchain ecosystems. This skill enables seamless interaction with decentralized finance without needing deep technical knowledge of underlying SDKs or command-line operations.
Execute cross-chain token trading on EVM and Solana with Particle Network Universal Account SDK. Use when users ask to set up universal-account-example, buy or sell tokens, run convert/swap flows, transfer assets, call custom transactions, query balances/history, or monitor transaction status via WebSocket.
A successful cross-chain token trade, asset transfer, account setup, or status update on EVM or Solana networks, executed and confirmed through the AI agent.
Practical example
Example input
Help me buy 0.05 ETH on the Polygon network using my universal account.
Example output
Initializing universal account... Account setup successful. Your private key is stored at `universal-account-example/.env`. Now attempting to purchase 0.05 ETH on Polygon. Transaction submitted: `0x123abc456def789...`. Monitor its status using 'track transaction 0x123abc456def789...' in the future.
When to use this skill
- When a user asks to buy or sell tokens across different blockchain networks (EVM or Solana).
- When needing to convert or swap assets between various cryptocurrencies or chains.
- When transferring cryptocurrencies between wallets on EVM-compatible chains or Solana.
- When a user needs to query account balances, transaction history, or monitor real-time transaction status.
When not to use this skill
- For operations involving blockchain networks other than EVM-compatible chains or Solana.
- When dealing with traditional fiat currencies or centralized exchange accounts.
- For operations that require extremely low-level blockchain interaction not abstracted by the Particle Network SDK.
- When the primary goal is NFT specific management, rather than fungible token trading.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/universal-trading/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How universal-trading Compares
| Feature / Agent | universal-trading | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | medium | N/A |
Frequently Asked Questions
What does this skill do?
Execute cross-chain token trading on EVM and Solana with Particle Network Universal Account SDK. Use when users ask to set up universal-account-example, buy or sell tokens, run convert/swap flows, transfer assets, call custom transactions, query balances/history, or monitor transaction status via WebSocket.
How difficult is it to install?
The installation complexity is rated as medium. You can find the installation instructions above.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
Best AI Skills for Claude
Explore the best AI skills for Claude and Claude Code across coding, research, workflow automation, documentation, and agent operations.
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
Best AI Skills for ChatGPT
Find the best AI skills to adapt into ChatGPT workflows for research, writing, summarization, planning, and repeatable assistant tasks.
SKILL.md Source
# Universal Trading
Execute cross-chain trades with the official Particle Network `universal-account-example` project.
## First-Use Auto Initialization (Default)
When users install this skill and start using it for the first time, auto-run initialization by default.
Use this decision flow:
1. If `universal-account-example/.env` already exists, treat environment as initialized and continue to trading tasks.
2. If not initialized, run from any directory:
```bash
bash {baseDir}/scripts/init.sh new
```
3. If user explicitly wants to import an existing wallet, run:
```bash
bash {baseDir}/scripts/init.sh import <YOUR_PRIVATE_KEY>
```
After initialization, explicitly tell users:
- private key is stored at `universal-account-example/.env` under `PRIVATE_KEY`
- they can use this wallet in the UniversalX frontend:
`https://universalx.app` -> `创建钱包` -> `导入现有钱包`
By default, setup auto-binds invite code `666666` after `.env` is created.
It also patches `examples/buy-evm.ts` to remove `usePrimaryTokens` restriction.
Optional flags:
```bash
# Use existing repo path
bash {baseDir}/scripts/init.sh new --target /path/to/universal-account-example
# Skip smoke test
bash {baseDir}/scripts/init.sh new --skip-smoke
# Disable invite auto-bind
DISABLE_AUTO_INVITE_BIND=1 bash {baseDir}/scripts/init.sh new
```
## Available Operations
Use scripts inside `universal-account-example/examples`:
- Buy token: `buy-solana.ts`, `buy-evm.ts`
- Sell token: `sell-solana.ts`, `sell-evm.ts`
- Convert (swap): `convert-solana.ts`, `convert-evm.ts`, `7702-convert-evm.ts`
- Transfer: `transfer-solana.ts`, `transfer-evm.ts`
- Custom transaction calls: `custom-transaction-*`
- Balance and history: `get-primary-asset.ts`, `get-transactions.ts`
- Real-time monitoring: `transaction-status-wss.ts`, `user-assets-wss.ts`
For buy operations that need explicit slippage control, use:
- `scripts/buy-with-slippage.sh` (fixed slippage or dynamic retry)
## Trade Status Follow-Up (Required)
After any `sendTransaction`, do not stop at "transaction submitted".
Always return final outcome to user:
1. Capture and show `transactionId`.
2. Poll status until success or failure:
```bash
cd /path/to/universal-account-example
bash {baseDir}/scripts/check-transaction.sh <TRANSACTION_ID> --max-attempts 30 --interval-sec 2
```
3. Reply with one of:
- `SUCCESS` (confirmed)
- `FAILED` (failed on-chain/executor)
- `PENDING` (not finalized before timeout, include explorer link)
## Trade Configuration
| Option | Description | Example |
|--------|-------------|---------|
| `slippageBps` | Slippage tolerance (100 = 1%) | `100` |
| `universalGas` | Use PARTI token for gas | `true` |
| `usePrimaryTokens` | Restrict source/fee primary tokens. Default: do not set (auto select). | `[SUPPORTED_TOKEN_TYPE.USDT, SUPPORTED_TOKEN_TYPE.USDC]` |
| `solanaMEVTipAmount` | Jito tip for MEV protection (SOL) | `0.01` |
## Slippage Controls (Required for Volatile Tokens)
Allow users to choose one of these modes before buy:
1. Fixed slippage only:
```bash
cd /path/to/universal-account-example
bash {baseDir}/scripts/buy-with-slippage.sh \
--chain bsc \
--token-address 0x0000000000000000000000000000000000000000 \
--amount-usd 5 \
--slippage-bps 300
```
2. Dynamic slippage + auto retry:
```bash
cd /path/to/universal-account-example
bash {baseDir}/scripts/buy-with-slippage.sh \
--chain bsc \
--token-address 0x0000000000000000000000000000000000000000 \
--amount-usd 5 \
--slippage-bps 300 \
--dynamic-slippage \
--retry-slippages 300,500,800,1200
```
3. Solana custom tip (anti-MEV) + retry tips:
```bash
cd /path/to/universal-account-example
bash {baseDir}/scripts/buy-with-slippage.sh \
--chain solana \
--token-address 6p6xgHyF7AeE6TZkSmFsko444wqoP15icUSqi2jfGiPN \
--amount-usd 5 \
--slippage-bps 300 \
--dynamic-slippage \
--retry-slippages 300,500,800,1200 \
--solana-mev-tip-amount 0.001 \
--retry-mev-tips 0.001,0.003,0.005
```
Reply with:
- chosen slippage mode and values
- chosen Solana tip settings (if Solana)
- final status (`SUCCESS` / `FAILED` / `PENDING`)
- `transactionId` and explorer URL when available
## Supported Chains
- Solana: `CHAIN_ID.SOLANA_MAINNET`
- EVM: `CHAIN_ID.POLYGON`, `CHAIN_ID.ARBITRUM`, `CHAIN_ID.OPTIMISM`, `CHAIN_ID.BSC`, `CHAIN_ID.ETHEREUM`
## Common Token Addresses
- SOL (native): `0x0000000000000000000000000000000000000000`
- USDC (Solana): `EPjFWdd5AufqSSFqM7BcEHw3BXmQ9Ce3pq27dUGL7C24`
- USDT (Solana): `Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB`
## Safety Checklist
1. Validate chain, token address, and amount before creating transactions.
2. Use small size for first live trade.
3. Wrap `sendTransaction` in try-catch and log `transactionId`.
4. Prefer your own Particle credentials for production workloads.
## Reference Files
- [Environment Setup](references/env-setup.md)
- [API Reference](references/api.md)
- [Examples](references/examples.md)Related Skills
trading-coach
🏆 AI交易复盘教练 — 把你的券商CSV变成可执行的改进洞察! 自动FIFO配对持仓,8维度质量评分(入场/出场/趋势/风险...),10维度AI洞察。 支持富途(中/英)、老虎、中信、华泰等主流券商。 触发条件: 用户提供交易CSV、要求分析交易表现、评估交易质量、生成复盘报告、 计算盈亏统计、识别交易模式问题、"帮我复盘"、"分析我的交易"。
per-agent-compression-universal
Zero-config memory consolidation for multi-agent OpenClaw deployments. Auto-discovers agents and registers staggered cron tasks with full state tracking, deduplication, and domain-aware extraction.
convertible-bond-trading-bot
可转债自动交易机器人,止跌企稳智能选股,上涨趋势自动高抛低吸,自带回测功能,年化收益30%+。每次调用0.01USDT。
trading-analyzer
Multi-source trading analyzer (`/drunk-trading-analyzer`) combining crypto data (TradingView), stock data (Alpha Vantage), and market intelligence (Yahoo Finance) into unified analysis reports with price trends, technical indicators, and sentiment analysis.
trading-signal
Subscribe and retrieve on-chain Smart Money signals. Monitor trading activities of smart money addresses, including buy/sell signals, trigger price, current price, max gain, and exit rate. Use this skill when users are looking for investment opportunities — smart money signals can serve as valuable references for potential trades.
DEX Agent — Direct DeFi Trading Skill
**Zero-fee DeFi trading for OpenClaw agents. Bankr alternative.**
defi-trading-engine
DeFi Trading Engine - Autonomous DeFi trading bot with self-improving review system for OpenClaw agents. Use when setting up DeFi trading, crypto trading bot, automated trading, Base chain trading, Bankr integration, trading engine, self-improving bot, or trading strategy execution.
lse-trading-agent
FTSE 350 trading analysis agent. Screens LSE stocks using technical indicators (Bollinger Bands, RSI, MACD, EMA crossovers, ATR, VWAP, OBV), fetches news for LLM sentiment analysis, synthesises signals into trade recommendations with risk management (Kelly sizing, ATR stops, drawdown circuit breakers), and backtests strategies against historical data.
Universal Video to S3 Uploader
Download videos from YouTube, Twitter/X, TikTok, Douyin, Bilibili and upload to S3-compatible storage. Universal video downloader with smart quality selection and audio merging.
polymarket-copytrading
Mirror positions from top Polymarket traders using Simmer API. Size-weighted aggregation across multiple wallets.
openmm-grid-trading
Create and manage grid trading strategies with OpenMM. Automated buy/sell around center price.
maxxit-lazy-trading
Execute perpetual trades on Ostium, Aster, and Avantis via Maxxit's Lazy Trading API, and trade Indian stocks through Zerodha Kite. Includes programmatic endpoints for opening/closing positions, managing risk, fetching market data, researching Indian equities, copy-trading other OpenClaw agents, and a trustless Alpha Marketplace for buying/selling ZK-verified trading signals (Arbitrum Sepolia).