tossinvest-openapi-mcp
Click on "Install 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., "@tossinvest-openapi-mcpwhat are my current holdings?"
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.
tossinvest-openapi-mcp
Safe-by-default local stdio MCP server for the official Toss Securities / 토스증권 Open API.
This package is designed for developers who want read-only account, market, and order data in an MCP client, with optional order operations protected by multiple explicit safety gates.
Safety defaults
Uses only the official Toss Open API server:
https://openapi.tossinvest.comStarts without credentials;
auth_statusreports missing configuration instead of crashing.Keeps OAuth access tokens in memory only.
Redacts API keys, secrets, bearer tokens, account headers, and account numbers from tool output/errors.
Trading is disabled by default.
Order tools default to
dryRun=true.Real create/modify/cancel operations require
ENABLE_TRADING=trueplus the operation-specific gate.Confirmation is required by default.
Default max order amounts are
0KRW and0USD.BLOCKED_SYMBOLStakes precedence overALLOWED_SYMBOLS.
Related MCP server: kiwoom-mcp
Install and run
npm install
npm run build
npm testRun locally:
TOSS_API_KEY=... TOSS_SECRET_KEY=... node dist/index.jsDo not put real secrets in committed files. Prefer passing env vars from your local shell or MCP client secret manager.
MCP client configuration example
{
"mcpServers": {
"tossinvest": {
"command": "node",
"args": ["/absolute/path/to/tossinvest-openapi-mcp/dist/index.js"],
"env": {
"TOSS_API_KEY": "${TOSS_API_KEY}",
"TOSS_SECRET_KEY": "${TOSS_SECRET_KEY}",
"TOSS_ACCOUNT_SEQ": "${TOSS_ACCOUNT_SEQ}"
}
}
}
}Environment variables
Name | Default | Purpose |
| unset | Toss Open API client id / API key. |
| unset | Toss Open API client secret. |
| unset | Optional default account sequence for account-scoped tools. |
|
| Global gate for any real order operation. |
|
| Gate for real order create. |
|
| Gate for real order modify. |
|
| Gate for real order cancel. |
|
| Requires exact confirmation text for real order operations. |
|
| Maximum allowed calculated KRW order amount. |
|
| Maximum allowed calculated USD order amount. |
| unset | Optional comma-separated allow list. |
| unset | Optional comma-separated block list; always wins over allow list. |
Confirmation text for real order operations:
I understand this may place a real Toss Securities orderTools
Read-only tools:
auth_statusaccountsholdingspricesorderbooktradesprice_limitscandlesstock_infostock_warningsexchange_ratemarket_calendarorders_openorders_closedorder_detailbuying_powersellable_quantitycommissions
Trading tools:
order_validate— checks local gates only and never calls Toss order POST endpoints.order_create— defaults to dry-run; real execution requires all create gates.order_modify— defaults to dry-run; real execution requires all modify gates.order_cancel— defaults to dry-run; real execution requires all cancel gates.
Endpoint mapping
Tool | Method/path | Side effect |
|
| Token check only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
|
| Read-only |
| Local gate evaluation only | No Toss order POST |
|
| Real order only after all gates pass |
|
| Real order modification only after all gates pass |
|
| Real order cancellation only after all gates pass |
Trading safety examples
Dry-run validation:
{
"request": {
"symbol": "005930",
"side": "BUY",
"orderType": "LIMIT",
"quantity": "1",
"price": "70000",
"currency": "KRW"
}
}Real create requires all of the following:
ENABLE_TRADING=true
ENABLE_ORDER_CREATE=true
REQUIRE_CONFIRMATION=true
MAX_ORDER_KRW=100000
ALLOWED_SYMBOLS=005930And the tool call must include:
{
"dryRun": false,
"confirmation": "I understand this may place a real Toss Securities order",
"request": {
"symbol": "005930",
"side": "BUY",
"orderType": "LIMIT",
"quantity": "1",
"price": "70000",
"currency": "KRW"
}
}Official endpoint mapping
The implementation is intentionally thin and maps tools to official Toss Open API paths:
OAuth:
POST /oauth2/tokenMarket/account/order data:
/api/v1/...paths fromhttps://openapi.tossinvest.com/openapi-docs/latest/openapi.jsonOrder create/modify/cancel: official
/api/v1/ordersPOST paths only, guarded locally before any POST is attempted.
Development
npm install
npm test
npm run lint
npm run audit:prodThe required test suite uses Node's built-in test runner and mocked fetch calls. It does not require real Toss credentials and does not call live order endpoints.
Publication hygiene
.gitignoreexcludes.env,.env.*, logs, coverage,node_modules, and build output..npmignoreexcludes local env files, logs, coverage, internal handoff/QA notes, and local run artifacts.package.jsonfilesonly publishesdist, public docs,.env.example, and changelog/security/license files.
Disclaimer
This software is not investment advice and does not implement trading strategy, rebalancing, optimization, or automated trading loops. Order tools can place real financial orders only when explicitly enabled and used with valid Toss credentials; use at your own risk.
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/EthanKlocked/tossinvest-openapi-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server