SI

sparker0i/indian-stock-mcp-agent

Browser automation

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

12 stars 10 forks 品質 65 トレンド 23

MCP Server that deals with Indian Stocks, MFs, Crypto, etc.

概要

A Model Context Protocol (MCP) server that connects to Indian broker platforms — , , and — to provide a unified, read-only view of your financial portfolio through Claude Code, Claude Desktop, or any MCP-compatible client. No paid broker API subscriptions required. The server uses to capture data from the broker web apps after you log in via a visible Chrome window. - across multiple brokers - — all asset classes - captures structured JSON from broker SPAs (more reliable than DOM scraping) - — log in once per session expiry - (AES-256-GCM) in memory - — no order placement, no fund transfers - — partial data returned if one broker fails - 18+ - installed (Playwright uses your system Chrome via channel: 'chrome') - or (or any MCP client) Copy the example env file and edit as needed: Add to your Claude Desktop config (~/.config/claude/claude_desktop_config.json on Linux, ~/Library/Application Support/Claude/claude_desktop_config.

README

以下は原文 README の抜粋です。原文を見る。

Indian Broker MCP Server

A Model Context Protocol (MCP) server that connects to Indian broker platforms — Groww, Zerodha Kite, and INDmoney — to provide a unified, read-only view of your financial portfolio through Claude Code, Claude Desktop, or any MCP-compatible client.

No paid broker API subscriptions required. The server uses Playwright browser automation to capture data from the broker web apps after you log in via a visible Chrome window.


Features

  • Unified portfolio view across multiple brokers
  • Stocks, F&O, Mutual Funds, US Stocks, Gold — all asset classes
  • Network interception captures structured JSON from broker SPAs (more reliable than DOM scraping)
  • Persistent browser sessions — log in once per session expiry
  • Encrypted session storage (AES-256-GCM) in memory
  • Read-only — no order placement, no fund transfers
  • Graceful degradation — partial data returned if one broker fails

Broker Support Matrix

Feature Groww Zerodha Kite INDmoney
Stock Holdings Yes Yes Yes
F&O Positions Yes Yes —
Mutual Funds Yes Yes (Coin) Yes
US Stocks Yes — Yes
Gold / SGB Yes — Yes
Orders Yes Yes Yes
Login Method Email + OTP User ID + Password + TOTP Phone + OTP

Prerequisites

  • Node.js 18+
  • Google Chrome installed (Playwright uses your system Chrome via channel: 'chrome')
  • Claude Code or Claude Desktop (or any MCP client)

Installation

git clone  indian-broker-mcp
cd indian-broker-mcp
npm install
npx playwright install chromium
npm run build

Configuration

Copy the example env file and edit as needed:

cp .env.example .env

Environment Variables

Variable Default Description
SESSION_ENCRYPTION_KEY Auto-generated 32-byte hex key for AES-256-GCM session encryption
SESSION_TTL_HOURS 6 Session expiry time in hours
BROWSER_HEADLESS false Set true to run browsers headless (login still needs headed mode)
BROWSER_SLOW_MO 100 Delay in ms between Playwright actions (helps avoid detection)
BROWSER_DATA_DIR ./browser-data Persistent browser profile storage
LOG_LEVEL info debug, info, warn, or error
RECORDINGS_DIR ./recordings Output directory for learn_broker_navigation

Connecting to an MCP Client

Claude Code

claude mcp add indian-broker -- node /path/to/indian-broker-mcp/build/index.js

Claude Desktop

Add to your Claude Desktop config (~/.config/claude/claude_desktop_config.json on Linux, ~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

{
  "mcpServers": {
    "indian-broker": {
      "command": "node",
      "args": ["/path/to/indian-broker-mcp/build/index.js"]
    }
  }
}

Restart Claude Desktop after adding the configuration.

GitHub で README 全文を見る

インストール

npx playwright install chromium
MCP 初心者?mcpskill.org のガイドから始めましょう →

設定

{ "mcpServers": { "indian-broker": { "command": "node", "args": ["/path/to/indian-broker-mcp/build/index.js"] } } }