2.6k
GitHub Stars
2
Bundled Files
2 months ago
Catalog Refreshed
4 months ago
First Indexed
Readme & install
Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.
Installation
Preview and clipboard use veilstrat where the catalogue uses aiagentskills.
npx veilstrat add skill openclaw/skills --skill mi-trading- _meta.json277 B
- SKILL.md3.4 KB
Overview
This skill provides a CLI interface to trade Solana tokens through the ClawDex tool, using Jupiter for route aggregation. It offers quotes, dry-run simulations, real swap execution, balance checks, and safety guardrails with machine-friendly JSON output. Use it to automate or script token trades and wallet management on Solana with clear exit codes and safety controls.
How this skill works
The skill wraps the clawdex CLI to perform status checks, fetch balances, request quotes, run on-chain simulations, and execute swaps. All commands support --json for structured output; simulations use --simulate-only and real swaps require --yes. It enforces configurable safety limits and reports violations in JSON alongside standard exit codes for programmatic handling.
When to use it
- You need a price quote without touching your wallet (lightweight check).
- You want to preview a swap via on-chain simulation before committing.
- You need to execute a non-interactive swap from a script or bot (use --yes).
- You must verify wallet connectivity and RPC health before trading.
- You want automated guardrails to prevent large slippage or price impact.
Best practices
- Always run clawdex status --json first and abort if rpc.healthy is false.
- Check balances with clawdex balances --json and parse balance as a string to preserve precision.
- Simulate every trade with clawdex swap --simulate-only --json before executing.
- Use clawdex swap --yes --json for automated execution; without --yes the CLI exits with code 1.
- Configure safety limits (max_slippage_bps, max_trade_sol, max_price_impact_bps) to avoid runaway trades.
- Respect exit codes: non-zero indicates a problem—inspect the JSON message and violations array.
Example use cases
- Bot fetches a quote for SOL→USDC before deciding to trade.
- CI job runs health check and balance verification, then simulates a rebalancing swap.
- Automated strategy executes a swap non-interactively with --yes after a successful simulation.
- Operator sets safety guardrails to cap trade size and slippage across all programmatic trades.
- Audit script archives JSON outputs of status, quotes, simulations, and executed swaps for compliance.
FAQ
No. Quote commands are lightweight and do not require a wallet or simulation.
Is --yes required for swaps?
Yes. --yes is required for non-interactive execution; without it clawdex exits with code 1 to prevent accidental trades.