K-Stock 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., "@K-Stock MCP Show me Samsung Electronics' current price and 1-month daily chart"
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.
K-Stock MCP
A read-only Model Context Protocol server that plugs the Korean stock market into Claude and other MCP agents: quotes and charts from the KIS Open API, disclosures and financials from OpenDART, and an IPO (공모주) schedule with an equal-allocation (균등배정) calculator.
Token handling for KIS is automatic: issued once, cached on disk (24 h validity), paper (mock) and real environments kept apart, paper is the default.
Data and calculations only. No order tools. No buy/sell recommendations.
stdio transport, runs with
uvx, no hosted service: your keys never leave your machine.
Disclaimer. Everything this server returns is informational data, not investment advice. It is not an investment advisory or discretionary service, and it does not recommend securities. Investment decisions and their consequences are entirely your own responsibility. Data may be delayed, incomplete or wrong. Not affiliated with Korea Investment & Securities or the Financial Supervisory Service.
Tools (v0.1, all read-only)
Tool | What it does | Source |
| Company name or code to code, market and type | KIS public symbol master files |
| Price, day range, volume, PER/PBR/EPS/BPS, 10-level order book | KIS |
| Daily/weekly/monthly/yearly candles, optionally adjusted | KIS |
| Holdings and account summary (paper by default) | KIS |
| Upcoming/ongoing IPOs: subscription dates, price, underwriters, optional equal-allocation estimate | OpenDART equity registration statements |
| Recent filings for a company, with DART viewer links | OpenDART |
| Key accounts (assets, liabilities, equity, revenue, operating income, net income) | OpenDART |
Every response carries a short notice field with the disclaimer, and the server instructions tell the model not to present output as advice.
Related MCP server: krx-cli
Install in 3 steps
1. Get keys (both free)
KIS Open API app key and secret from apiportal.koreainvestment.com. Start with paper (mock-trading) keys; they are separate from real keys.
OpenDART key from opendart.fss.or.kr.
2. Install uv and check the server starts:
uvx kstock-mcp --version3. Add it to your client
Claude Code:
claude mcp add kstock \
--env KIS_ENV=paper \
--env KIS_APP_KEY=your-kis-app-key \
--env KIS_APP_SECRET=your-kis-app-secret \
--env KIS_ACCOUNT_NO=12345678-01 \
--env DART_API_KEY=your-dart-api-key \
-- uvx kstock-mcpClaude Desktop (claude_desktop_config.json; use the full path to uvx if the app cannot find it):
{
"mcpServers": {
"kstock": {
"command": "uvx",
"args": ["kstock-mcp"],
"env": {
"KIS_ENV": "paper",
"KIS_APP_KEY": "your-kis-app-key",
"KIS_APP_SECRET": "your-kis-app-secret",
"KIS_ACCOUNT_NO": "12345678-01",
"DART_API_KEY": "your-dart-api-key"
}
}
}
}You only need the keys for the tools you use: DART tools need DART_API_KEY; KIS tools need the KIS variables; get_balance also needs the account number; search_stock needs no key.
Alternative: pre-PyPI or development version. To run straight from GitHub instead of PyPI, replace uvx kstock-mcp with uvx --from git+https://github.com/ez2sarang/kstock-mcp kstock-mcp (in Claude Desktop: "args": ["--from", "git+https://github.com/ez2sarang/kstock-mcp", "kstock-mcp"]).
Configuration
Variable | Meaning |
|
|
| KIS credentials for the chosen environment |
|
|
| OpenDART key |
| Cache directory (default |
IPO schedule and equal allocation
Source choice: get_ipo_schedule uses OpenDART equity registration statements (증권신고서, 지분증권) because it is the official, documented, keyed API, so there is no scraping and no robots.txt/terms question. Pre-listing issuers that filed one are treated as IPO candidates. Dates, price text and underwriters come from the latest filing or amendment and can still change before book-building ends. The filing does not contain retail allocation ratios or subscriber counts.
Pass expected_subscribers (and optionally general_ratio_pct, equal_ratio_pct, min_subscription_shares, deposit_rate_pct) to get an equal_allocation_estimate per IPO. The calculation is a pure function (kstock_mcp.allocation.estimate_equal_allocation) and the response lists its formula and assumptions:
general_shares = floor(total_shares * general_ratio_pct / 100)
equal_shares = floor(general_shares * equal_ratio_pct / 100)
guaranteed_each = floor(equal_shares / expected_subscribers)
leftover (lottery) = equal_shares mod expected_subscribersReal allocations are decided per underwriter, so treat the output as a rough estimate.
Privacy
The server runs locally over stdio. It sends your KIS key/secret to the KIS Open API, your DART key to OpenDART, and downloads KIS's public symbol master files. It has no telemetry and no server of its own. Keys are read from environment variables only, are never written to logs, and error messages never include request URLs.
Development
git clone https://github.com/ez2sarang/kstock-mcp && cd kstock-mcp
uv sync
uv run pytest # all HTTP is mocked; no network, no keys neededDependencies are pinned to exact versions in pyproject.toml and uv.lock. The server uses mcp 2.x, where the former FastMCP class is MCPServer.
Roadmap
v0.2 and later: condition search, portfolio report, IPO alerts. This server stays read-only: order placement is not planned.
License
Available Tools
7 toolsget_balanceARead-onlyIdempotent
Holdings and account summary for the configured KIS account (paper by default). Read-only.
Inputs: no named parameters. Returns: object
get_disclosureARead-onlyIdempotent
Recent DART disclosures for a company, newest first, with links to the DART viewer.
Inputs: symbol (required), days, kind, limit. Returns: object
get_financialsCRead-onlyIdempotent
Key financial statement accounts (assets, liabilities, equity, revenue, operating income, net income) from DART.
Inputs: symbol (required), year, report, consolidated. Returns: object
get_ipo_scheduleARead-onlyIdempotent
Upcoming/ongoing IPO (공모주) schedule from OpenDART equity filings: subscription dates, price text, underwriters, and an optional equal-allocation estimate whose formula and assumptions are in the response.
Inputs: limit, days_back, equal_ratio_pct, deposit_rate_pct, +3 more. Returns: object
get_ohlcvARead-onlyIdempotent
Historical candles (open/high/low/close/volume), oldest first. Up to ~300 rows per call; see 'truncated'.
Inputs: code (required), period, adjusted, end_date, +1 more. Returns: object
get_quoteARead-onlyIdempotent
Current price, day range, volume, valuation ratios and order book for a stock (KIS, KRX market).
Inputs: code (required), include_orderbook. Returns: object
search_stockARead-onlyIdempotent
Find Korean listed securities (KOSPI/KOSDAQ/KONEX) by name or code. Returns code, name, market, type.
Inputs: query (required), limit. Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 7 tools
Each tool targets a clearly distinct data type or resource: account balance, disclosures, financials, IPO schedule, historical candles, current quote, and symbol lookup. The closest pair (get_ohlcv vs get_quote) is well separated by 'historical candles' versus 'current price', so an agent can select correctly without guessing.
All names follow a consistent snake_case verb_noun pattern (get_balance, get_disclosure, get_financials, get_ipo_schedule, get_ohlcv, get_quote, search_stock). The single search_ prefix is a meaningful and standard distinction from the get_ lookup family rather than an inconsistency.
Seven tools is well scoped for a read-only Korean market data server. Each tool covers a distinct data need (quote, candles, financials, disclosures, IPO calendar, lookups, account) and none appear redundant or filler.
The read-only data surface is broad and coherent: discovery (search_stock), pricing (get_quote, get_ohlcv), fundamentals (get_financials, get_disclosure, get_ipo_schedule), and account state (get_balance). Minor gaps remain, such as order/trade history or watchlist management, but these are plausibly out of scope for a read-only server.
Maintenance
Related MCP Connectors
Korean company facts in English for AI agents: ~830 KOSPI-listed companies (DART profiles, KRW financials, recent filings) and ~110,000 corporate public procurement suppliers (12-month KONEPS contract awards), plus live National Tax Service business status checks. 4 tools, keyless, read-only.
FinBridge is a hosted MCP server for Korean company disclosures, read in English. DART filings and normalized financial statements, business segments, insider reports and 13F holdings, with US, Japanese and European filers on the same schema for comparison. Search a company by its registered English name or its Korean name. Every answer names the filing, the receipt number and the date. Korean price delivery is planned and not currently served. Docs: https://www.gronox.kr/docs
Search company disclosures and financial statements from the Korean market. Retrieve stock profile…
Market analyst tools + AI agent: crypto, US equities, options, Korea, fundamentals, macro, backtests
Related MCP Servers
- FlicenseAqualityDmaintenanceMCP server that provides Korean stock market data including indices, top gainers, stock quotes, news, fundamentals, and buy recommendations. Enables LLMs to access real-time and historical Korean stock information.6-
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to query real-time and historical Korean stock market data from KRX (Korea Exchange) including indices, stocks, ETFs, bonds, derivatives, and commodities via MCP tools and resources.27 npm1MIT

pykrx-mcpofficial
AlicenseNot gradedqualityDmaintenanceProvides Korean stock market data (KOSPI, KOSDAQ, KONEX) including prices, fundamentals, investor trading, short selling, and indices via MCP protocol, enabling natural language queries from AI agents like ChatGPT and Claude.57 PyPI3MIT- FlicenseNot gradedqualityDmaintenanceProvides real-time Korean stock market data, including stock prices, rankings, investor trends, and derivatives, via the Korea Investment & Securities OpenAPI. Enables AI models to query and analyze Korean financial data through natural language.-