kraken-autonomy-levels
Progress from manual trading to full agent autonomy with controlled risk at each level.
Price alerts, threshold monitoring, and notification triggers for agents.
Claude Code
$ npx -y skills add krakenfx/kraken-cli --skill kraken-alert-patterns --agent claude-code
Codex
$ npx skills add krakenfx/kraken-cli --skill kraken-alert-patterns -a codex -y
Cursor
$ npx skills add krakenfx/kraken-cli --skill kraken-alert-patterns -a cursor -y
Gemini CLI
$ npx skills add krakenfx/kraken-cli --skill kraken-alert-patterns -a gemini-cli -y
GitHub Copilot
$ npx skills add krakenfx/kraken-cli --skill kraken-alert-patterns -a github-copilot -y
OpenCode
$ npx skills add krakenfx/kraken-cli --skill kraken-alert-patterns -a opencode -y
Windsurf
$ npx skills add krakenfx/kraken-cli --skill kraken-alert-patterns -a windsurf -y
name: kraken-alert-patterns
version: 1.0.0
description: "Price alerts, threshold monitoring, and notification triggers for agents."
metadata:
openclaw:
category: "finance"
requires:
bins: ["kraken"]Use this skill for:
Check price at intervals and compare against thresholds:
PRICE=$(kraken ticker BTCUSD -o json 2>/dev/null | jq -r '.[].last_price') # Agent compares $PRICE to upper/lower thresholds # If breached, notify the user
More efficient for continuous monitoring. The agent reads the stream and fires when conditions are met:
kraken ws ticker BTC/USD -o json 2>/dev/null | while read -r line; do LAST=$(echo "$line" | jq -r '.data[0].last // empty') [ -z "$LAST" ] && continue # Compare against thresholds, break or notify on breach done
Detect when the bid-ask spread widens beyond a threshold (liquidity warning):
kraken ws ticker BTC/USD --event-trigger bbo -o json 2>/dev/null | while read -r line; do ASK=$(echo "$line" | jq -r '.data[0].ask // empty') BID=$(echo "$line" | jq -r '.data[0].bid // empty') [ -z "$ASK" ] || [ -z "$BID" ] && continue SPREAD=$(echo "$ASK - $BID" | bc) # Alert if spread exceeds threshold done
Compare current 24h volume against a baseline:
kraken ticker BTCUSD -o json 2>/dev/null | jq -r '.[].volume_24h' # Agent compares to historical average # Alert if volume > 2x baseline
Read recent candles and compute range or standard deviation:
kraken ohlc BTCUSD --interval 60 -o json 2>/dev/null # Agent calculates high-low range per candle # Alert if range exceeds threshold
Monitor for unexpected balance changes:
INITIAL=$(kraken balance -o json 2>/dev/null | jq -r '.USD // "0"') # On each check: CURRENT=$(kraken balance -o json 2>/dev/null | jq -r '.USD // "0"') # Alert if |CURRENT - INITIAL| exceeds threshold
Streaming alternative:
kraken ws balances -o json 2>/dev/null # Each line is a balance update event
Alert on trade executions:
kraken ws executions -o json 2>/dev/null | while read -r line; do TYPE=$(echo "$line" | jq -r '.data[0].exec_type // empty') [ "$TYPE" = "trade" ] && echo "Fill: $line" done
Monitor futures positions for margin or P&L thresholds:
kraken futures positions -o json 2>/dev/null # Agent checks unrealized P&L against stop-loss threshold
Stream futures balance changes:
kraken futures ws balances -o json 2>/dev/null
Futures notifications (margin calls, liquidation warnings):
kraken futures ws notifications -o json 2>/dev/null
Watch several pairs and alert on the first one that hits a condition:
kraken ws ticker BTC/USD ETH/USD SOL/USD -o json 2>/dev/null | while read -r line; do PAIR=$(echo "$line" | jq -r '.data[0].symbol // empty') LAST=$(echo "$line" | jq -r '.data[0].last // empty') [ -z "$PAIR" ] || [ -z "$LAST" ] && continue # Check pair-specific thresholds done
The CLI outputs alerts to stdout. The agent is responsible for delivering notifications through its own channels (Slack, email, push notification, or presenting to the user in chat).
| Condition | Method | Command | |-----------|--------|---------| | Price crosses level | Stream | `ws ticker <PAIR>` | | Spread widens | Stream | `ws ticker <PAIR> --event-trigger bbo` | | Volume spike | Poll | `ticker <PAIR>` | | Balance change | Stream | `ws balances` | | Trade fill | Stream | `ws executions` | | Futures margin | Stream | `futures ws balances` | | Futures notification | Stream | `futures ws notifications` |
Trade on Kraken from your terminal, or let your AI agent trade for you. One install covers crypto, tokenized U.S. stocks and ETFs (for non-U.S. customers), forex, and futures. Every command can answer in JSON.
Progress from manual trading to full agent autonomy with controlled risk at each level.
Capture the spot-futures price spread with delta-neutral basis trades.
Dollar cost averaging with scheduled buys and performance tracking.
Discover staking strategies, allocate funds, and track earn positions.
Handle order failures, network errors, and duplicate submissions safely.
Minimize trading fees through maker orders, volume tiers, and fee-aware execution.
Complete, populate and fill out 3-statement financial model templates (Income Statement, Balance Sheet, Cash Flow Statement) .…
Complete, populate and fill out 3-statement financial model templates (Income Statement, Balance Sheet, Cash Flow Statement) .…