LONGBRIDGE OPENAPI

Real-time markets,
built for AI.

Real-time market data, quantitative research, and AI-powered analysis — through AI Skill, CLI, MCP, SDK and OpenAPI. One credential, every market, zero overhead.

4markets
US · HK · SG · CN
7SDKs
Python · Rust · Node · Go · Java · C · C++
100+endpoints
Quote · Trade · Research · News
$0OpenAPI access
No monthly fees
Longbridge CLI

AI-native command-line tool, covering every OpenAPI.

  • 130+ commands
    Market data, trading, fundamentals — all in your shell.
  • --format json output
    Pipe into jq, awk, or any AI agent's tool channel.
  • Multi-period candlesticks
    Daily, hourly, 15-min, 5-min, 1-min — all from one flag.
  • Portfolio P&L view
    Position breakdown with allocation drill-down.
  • OAuth 2.0 on SSH
    Works on headless servers and inside Docker.
CLI Documentation
macos · bash
$ brew install --cask longbridge/tap/longbridge-terminal
 
$ longbridge auth login
✓ Browser opened. Logged in as jason@longbridge.com
 
$ longbridge quote "TSLA.US""NVDA.US" "700.HK"
SYMBOL   LAST     CHANGE    VOLUME
TSLA.US   421.65   +2.31%   18.2M
NVDA.US   142.83   +1.18%   62.7M
700.HK    528.50   +0.86%    5.4M
 
$ longbridge portfolio --format json | jq '.positions[] | select(.pnl_pct > 5)'
120+commands
7output formats
3platforms
40msp50 query
AI Skill · 100+ packaged tools

Unlock market insights, deep research,
and intelligent trading for your AI.

With Longbridge Skill, your AI assistant can screen stocks, decode earnings, track insider moves, and place orders — all in plain conversation, no app-switching required.

Copy and send to any AI — it walks you through install:
Install Longbridge AI toolkit following the guide:
https://open.longbridge.com/skill/install.md

And complete login and test with a market data query.
— or via package manager —
$ npx skills add longbridge/skills -g
C Claude Code
O Codex
C Cursor
G Gemini
O OpenClaw
Z Zed
+ any Skill-compatible agent
Claude Code · skill: longbridge connected
Pull NVDA's daily chart for the past 6 months and tell me if I should hold my position.
used longbridge-kline · 6mo · daily
used longbridge-positions
NVDA broke its 50-day MA on heavy volume 3 sessions ago. Your 247 shares at avg $127.40 are up +12.1%. Concentration risk is medium — NVDA is 31% of your portfolio. Consider trimming if it hits $150.
Hosted MCP

Connect any AI assistant to live market data — no API keys.

Hosted HTTP MCP service with OAuth 2.1 authentication. Your AI coding assistant gets real-time quotes, account info, and trading — all in one connection.

Claude Code Codex Gemini Cursor Zed
MCP Documentation
~/projects/quant — claude
# One-line install for Claude Code
$ claude mcp add --transport http longbridge \
  https://openapi.longbridge.com/mcp
 
→ Opening browser for OAuth 2.1…
✓ Authenticated as jason@longbridge.com
✓ Connected · 130 tools available
 
# Verify the connection
$ claude mcp list
longbridge   ✓ ready   130 tools
OAuth 2.1 — browser opens automatically on first use. No API key needed.
OpenAPI SDK

Production-grade SDKs with real-time streaming.

7 SDKs built on a shared Rust core — subscribe to live data, place orders, and monitor positions with async/await patterns and built-in rate limiting.

get_quote.py
from longbridge.openapi import QuoteContext, Config, OAuthBuilder
 
oauth = OAuthBuilder("your-client-id").build(
lambda url: print("Visit:", url))
config = Config.from_oauth(oauth)
ctx = QuoteContext(config)
 
resp = ctx.quote(["AAPL.US", "TSLA.US", "NVDA.US", "GOOG.US"])
print(resp)
pippip3 install longbridge
Multi-Market
US · HK · SG · CN (SH/SZ) — stocks, ETFs, options, warrants.
USHKSGCN
Free & Paper Trading
No additional API charges. Paper trading with real market data, no securities account required.
$0 API charges
Real-time Push
WebSocket push for quotes, order depth, trades, and order status — <60 ms latency.
OAuth 2.0 + Async
Automatic token management with modern async/await patterns and built-in rate control.

Build smarter financial tools with real-time data and AI.