Skip to main content
kraken-cli ships a built-in Model Context Protocol server over stdio. It exposes all 151 CLI commands as structured tools that any MCP-compatible AI agent can call — Claude, Cursor, GitHub Copilot, Windsurf, and others. The MCP server is part of the CLI binary. Install the CLI first.

Quickstart

This starts the server with the default safe service set: market (public data), account (read-only), and paper (paper trading). No credentials required for market and paper.

Client setup

Run once to register the server for your user:
For all services including live trading:
Verify it is registered:

Services

Pass -s <services> to control which command groups are exposed. Multiple services are comma-separated. Default (no -s flag): market, account, paper.

Dangerous tools

Tools marked dangerous (order placement, withdrawals, transfers) require the calling agent to pass acknowledged: true in the tool input unless the server was started with --allow-dangerous. This gives you a confirmation gate at the tool level without relying on the agent’s judgment alone.

Authentication

Set credentials as environment variables before starting the server:
Or use the CLI config file (set up once with kraken setup). The server inherits credentials from the CLI’s standard resolution order.

What agents can do

With the default safe service set, an agent can:
  • Query live prices, orderbooks, and recent trades for any pair
  • Check account balances and open orders
  • Place and cancel paper trades against live prices
  • Stream real-time market data
With trade added, an agent can place, amend, and cancel live orders. With funding, it can initiate withdrawals. Scope services to the minimum your workflow requires.

Safety notes

  • The MCP server runs locally over stdio and is not exposed as a network service
  • Use minimum-permission API keys scoped to what the agent actually needs
  • The default service set (market, account, paper) is read-only for live funds
  • Treat agent sessions with live trading scope the same as a logged-in user session
  • Set position size limits and pair allowlists at the API key level on Kraken’s settings page

Agent resources

The CLI ships supplementary resources for agent integration: