接入你的智能体
發布者自己的指令。不是 PlugMCP 端點。
用我們的金鑰與日誌託管一份副本。
npx -y [email protected]Claude Code 沒有本機指令的安裝連結。複製下方指令並在終端機中執行。
claude mcp add robinhood-for-agents -- npx -y robinhood-for-agents@5.0.0在終端機中執行。
{ "mcpServers": { "robinhood-for-agents": { "command": "npx", "args": [ "-y", "[email protected]" ] } }}claude_desktop_config.json
遠端 URL 還是本機指令? 兩種安裝方式的差異
An MCP server that lets your AI agent read and trade your Robinhood account, in one of two modes:
Also included: a TypeScript client library (82 async methods) and a trading skill for agent apps that support skills. Works with Claude Code, Codex, Cursor, Antigravity, Hermes, and any other MCP client; OpenClaw uses the skill.
Run the installer. Needs Bun v1.3+.
bunx robinhood-for-agents install
It detects your agent apps and asks which to configure and whether to add web mode, then registers the server with a generated ROBINHOOD_TOKEN_KEY (reused on re-runs) and copies the trading skill into each app that supports skills. Manual setup instead: npx -y add-mcp "bunx robinhood-for-agents" -g -n robinhood-for-agents --env "ROBINHOOD_TOKEN_KEY=<32-byte base64 key>" plus npx skills add kevin1chun/robinhood-for-agents.
Other clients:
Web mode only: the skill calls the client library through bun, with no MCP server. bunx robinhood-for-agents install covers it when ~/.openclaw exists (as "OpenClaw (skill only)": the skill plus robinhood-for-agents in ~/.openclaw/workspace). Alternative:
clawhub install robinhood-for-agents
Add to ~/.hermes/config.yaml, keeping the entries for the modes you use, then run /reload-mcp:
mcp_servers:
robinhood-for-agents:
command: "bunx"
args: ["robinhood-for-agents"]
env:
ROBINHOOD_TOKEN_KEY: "<any 32-byte base64 key, e.g. from the installer's config entry>"
robinhood-web:
command: "bunx"
args: ["robinhood-for-agents", "--mode", "web"]
Restart the app and ask your agent to "log in to Robinhood"; approve once in the browser. Then prompt it: "show my portfolio".
Use standard mode unless you need something only web mode has. It is the surface Robinhood supports for agents: the 76 official tools, with Robinhood's own titles, descriptions, schemas, and annotations, each call relayed unchanged to agent.robinhood.com/mcp/trading. Orders reach your Agentic account only; other accounts are read-only. Web mode trades that for reach: it calls the web API robinhood.com itself uses, serves every brokerage account, and backs the client library, but Robinhood does not sanction it for agents.
25 tools exist only in standard mode, 8 only in web mode; the Mode column in Tools says which, and docs/MODES.md has the full comparison. To run both, register both entries, robinhood-for-agents and robinhood-web. Tool names match, so your agent tells them apart by entry; the credentials are separate.
Prerequisites: Bun v1.3+ and a Robinhood account. Standard mode needs ROBINHOOD_TOKEN_KEY (the installer sets it), and its sign-in opens your browser with the macOS open command. Web mode needs Google Chrome for login (playwright-core, channel: "chrome"; no bundled browser, Brave/Chromium fallback, or BROWSER_PATH override).
bunx robinhood-for-agents install # pick apps, register the server, copy the skill; -y takes every detected app, standard mode only
bunx robinhood-for-agents login # web-mode Chrome login outside an MCP client
bunx robinhood-for-agents login --export # also writes ./tokens.enc for Docker
install registers entries through the add-mcp library (supported apps: npx add-mcp list-agents) and copies the skill with the skills CLI. It overwrites existing robinhood-for-agents/robinhood-web entries and keeps the ROBINHOOD_TOKEN_KEY already in them.
git clone https://github.com/kevin1chun/robinhood-for-agents.git
cd robinhood-for-agents
bun install
bun bin/robinhood-for-agents.ts # standard mode; add --mode web for web mode
To register a checkout, pass "bun run /path/to/checkout/bin/robinhood-for-agents.ts" as the add-mcp target in the manual setup line.
What each client gets:
robinhood_official_login, then approve once in the browser it opens. The browser must reach the server's 127.0.0.1 callback. Until then, every standard-mode tool answers an error naming the login tool. The credential is stored as official-mcp.enc (AES-256-GCM under ROBINHOOD_TOKEN_KEY), never in the keychain.robinhood_browser_login, then log in to Robinhood in Chrome with your credentials and MFA. The token capture is a passive network intercept that never touches the page. The session is cached in the OS keychain (or the encrypted file named by ROBINHOOD_TOKENS_FILE) and renews a day before expiry and on any 401; a long idle gap lapses it and needs a new login. robinhood_check_session probes the API and answers logged_in, expired, unknown, or not_authenticated."Buy 1 50-delta SPX call expiring tomorrow"

