Tiger Quant Open Platform C++ SDK Complete Skill Set / Complete AI skill set for Tiger Brokers OpenAPI (C++)
Safety Warning / Safety Warning: Trading involves real money. When generating trading code, default tosimulated account, unless the user explicitly requests live trading. Before placing a live order, you must confirm the order details with the user. Trading involves real money. Default to Paper Trading when generating trading code. Always confirm order details before live orders.
- Docs: https://docs.itigerup.com/docs/prepare
- GitHub: https://github.com/tigerfintech/openapi-cpp-sdk
- C++14, CMake 3.15+, cross-platform (macOS/Linux/Windows)
Language Rules / Language Rules
Reply automatically based on the user's input language. Keep technical terms (code, API names, parameter names) in their original form without translation. Reply in the user's language. Keep technical terms (code, API names, parameters) as-is.
Reference Guides
- Quickstart — Build setup, CMake, config, client creation
- Market Data — Real-time quotes, K-lines, depth, options, futures
- Trading — Place/modify/cancel orders, positions, assets
- Real-time Push — WebSocket push for quotes, orders, positions
- Account Management — Account list, assets, positions, fund transfer, deposit/withdrawal
- Options Trading — Option chain, expirations, Greeks, multi-leg strategies
Quick Start
#include "tigerapi/client_config.h"
#include "tigerapi/quote_client.h"
#include "tigerapi/trade_client.h"
using namespace TIGER_API;
int main() {
// 1. 创建配置 / Create config
ClientConfig config(false, "path/to/config/");
// 2. 查询行情 / Query quotes
QuoteClient qc(config);
value symbols = value::array();
symbols[0] = value::string(U("AAPL"));
symbols[1] = value::string(U("TSLA"));
value quotes = qc.get_brief(symbols);
ucout << quotes << std::endl;
// 3. 交易操作 / Trading
TradeClient tc(config);
value orders = tc.get_orders();
ucout << orders << std::endl;
return 0;
}
When to Use Each Reference
| Task | Reference |
|---|---|
| First time setup, build, CMake, auth config | quickstart.md |
| Get stock/option/future quotes, K-lines | quote.md |
| Place/modify/cancel orders, check positions/assets | trade.md |
| Real-time streaming data via WebSocket | push.md |
| Account info, assets, fund transfer, deposit/withdrawal | account.md |
| Option chain, Greeks, expirations, multi-leg orders | option.md |
Common Symbols / Common Symbols Quick Reference
Hong Kong Stocks HK
| Common Name | Symbol Symbol |
|---|---|
| Tencent | 00700 |
| Alibaba | 09988 |
| Meituan | 03690 |
| Xiaomi | 01810 |
US Stocks US
| Common Name | Symbol Symbol |
|---|---|
| Apple / Apple | AAPL |
| Tesla / Tesla | TSLA |
| NVIDIA / NVIDIA | NVDA |
| Microsoft / Microsoft | MSFT |
| Google / Google | GOOGL |
| Amazon / Amazon | AMZN |
| Meta | META |
| Tiger Brokers / TIGR | TIGR |
| S&P 500 ETF / SPY | SPY |
| Nasdaq ETF / QQQ | QQQ |