Getting Started
Connect Claude, ChatGPT or your coding agent to Keel with nothing to install, or run the CLI from `pipx install` to a backtest in five commands.
Keel is a quantitative crypto trading platform driven from your AI agent
or your terminal. The fastest start is hosted and needs no install: add
Keel to the assistant you already use. The local install (pipx install keel-trade) adds the keel CLI and a local MCP server, with strategies in
your filesystem; backtests run against Keel's price and funding data on
Hyperliquid either way.
See it working first: Funding carry in the strategy library shows a full backtest on Hyperliquid perps, net of fees, slippage and funding, with the rules you can fork.
Hosted: nothing to install
- Claude or ChatGPT: Keel is listed in the Claude connectors directory and the ChatGPT plugin directory. Add it from its listing and sign in; Agent Setup has both listing links and the steps.
- Claude Code, Cursor, Codex or Windsurf: add the hosted endpoint
https://mcp.usekeel.io/mcpand sign in in the browser. In Claude Code that isclaude mcp add --transport http keel https://mcp.usekeel.io/mcp, then/mcpand Authenticate. Nothing to install. - Local:
pipx install keel-tradegives you thekeelCLI and a local MCP server; the install steps are below.
Then ask your agent:
"Find a carry strategy in the Keel library and backtest it."
Local: two commands, then talk to your agent
pipx install keel-trade # or: uv tool install keel-trade
claude mcp add keel -- keel mcp serve # register the stdio MCP with Claude CodeOpen Claude Code and say:
"Connect to Keel, then backtest a carry strategy."
Claude calls keel_auth_login (browser opens — sign in, close the tab),
then keel_strategy_compose + keel_backtest_run. You're done. No
terminal-side login dance, no ~/.keel/config.yaml to inspect.
What the agent does for you
| Prompt | Tool the agent calls |
|---|---|
| "connect to keel" / "log me in" | keel_auth_login |
| "what's my status?" | keel_account_status |
| "find momentum signals" | keel_components_search |
| "build a carry strategy on top-30 perps" | keel_strategy_compose |
| "backtest from 2025-06-01 to 2026-02-01" | keel_backtest_run |
| "what went wrong with that backtest?" | keel_backtest_summarize |
| "fork it and try ROC 14" | keel_strategy_fork |
| "list my recent tool/audit events" | keel_audit_list_last |
Each tool returns a share_url you can click to see the tearsheet in
your browser.
1. Install
pipx install keel-trade # or: uv tool install keel-tradeRequires Python 3.11+. pipx and uv both work — pipx is more
common, uv is faster. The package ships with the Keel DSL validator,
component catalog, and the MCP server bound into the
keel binary.
Verify:
keel --version
# keel, version <latest>2. Register the MCP for your agent
# Claude Code
claude mcp add keel -- keel mcp serve
# Cursor — add to .cursor/mcp.json:
{
"mcpServers": {
"keel": { "command": "keel", "args": ["mcp", "serve"] }
}
}The agent host launches keel mcp serve as a child process and talks to it
over stdin/stdout. You do not need to run a daemon, open a port, or start a
separate service. No login needed yet — the next step does that from inside
Claude.
Agent Setup has the full matrix (Windsurf, Continue, Cline, OpenAI Codex, generic MCP client).
3. Sign in — from inside Claude
Open Claude Code (or your MCP-capable agent) and say:
"Connect to Keel."
Claude calls the keel_auth_login MCP tool. Your default browser opens
to app.usekeel.io/oauth/connect, you complete the OAuth 2.1 + PKCE
consent, and tokens land in ~/.keel/config.yaml. You stay logged in
for 30 days — access tokens refresh transparently before each request.
For live-trading scope (deploy / pause / stop strategies on Hyperliquid), say:
"Connect to Keel with live trading."
Claude calls keel_auth_login(scope="live") and the "Include live
trading" checkbox is pre-checked on the consent page. Live trading
also requires you to arm your local machine — defense in depth. See
keel arm live --help.
Paper trading needs no live-trading scope and no new login: it runs on the
access that lets you run a backtest, which every API key and keel auth login
already holds.
Logging in from a terminal
If you'd rather skip the MCP-driven flow and authenticate before registering the MCP, the same OAuth ceremony is one CLI command:
keel auth loginFor headless environments (CI, SSH, GitHub Codespaces, WSL without port forwarding) where the CLI and your browser are not on the same machine, use:
keel auth login --key <token>
# Token from https://app.usekeel.io/settings?tab=api-keys4. Verify
keel statusShows your identity, org, plan, entitlements, and the scopes your
session has — also lists every MCP tool currently exposed under your
KEEL_TOOLSETS. If anything looks off, run keel auth logout and try
again. From inside Claude, the equivalent is "What's my Keel status?"
(which calls keel_account_status).
5. First strategy + backtest
From your agent, ask:
"Create a funding-carry baseline, validate it, save it, then backtest 2025-06-01 through 2026-02-01."
The agent should follow this tool sequence:
| Step | Tool |
|---|---|
| Find candidate components | keel_components_search |
| Inspect schemas | keel_components_get_many |
| Validate source without saving | keel_strategy_compose(dry_run=True, ...) |
| Save the strategy | keel_strategy_compose(dry_run=False, ...) |
| Run the backtest | keel_backtest_run(strategy_id=<id>, start_date="2025-06-01") |
| Watch if still active | keel_backtest_watch(backtest_id=<run_id>) |
| Read terminal metrics if needed | keel_backtest_summarize(backtest_id=<run_id>) |
CLI equivalent for an existing strategy.py:
keel strategy compose --source-file strategy.py --dry-run --format json
STRATEGY_ID=$(keel strategy compose \
--source-file strategy.py \
--name my-first \
--format json | jq -r '.strategy_id')
BT_ID=$(keel backtest run "$STRATEGY_ID" \
--start-date 2025-06-01 \
--format json | jq -r '.run_id')
keel backtest watch "$BT_ID" --format json
keel backtest summarize "$BT_ID" --format jsonOpen the returned hero_url or share_url in your browser for the rich
tearsheet.
Omit --end-date to run through today's UTC date. Pass it only when you need a
fixed historical window.
Next steps
- Step-by-step CLI walkthrough — every command with annotated output
- Agent Setup — Claude Code, Cursor, Windsurf, Codex configs + skills
- CLI Reference — every command grouped by domain
- Web app alternative — visual strategy builder + AI editor at
app.usekeel.io
Paper first
To watch a strategy trade forward before it touches real capital, start a paper run. Fills are simulated at live Hyperliquid prices; no real orders are placed and no exchange account is needed:
keel paper deploy <strategy-id>It completes in one call. Read the run with keel live monitor <deployment-id>;
see Paper trading for the fill model, plan slots and the
auto-pause rules.
Going live
Once you have a backtested strategy you want to run on Hyperliquid:
# Print the deploy link; no orders are sent and no accounts are enumerated
keel live deploy <strategy-id>
# Poll the handoff you were given (pending | completed | expired)
keel live deploy <strategy-id> --intent-token <resume-token>keel live deploy returns code=handoff_required with an action_url. You
open that link and finish in the Keel web app: connect or pick a Hyperliquid
account, review the server-computed sizing, accept the risk, go live. The CLI
never places the orders, so nothing on your machine can deploy live capital on
its own.
Connecting an account is web-only — an EIP-712 wallet challenge signed at https://app.usekeel.io/accounts.
Plan limits
Your current plan, entitlements, scopes, and exposed toolsets are shown by
keel status. Sign up or manage billing at
app.usekeel.io.