# Send crypto-trader to your agent
Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.
## Fast path
- Download the package from Yavira.
- Extract it into a folder your agent can access.
- Paste one of the prompts below and point your agent at the extracted folder.
## Suggested prompts
### New install

```text
I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.
```
### Upgrade existing

```text
I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "crypto-trader",
    "name": "crypto-trader",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/nandichi/crypto-trader",
    "canonicalUrl": "https://clawhub.ai/nandichi/crypto-trader",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/crypto-trader",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=crypto-trader",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "requirements.txt",
      "config/strategies.yaml",
      "config/notifications.yaml",
      "config/risk_limits.yaml",
      "config/exchanges.yaml",
      "config/cron_examples.yaml"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "slug": "crypto-trader",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-11T21:00:12.698Z",
      "expiresAt": "2026-05-18T21:00:12.698Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=crypto-trader",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=crypto-trader",
        "contentDisposition": "attachment; filename=\"crypto-trader-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "crypto-trader"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/crypto-trader"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    }
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/crypto-trader",
    "downloadUrl": "https://openagent3.xyz/downloads/crypto-trader",
    "agentUrl": "https://openagent3.xyz/skills/crypto-trader/agent",
    "manifestUrl": "https://openagent3.xyz/skills/crypto-trader/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/crypto-trader/agent.md"
  }
}
```
## Documentation

### Crypto Trader Skill

Automated cryptocurrency trading with 8 strategies, multi-exchange support, AI sentiment analysis, and comprehensive risk management.

Important: By default all operations run against testnet (paper trading). Set CRYPTO_DEMO=false only when you are absolutely certain the user wants to trade with real money.

### Prerequisites

Install dependencies once from the skill directory:

pip install -r {baseDir}/requirements.txt

Required environment variables (set in .env or via OpenClaw settings):

BINANCE_API_KEY and BINANCE_API_SECRET (required for Binance)
CRYPTO_DEMO=true (default: paper trading mode)

Optional:

BYBIT_API_KEY, BYBIT_API_SECRET (for Bybit)
KRAKEN_API_KEY, KRAKEN_API_SECRET (for Kraken)
COINBASE_API_KEY, COINBASE_API_SECRET (for Coinbase)
TELEGRAM_BOT_TOKEN, TELEGRAM_CHAT_ID (for Telegram alerts)
DISCORD_WEBHOOK_URL (for Discord alerts)
CRYPTOPANIC_API_KEY (for sentiment analysis)

### 1. status -- Portfolio and strategy overview

python3 {baseDir}/scripts/main.py --mode status

Returns JSON with:

Portfolio value per exchange
Active strategies and their state
Risk status (daily P&L, drawdown, kill switch)
Environment (paper/live)

Use when the user asks: "How is my portfolio?", "What's running?", "Give me an overview."

### 2. balance -- Check exchange balances

python3 {baseDir}/scripts/main.py --mode balance
python3 {baseDir}/scripts/main.py --mode balance --exchange binance

Returns balances for the specified exchange (or all exchanges). Shows total, free, and used amounts per asset.

Use when the user asks: "How much BTC do I have?", "What's my balance?", "Show my funds."

### 3. start_strategy -- Start a trading strategy

python3 {baseDir}/scripts/main.py --mode start_strategy --strategy grid --params '{"symbol":"BTC/USDT","price_range":[90000,110000],"num_grids":10,"order_amount_usdt":10}'
python3 {baseDir}/scripts/main.py --mode start_strategy --strategy dca --params '{"symbol":"ETH/USDT","interval":"daily","amount_per_buy_usdt":5}'
python3 {baseDir}/scripts/main.py --mode start_strategy --strategy trend --params '{"symbol":"BTC/USDT","timeframe":"4h"}'

Supported strategies:

StrategyNameDescriptionGrid Tradinggrid_tradingBuy/sell at evenly spaced price levels within a rangeDCAdcaBuy fixed amounts at regular intervalsTrend Followingtrend_followingEMA crossover + RSI signalsScalpingscalpingFast small trades on spread/momentumArbitragearbitrageCross-exchange price difference exploitationSwing Tradingswing_tradingBollinger Bands + MACD, hold 2-14 daysCopy Tradingcopy_tradingReplicate trades from tracked wallets/tradersRebalancingrebalancingMaintain target portfolio allocation

Each strategy uses defaults from config/strategies.yaml which can be overridden via --params.

CRITICAL: Always confirm with the user before starting a strategy. Show the parameters clearly and ask for approval.

Use when the user asks: "Start grid trading on BTC", "I want to DCA into ETH", "Follow the trend on SOL."

### 4. stop_strategy -- Stop a running strategy

python3 {baseDir}/scripts/main.py --mode stop_strategy --strategy-id <id>

Stops a specific strategy instance. The strategy ID is returned when starting and shown in the list.

### 5. list_strategies -- List all strategies

python3 {baseDir}/scripts/main.py --mode list_strategies

Returns all available and running strategies with their status, parameters, and performance stats.

### 6. backtest -- Test a strategy on historical data

python3 {baseDir}/scripts/main.py --mode backtest --strategy grid_trading --params '{"symbol":"BTC/USDT","price_range":[40000,50000],"num_grids":10}' --start 2025-01-01 --end 2025-12-31
python3 {baseDir}/scripts/main.py --mode backtest --strategy dca --params '{"symbol":"BTC/USDT","interval":"daily","amount_per_buy_usdt":10}' --start 2025-06-01 --end 2025-12-31
python3 {baseDir}/scripts/main.py --mode backtest --strategy trend_following --params '{"symbol":"BTC/USDT","timeframe":"4h"}' --start 2025-01-01 --end 2025-12-31

Returns performance metrics:

Total return % vs buy-and-hold
Win rate, trade count
Max drawdown, Sharpe ratio
Fee impact
Individual order history

Results are saved to data/backtests/.

Use when the user asks: "Would grid trading have worked?", "Backtest DCA on ETH", "Test this strategy."

### 7. history -- Trade history

python3 {baseDir}/scripts/main.py --mode history --days 7
python3 {baseDir}/scripts/main.py --mode history --days 30

Returns completed orders from all exchanges for the last N days.

### 8. sentiment -- Market sentiment analysis

python3 {baseDir}/scripts/main.py --mode sentiment --symbol BTC
python3 {baseDir}/scripts/main.py --mode sentiment --symbol ETH

Analyzes sentiment from:

Crypto news RSS feeds (CoinTelegraph, CoinDesk)
CryptoPanic (requires API key)
Reddit (r/cryptocurrency, r/bitcoin)
Twitter (requires bearer token)

Returns aggregate score (-1.0 to 1.0) with labels: very_bearish, bearish, neutral, bullish, very_bullish.

Use when the user asks: "What's the market sentiment?", "Is BTC bullish right now?", "Any news about ETH?"

### 9. monitor -- Real-time monitoring daemon

python3 {baseDir}/scripts/main.py --mode monitor --action start
python3 {baseDir}/scripts/main.py --mode monitor --action status
python3 {baseDir}/scripts/main.py --mode monitor --action stop

The monitoring daemon runs in the background and:

Checks open orders every 10 seconds
Updates portfolio snapshot every 60 seconds
Checks risk limits every 60 seconds
Evaluates strategy signals every 5 minutes
Runs sentiment analysis every 30 minutes
Sends alerts via Telegram/Discord/Email

### 10. emergency_stop -- Kill switch

python3 {baseDir}/scripts/main.py --mode emergency_stop

Immediately:

Cancels ALL open orders on ALL exchanges
Stops ALL running strategies
Activates the kill switch (blocks all future trades)

The kill switch must be manually deactivated before trading can resume.

Use when the user says: "Stop everything!", "Emergency!", "Kill all trades."

### config/exchanges.yaml

Exchange connectivity settings, sandbox mode, rate limits.

### config/strategies.yaml

Default parameters for each strategy. Users can override via --params.

### config/risk_limits.yaml

Risk management rules:

max_position_size_pct: Max portfolio % per position (default: 25%)
max_daily_loss_eur: Emergency stop on daily loss (default: 50 EUR)
max_drawdown_pct: Stop at drawdown from ATH (default: 15%)
max_order_size_eur: Max per order (default: 100 EUR)
max_open_orders: Max concurrent orders (default: 50)
Stop-loss (fixed 5%, trailing 3%)
Take-profit (10%, partial at 5%)

### config/notifications.yaml

Alert routing rules per event type and channel.

### Safety Rules

NEVER execute trades without explicit user confirmation in live mode.
Default mode is paper trading (CRYPTO_DEMO=true). Remind the user which mode is active.
API keys must have TRADE permissions only. NEVER withdrawal permissions.
Risk limits are enforced automatically. If a limit is hit, explain to the user what happened.
Emergency stop is always available and overrides everything.
Always show estimated cost and risk before confirming a trade.
If CRYPTO_DEMO=false, warn the user clearly that this uses real money.
Log all actions. The user can review history at any time.
When starting a strategy, show the full parameter set and ask for confirmation.
Never bypass risk limits, even if the user asks. Explain why the limit exists.

### Output Format

All modes return structured JSON to stdout. Parse it and present a human-readable summary to the user. Highlight important numbers (P&L, prices, risk metrics). Use clear formatting with tables where appropriate.

### Running Tests

cd {baseDir}
pip install pytest
python -m pytest tests/ -v

### "Exchange not initialized"

Check that the API key and secret are set in environment variables for the target exchange.

### "Authentication failed"

Verify your API keys are correct and not expired. For testnet, make sure you're using testnet keys.

### "Rate limit reached"

The skill automatically retries with backoff. If persistent, reduce strategy evaluation frequency.

### "Kill switch is active"

The emergency stop was triggered. Review what happened, then deactivate:
The kill switch state is stored in ~/.openclaw/.crypto-trader-risk-state.json. Set "killed": false to reset, or use a future CLI command to deactivate.
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: nandichi
- Version: 1.0.0
## Source health
- Status: healthy
- Item download looks usable.
- Yavira can redirect you to the upstream package for this item.
- Health scope: item
- Reason: direct_download_ok
- Checked at: 2026-05-11T21:00:12.698Z
- Expires at: 2026-05-18T21:00:12.698Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/crypto-trader)
- [Send to Agent page](https://openagent3.xyz/skills/crypto-trader/agent)
- [JSON manifest](https://openagent3.xyz/skills/crypto-trader/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/crypto-trader/agent.md)
- [Download page](https://openagent3.xyz/downloads/crypto-trader)