Stoqey Interactive Brokers Documentation Hub
Documentation portal for @stoqey/ib (Low-level TWS API SDK) and @stoqey/ibkr (High-level wrapper library).
Welcome to the documentation portal for Stoqey's Interactive Brokers Node.js & TypeScript client suite.
Which Package Should You Use?
We maintain two packages depending on your application requirements and architectural style:
graph TD
UserApp[Your Node.js Application] --> Choice{What level of control do you need?}
Choice -->|High-Level Abstractions & Auto-Caching| IBKR["@stoqey/ibkr (High-Level Wrapper)"]
Choice -->|Low-Level Control or Porting TWS Java Code| IB["@stoqey/ib (Low-Level SDK)"]
IBKR -->|Built on top of| IB
IB -->|TCP Sockets| TWS[IB Gateway / TWS Workstation]Detailed Comparison Matrix
| Criteria | @stoqey/ib | @stoqey/ibkr |
|---|---|---|
| Primary Goal | Direct TypeScript port of official TWS Java SDK v10.32.01 | Developer-friendly high-level wrapper library |
| API Style | Event-Driven (IBApi) or RxJS 7 (IBApiNext) | Singleton Managers (AccountSummary, Portfolios, Orders, MarketDataManager) |
| Account State | Manual request & event teardown | Automatic background balance & position caching |
| Order Tracking | Manual status callback handling | Built-in orders & trades history with IBKR_SAVE_TRADE fill events |
| Market Data Feeds | Manual ticker management | Simplified contract lookup, bar streaming, & tick aggregation |
| Special Features | 1:1 match with official TWS Java SDK specifications | Market-Data-Only mode (IBKR_MD_ONLY) & contract allowlisting (IBKR_CONTRACTS) |