JungHoonGhae/tossinvest-cli
About
Use it in the terminal and with AI, with 30+ features not available in the official API. An unofficial Toss Securities CLI·MCP.
AI & Machine LearningMeasured star growth
- in 24h
- 0
- in 7 days
- +1
- in 15 days
- +1
- in 1 month
- Collecting history
Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.
README.en.md
Original한국어 · English
tossinvest-cli
Give your AI investment data beyond the official API.
From stock discovery to assets, profit, taxes, and watchlists — one tossctl.
Quick Start · Beyond the API · Connect AI · Before Trading · Docs
[!WARNING] This is not an official Toss Securities product. Features outside the official Open API use Toss Securities' internal web API unofficially, may violate its Terms of Service, and can change without notice. You are responsible for account restrictions, losses, and other consequences of use.
Go Beyond the Official API with tossctl
tossctl brings 30+ capabilities beyond the official API into your AI and automation. Discover stocks, track changes in your assets, and review tax records in one place.
Compare capabilities
| What else you can do | Official Open API | What tossctl connects |
|---|---|---|
| Discover and research stocks | Not supported | Toss AI signals, reasons for price moves, screening, sector analysis |
| Follow news and investment events | Not supported | Holdings and watchlist news, earnings calls, key economic releases |
| Review assets and performance | Not supported | All-account totals, valuation history, dividends, realized profit by period |
| Check taxes and other income | Not supported | Overseas capital gains, deposit interest, expected stock-lending income |
| Manage your investing setup | Not supported | Watchlist folders, price alerts, hidden holdings, accumulation-plan lookup |
Go from “What's my balance?” to “Summarize my asset changes, dividends received, and holdings news.” Ask your AI for the information you used to check separately in the app.
These extra features use WTS, Toss Securities' internal web API. The scope is Toss Securities, excluding general Toss banking and card spending. Compare all supported features →
Quick Start
macOS / Linux:
curl -fsSL https://raw.githubusercontent.com/JungHoonGhae/tossinvest-cli/main/install.sh | sh
tossctl auth login --phone
tossctl account summary --output json
Enter your name, date of birth and phone number and the Toss app receives an approval notification. Approve it, then approve Keep this device signed in. The details go only to the Toss Securities sign-in page and are not saved. For the browser QR login use tossctl auth login; for a link, tossctl auth login --link.
Windows · Homebrew · Official API setup
Install in Windows PowerShell, then run the login and query commands above:
irm https://raw.githubusercontent.com/JungHoonGhae/tossinvest-cli/main/install.ps1 | iex
To connect an official Open API key (after the web login):
tossctl openapi setup # reuse the existing key, enter a saved secret, or issue a new key
tossctl openapi status
If you already have the key and secret, tossctl openapi login registers them directly.
See the installation guide for Homebrew and source builds. Run tossctl doctor --report to diagnose authentication or connection problems.
Demo — installation through the first query
Put It to Work
# Explore the market
tossctl quote flows A005930
tossctl market signals
# Review your dividends
tossctl portfolio dividends
# Include completed and canceled orders from earlier months
tossctl orders completed --all-dates --size 50
# Pass holdings to your scripts
tossctl portfolio positions --output json
The flows command above uses WTS; the official API's investor-trading query is also supported separately. See the command reference for AI signals, dividends, and more.
Live streams · API monitoring · Local history
# Assets across accounts and a holdings briefing
tossctl account overview
tossctl portfolio briefing
# Stream trades and watch for API changes
tossctl stream --trade A005930
tossctl monitor api # read-only checks; exit 0 pass, 1 fail
Use tossctl history sync to preview a collection of holdings and transactions. After saving, history list, history search, and history compare work offline.
Select only the JSON fields you need with --fields symbol,quantity --compact. History and briefing guide →
Use It with AI
Connect your installed tossctl to an AI app and ask in plain language. Claude Code, Codex, and Cursor support MCP connections.
Register MCP with Claude Code:
claude mcp add tossctl tossctl mcp
Ask your connected agent:
Summarize my asset changes and dividends received, and show news about my holdings.
See the MCP guide for Codex, Cursor, and other apps.
Connect another AI app — MCP settings
Add this configuration if your AI app supports this MCP format:
{
"mcpServers": {
"tossinvest": { "command": "tossctl", "args": ["mcp"] }
}
}
Demo — connect MCP to an AI agent
Before You Place an Order
[!IMPORTANT] Live trading is disabled by default. Agents preview orders. A human must review, approve, and submit each live order.
tossctl order preview --symbol AAPL --side buy --qty 1 --price 200
# Preview only. A human must review the result and confirmation token before placing an order.
- Check the order: review the symbol, quantity, and price in the preview, then approve and submit it yourself.
- Watchlist and alert changes: check what will change before approving.
- Unclear submission results: check order status before trying again.
US-options paper trading — experimental
This feature is still stabilizing and hidden by default. You must also meet Toss Securities' eligibility requirements. Paper balances and orders stay separate from live trading, and paper approval never authorizes a live order. See support scope for setup and limits.
See the safety guide for enabling trading and confirming orders.
Documentation
| Document | Covers |
|---|---|
| Quick start | Install through first query |
| Command reference | All CLI commands and examples |
| Support scope | Official API and WTS feature matrix |
| Connect an AI app | Claude Code, Codex, and Cursor setup |
| Safety guide | Settings and checks before live orders |
Report problems or suggestions in Issues. For security reports, see SECURITY.md.
Sponsors
For sponsorship and brand placement, contact [email protected].
1 person backs my open-source work (one-time included). Sponsorship funds my projects, tossinvest-cli included.
Contributors
Thanks to everyone who has helped build tossinvest-cli. See CONTRIBUTING.md to join in.
Star History
License
Explore related projects
Loading…

