idx-market-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@idx-market-mcpCheck the orderbook and bandarmology for TLKM"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
IDX Market MCP (idx-market-mcp)
Institutional-grade Model Context Protocol (MCP) server for Indonesian Stock Exchange (IDX) equities.
idx-market-mcp bridges AI agents (Claude Desktop, Cursor, Hermes Agent) to the Indonesian capital markets. It combines public market telemetry, real-time Level 2 orderbook depth, institutional bandarmology (broker accumulation/distribution), automated chart pattern recognition, and quantitative risk budgeting into a single, token-efficient Python server.
š Key Capabilities
Unified Multi-Action Gateway (
idx_stockbit):Access orderbook depth, broker summaries, audited financials, corporate action dividends, and insider disclosures through a single tool schema (~150 input tokens), eliminating tool-definition bloat across conversation turns.
Institutional Bandarmology:
Real-time foreign net flows and broker summary breakdown (Top-1, Top-3, Top-5 broker accumulation/distribution status).
Full Level 2 Orderbook Depth:
10 Bid & 10 Ask depth ladder with lot volume and institutional support/resistance wall detection.
Algorithmic Chart Pattern Recognition:
Mathematical detection of local extrema (
scipy.signal.argrelextrema) and trendline regression to identify triangles, channels, and coils, complete with Bulkowski breakout probabilities and auto-generated candlestick charts (mplfinance).
Defensive Financial Sanitization:
Automatic currency mismatch normalization for USD-reporting issuers (
KRAS,AMMN,MEDC,ADRO), thin-equity ROE clamping, and solvency violation locks ($\text{DER} > 1.5\times$).
Quantitative Risk Budgeting & Two-Tranche Orders:
Anti-cluster sector concentration ceilings (max 50% per sector) and mathematical 2-tranche limit order calculators ready for retail broker execution (e.g. Ajaib, Stockbit).
Related MCP server: Baguskto Saham
šļø Architecture
āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā AI Agent / Client ā
ā (Claude Desktop, Cursor, Hermes Agent, LLM) ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā Model Context Protocol (JSON-RPC / stdio)
āāāāāāāāāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāā
ā idx-market-mcp ā
ā ā
ā āāāāāāāāāāāāāāāāāāāāāāāāā āāāāāāāāāāāāāāāāāāāāāāāāā ā
ā ā Unified Gateway ā ā Quantitative Guards ā ā
ā ā (idx_stockbit) ā ā (Sanitize/Sector/Lot) ā ā
ā āāāāāāāāāāāāā¬āāāāāāāāāāāā āāāāāāāāāāāāā¬āāāāāāāāāāāā ā
ā ā ā ā
ā āāāāāāāāāāāāā¼āāāāāāāāāāāā āāāāāāāāāāāāā¼āāāāāāāāāāāā ā
ā ā Pattern Recognition ā ā Free Quote Fallback ā ā
ā ā (scipy + mplfinance) ā ā (Yahoo Finance .JK) ā ā
ā āāāāāāāāāāāāāāāāāāāāāāāāā āāāāāāāāāāāāāāāāāāāāāāāāā ā
āāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāā
ā Session Bearer Token ā Public OHLCV
āāāāāāāāāāāāāāāā¼āāāāāāāāāāāā āāāāāāāāāāāāā¼āāāāāāāāāāāāāā
ā Stockbit Exodus API ā ā Yahoo Finance Charts ā
ā (Orderbook L2 / Bandar) ā ā (.JK Tickers) ā
āāāāāāāāāāāāāāāāāāāāāāāāāāāā āāāāāāāāāāāāāāāāāāāāāāāāāāāš ļø Tool Catalog (11 Active Tools)
Tool Name | Type | Description |
| Gateway | Single unified action tool: |
| Market L2 | 10-level Bid & Ask ladder, total queue lots, ARA/ARB thresholds. |
| Flow | Broker summary, institutional flow in IDR, Top 1/3/5 broker actions. |
| Fundamental | Audited IDR balance sheet, Piotroski F-Score (1-9), DER, ROE, CFO, DPR. |
| Corp Action | Historical and upcoming dividend calendar (cum, ex, payment dates, IDR value). |
| Corporate | Major shareholder and director/commissioner transaction disclosures. |
| Technical | Algorithmic pattern detection, regression slopes, and annotated PNG chart rendering. |
| Price Feed | Real-time quote, intraday range, volume in shares and lots. |
| Risk Guard | Normalizes USD reporting mismatches, thin-equity ROE distortions, and leverage traps. |
| Risk Guard | Enforces 50% single-sector portfolio ceiling (e.g. anti-cluster bank guard). |
| Execution | Computes disciplined 2-tranche limit orders (Tranche 1 immediate + Tranche 2 reserve). |
š Quickstart
1. Installation
Clone and install dependencies via pip or uv:
git clone https://github.com/mpandudc/idx-market-mcp.git
cd idx-market-mcp
# Using uv (recommended)
uv venv
source .venv/bin/activate
uv pip install -e .
# Or using standard pip
pip install -e .2. Authentication (Optional for Deep Data)
Basic market quotes, sector concentration checks, and chart pattern recognition work without credentials (using public feeds).
To unlock Level 2 Orderbook depth, Bandarmology, and audited Keystats, provide a Stockbit Bearer token via environment variable:
export STOCKBIT_BEARER_TOKEN="eyJhbGciOiJSUzI1NiIs..."(Token can be obtained once from your browser DevTools Authorization: Bearer header on stockbit.com).
š Client Configuration
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"idx-market": {
"command": "python",
"args": ["-m", "idx_market_data_mcp.server"],
"env": {
"STOCKBIT_BEARER_TOKEN": "YOUR_BEARER_TOKEN_HERE"
}
}
}
}Cursor
Add to .cursor/mcp.json:
{
"mcpServers": {
"idx-market": {
"command": "python",
"args": ["-m", "idx_market_data_mcp.server"],
"env": {
"STOCKBIT_BEARER_TOKEN": "YOUR_BEARER_TOKEN_HERE"
}
}
}
}Hermes Agent (~/.hermes/config.yaml)
mcp_servers:
idx_market:
command: /path/to/idx-market-mcp/.venv/bin/python
args:
- -m
- idx_market_data_mcp.server
enabled: true
env:
STOCKBIT_BEARER_TOKEN: "YOUR_BEARER_TOKEN_HERE"š Example Prompts
"Cek orderbook dan bandarmology saham MYOR hari ini"
"Analisis chart pattern SMSM pada timeframe 1d dan render gambarnya"
"Hitung tiket limit order 2-tranche untuk alokasi Rp 12.000.000 di saham BBCA"
"Audit portofolio saya: apakah boleh menambah BBNI jika sudah memegang BBCA, BMRI, dan BBRI?"
āļø Disclaimer
This software is developed strictly for educational, academic, and quantitative research purposes. It is not affiliated with, endorsed by, or sponsored by PT Bursa Efek Indonesia (IDX) or PT Stockbit Sekuritas Digital. Automated data access may be subject to the terms of service of upstream providers. Use responsibly on your own personal accounts.
š License
MIT License ā Copyright (c) 2026 Muhammad Pandu Dwi Cahyo.
This server cannot be deployed
Maintenance
Related MCP Connectors
Data saham Indonesia (IDX) untuk AI: harga, teknikal, screener, deteksi bandar, sektor, earnings.
US stock market data for AI agents: SEC filings, financials, insider trades, 13F, options, macro.
Read-only China A-share data for AI agents: market, limit-up, capital flow and disclosures.
Evidence-backed capital-change intelligence and sourced financial data for AI agents
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceProvides real-time Indonesian stock market (IDX) data including prices, technical indicators, fundamental analysis, and trading signals optimized for the Indonesian market through the Model Context Protocol.7MIT
- AlicenseAqualityDmaintenanceEnables access to Indonesian Stock Exchange (IDX) data with comprehensive historical data from 2019-2025 for 958 stocks, including real-time market overview, technical analysis, sector performance, and stock comparison capabilities.920 npm42MIT
- AlicenseNot gradedqualityDmaintenanceConnects AI assistants to real-time Indian stock market data with 34 tools for search, screening, analysis, portfolio tracking, and market insights across all NSE and BSE stocks.93 npm80MIT
- AlicenseAqualityCmaintenanceEnables AI assistants to access Indonesian stock market data, including real-time quotes, historical data from 2019, and technical analysis for 958 IDX-listed stocks.920 npmMIT