The robinhood-for-agents skill (Claude Code and OpenClaw; clawhub install robinhood-for-agents from ClawHub) adds guided workflows. With Claude Code it drives whichever MCP entry you registered, so standard-only tools need robinhood-for-agents; standalone it uses the client library, which is web mode only.
In skills/robinhood-for-agents/, SKILL.md routes to domain files (portfolio.md, trade.md, …) and the client-api.md reference, loaded on demand. More examples: docs/USE_CASES.md.
Names and input schemas are the official ones, prefixed robinhood_ (parity table). In standard mode each tool also carries Robinhood's title, description, output schema, and annotations verbatim from docs/official-mcp-tools.json. The hosted server's rate limit: measured here. Mode: standard or web = only in that mode; both = both modes.
Both modes run review → confirm → place. robinhood_review_equity_order simulates the order (live quote plus Robinhood's price collar) and places nothing. Show the result, get explicit confirmation, then call robinhood_place_equity_order. The client-side checks below run in web mode only; standard mode relays the call for Robinhood to validate.
Side — buy, sell, or sell_short:
sell only closes a long; selling shares you don't hold fails with Not enough shares to sell. sell_short carries unlimited loss, so confirm the user meant a short. Shorts also need gfd and the regular or extended session, not the 24 Hour Market.
Trading session — market_hours defaults to regular_hours, as in the official tool:
An order tagged to the wrong session queues for the next open instead of executing, which looks like success. Name the session outside regular hours; robinhood_get_market_hours says which is live. See examples/short-selling.ts, trade.md, and docs/ARCHITECTURE.md.
import { RobinhoodClient } from "robinhood-for-agents";
const client = new RobinhoodClient();
await client.restoreSession();
const quotes = await client.getQuotes("AAPL");
const portfolio = await client.buildHoldings();
Web mode only; there is no client-library path to the hosted MCP. All 82 methods are async, and account-scoped ones take accountNumber. Reference, including EncryptedFileTokenStore and direct-accessToken construction: client-api.md.
Without a keychain or browser, both modes keep their credential in an encrypted file under ROBINHOOD_TOKEN_KEY and sign in on the host.
official-mcp.enc lives beside ROBINHOOD_TOKENS_FILE, so mount the directory, not the file (docs/DOCKER.md).bunx robinhood-for-agents login --export on the host. It exports ./tokens.enc, copies the key to the clipboard, and prints the env vars, including ROBINHOOD_MODE=web (docs/DOCKER.md).Keep the mount read-write and use one process per token file: refresh tokens are single-use, and a failed write-back logs CRITICAL to stderr and strands the container on restart. Encryption stops casual disk access, not an agent with shell access that can read the key, so run only agents you trust (docs/SECURITY.md).
time_in_force and market_hours default to gfd and regular_hours, as in the official tools.sell_short side, so a mis-parsed "sell" can never open one."ACCOUNT_ID".bun install
bun run typecheck # tsc --noEmit
bun run check # Biome lint + format
npx vitest run # all tests — vitest, not `bun test`
Integration tests (read-only, real API, not in CI): bunx robinhood-for-agents login, then bun run test:integration. Design: docs/ARCHITECTURE.md. Adding tools and skills: docs/CONTRIBUTING.md.
This project is not affiliated with, endorsed by, or sponsored by Robinhood Markets, Inc. "Robinhood" is a trademark of Robinhood Markets, Inc. This software interacts with Robinhood's services through publicly accessible interfaces but is an independent, third-party tool.
USE AT YOUR OWN RISK. This software enables AI agents to read data from and place orders on your Robinhood brokerage account. Automated and AI-assisted trading carries inherent risks, including but not limited to:
You are solely responsible for all activity on your brokerage account, whether initiated manually or through this software. The authors and contributors assume no liability for any financial losses, damages, or other consequences arising from the use of this software. Review all AI-proposed actions before confirming, and never grant unsupervised trading authority to any automated system.
This software is provided "as is" without warranty of any kind. See LICENSE for full terms.
I'm a solo developer. I built this for myself, I use it every day, and I keep it up to date so anyone else can share the joy of it. If it saves you time or makes trading more fun, a coffee helps me keep pace with changes to Robinhood's API and official MCP, and keep adding new tools:
A star on the repo helps too, and issues and pull requests are always welcome.
MIT — see LICENSE.
AI-native Robinhood trading interface — MCP server + TypeScript client
{ "mcpServers": { "robinhood-for-agents": { "command": "npx", "args": [ "-y", "[email protected]" ] } }}工具
尚無工具清單。遠端伺服器會在首次健康檢查後取得工具清單。
常見問題
在本頁複製適用於 Cursor、Claude Desktop、Claude Code 或 VS Code 的 stdio 設定。它使用發布者的安裝方式,而不是 PlugMCP 代理伺服器。
這筆記錄未列出必要的環境變數。
Robinhood For Agents 透過 stdio 在本機執行。
上次檢查時間:2026-10-28。 AI-native Robinhood trading interface — MCP server + TypeScript client