webull-openapi-mcp 1.2.2__tar.gz → 1.2.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/.env.example +1 -1
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/PKG-INFO +29 -38
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/README.md +27 -36
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/mcpb/build_manifest.py +1 -1
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/pyproject.toml +2 -2
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/server.json +2 -2
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_fundamental_screener_registration.py +3 -3
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_sdk_client.py +2 -2
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/__init__.py +1 -1
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/cli.py +1 -1
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/constants.py +3 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/formatters.py +156 -64
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/region_config.py +5 -33
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/sdk_client.py +1 -19
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/option_order.py +41 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/order.py +59 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/stock_order.py +35 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/.github/workflows/pypi-ci.yml +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/.gitignore +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/DISCLAIMER.md +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/LICENSE +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/mcpb/.mcpbignore +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/mcpb/build.sh +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/mcpb/src/server.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/__init__.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_account_tools.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_audit.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_cli.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_config.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_errors.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_formatters.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_fundamental_tools.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_guards.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_instrument_tools.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_market_data_tools.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_property_audit.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_property_config.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_property_formatters.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_property_guards.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_property_sdk.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_property_server.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_screener_tools.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/tests/test_stock_order_tools.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/__main__.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/audit.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/config.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/errors.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/guards.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/server.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/__init__.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/__init__.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/crypto.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/event.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/financial.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/fundamental.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/futures.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/option.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/screener.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/stock.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/market_data/watchlist.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/__init__.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/account.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/assets.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/crypto_order.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/event_order.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/futures_order.py +0 -0
- {webull_openapi_mcp-1.2.2 → webull_openapi_mcp-1.2.4}/webull_openapi_mcp/tools/trading/instrument.py +0 -0
|
@@ -20,7 +20,7 @@ WEBULL_APP_SECRET=
|
|
|
20
20
|
# Set to 'prod' for live trading (use with caution)
|
|
21
21
|
# WEBULL_ENVIRONMENT=uat
|
|
22
22
|
|
|
23
|
-
# Region ID: us, hk, jp, sg,
|
|
23
|
+
# Region ID: us, hk, jp, sg, my, uk, mx, br, or za
|
|
24
24
|
# Default: us
|
|
25
25
|
# WEBULL_REGION_ID=us
|
|
26
26
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: webull-openapi-mcp
|
|
3
|
-
Version: 1.2.
|
|
3
|
+
Version: 1.2.4
|
|
4
4
|
Summary: MCP Server for Webull OpenAPI - enables AI assistants to securely access Webull trading and market data
|
|
5
5
|
Project-URL: Homepage, https://github.com/webull-inc/webull-openapi-mcp
|
|
6
6
|
Project-URL: Repository, https://github.com/webull-inc/webull-openapi-mcp
|
|
@@ -20,7 +20,7 @@ Requires-Python: <3.13,>=3.10
|
|
|
20
20
|
Requires-Dist: click
|
|
21
21
|
Requires-Dist: fastmcp==3.0.2
|
|
22
22
|
Requires-Dist: python-dotenv
|
|
23
|
-
Requires-Dist: webull-openapi-python-sdk==
|
|
23
|
+
Requires-Dist: webull-openapi-python-sdk==3.0.0
|
|
24
24
|
Provides-Extra: dev
|
|
25
25
|
Requires-Dist: hypothesis; extra == 'dev'
|
|
26
26
|
Requires-Dist: pytest; extra == 'dev'
|
|
@@ -49,7 +49,7 @@ See [DISCLAIMER.md](DISCLAIMER.md) for the full disclaimer.
|
|
|
49
49
|
|
|
50
50
|
## Features
|
|
51
51
|
|
|
52
|
-
- **Multi-Region Support** — US, HK, JP, SG,
|
|
52
|
+
- **Multi-Region Support** — US, HK, JP, SG, MY, UK, MX, BR, and ZA regions with region-specific order types, trading sessions, and validation
|
|
53
53
|
- **Market Data** — Real-time snapshots, tick data, quotes (depth), footprint, and OHLCV bars for stocks, options, futures, crypto, and event contracts
|
|
54
54
|
- **NOII Data** — Net Order Imbalance Indicator bars and snapshots for US stock opening/closing auctions
|
|
55
55
|
- **Screener** — Top gainers/losers, most active, market sectors, high dividend, and 52-week high/low rankings
|
|
@@ -146,12 +146,9 @@ Here are some prompts you can use with your AI assistant:
|
|
|
146
146
|
- HK: [developer.webull.hk](https://developer.webull.hk/apis/home)
|
|
147
147
|
- JP: [developer.webull.co.jp](https://developer.webull.co.jp/)
|
|
148
148
|
- SG: [developer.webull.com.sg](https://developer.webull.com.sg/apis/home)
|
|
149
|
-
- TH: [developer.webull.co.th](https://developer.webull.co.th/apis/home)
|
|
150
149
|
- MY: [developer.webull.com.my](https://developer.webull.com.my/apis/home)
|
|
151
150
|
- UK: [developer.webull-uk.com](https://developer.webull-uk.com/apis/home)
|
|
152
|
-
- EU: [developer.webull.eu](https://developer.webull.eu/apis/home)
|
|
153
151
|
- ZA: [developer.webull.co.za](https://developer.webull.co.za/apis/home)
|
|
154
|
-
- AU: [developer.webull.com.au](https://developer.webull.com.au/apis/home)
|
|
155
152
|
- MX: [developer.webull.com.mx](https://developer.webull.com.mx/apis/home)
|
|
156
153
|
- BR: [developer.webull.com.br](https://developer.webull.com.br/apis/home)
|
|
157
154
|
2. **API Credentials** — Obtain your `App Key` and `App Secret`
|
|
@@ -160,12 +157,9 @@ Here are some prompts you can use with your AI assistant:
|
|
|
160
157
|
- HK: [webullapp.hk/quote](https://www.webullapp.hk/quote) | [Guide](https://developer.webull.hk/apis/docs/market-data-api/subscribe-quotes)
|
|
161
158
|
- JP: [webull.co.jp/pricing](https://www.webull.co.jp/pricing) | [Guide](https://developer.webull.co.jp/api-doc/market-data/subscribe-quotes/)
|
|
162
159
|
- SG: [webull.com.sg/quote](https://www.webull.com.sg/quote) | [Guide](https://developer.webull.com.sg/apis/docs/market-data-api/subscribe-quotes)
|
|
163
|
-
- TH: [webull.co.th/quote](https://www.webull.co.th/quote) | [Guide](https://developer.webull.co.th/apis/docs/market-data-api/subscribe-quotes)
|
|
164
160
|
- MY: [webull.com.my/quote](https://www.webull.com.my/quote) | [Guide](https://developer.webull.com.my/apis/docs/market-data-api/subscribe-quotes)
|
|
165
161
|
- UK: [webull-uk.com/quote](https://www.webull-uk.com/quote) | [Guide](https://developer.webull-uk.com/apis/docs/market-data-api/subscribe-quotes)
|
|
166
|
-
- EU: [webullapp.eu/quote](https://www.webullapp.eu/quote) | [Guide](https://developer.webull.eu/apis/docs/market-data-api/subscribe-quotes)
|
|
167
162
|
- ZA: [webullapp.co.za/quote](https://www.webullapp.co.za/quote) | [Guide](https://developer.webull.co.za/apis/docs/market-data-api/subscribe-quotes)
|
|
168
|
-
- AU: [webullapp.com.au/quote](https://www.webullapp.com.au/quote) | [Guide](https://developer.webull.com.au/apis/docs/market-data-api/subscribe-quotes)
|
|
169
163
|
- MX: [webull.com.mx/quote](https://www.webull.com.mx/quote) | [Guide](https://developer.webull.com.mx/apis/docs/market-data-api/subscribe-quotes)
|
|
170
164
|
- BR: [webull.com.br/quote](https://www.webull.com.br/quote) | [Guide](https://developer.webull.com.br/apis/docs/market-data-api/subscribe-quotes)
|
|
171
165
|
4. **Python 3.10+**
|
|
@@ -310,7 +304,7 @@ Add to your MCP configuration:
|
|
|
310
304
|
| `WEBULL_APP_KEY` | App Key (required) | — |
|
|
311
305
|
| `WEBULL_APP_SECRET` | App Secret (required) | — |
|
|
312
306
|
| `WEBULL_ENVIRONMENT` | `uat` (sandbox) or `prod` | `uat` |
|
|
313
|
-
| `WEBULL_REGION_ID` | `us`, `hk`, `jp`, `sg`, `
|
|
307
|
+
| `WEBULL_REGION_ID` | `us`, `hk`, `jp`, `sg`, `my`, `uk`, `mx`, `br`, or `za` | `us` |
|
|
314
308
|
| `WEBULL_TOOLSETS` | Enabled tool categories (comma-separated). Valid values: `account`, `market-data`, `trading`, `instrument` | (all enabled) |
|
|
315
309
|
| `WEBULL_MAX_ORDER_NOTIONAL_USD` | Max order value for US market (USD) | `10000` |
|
|
316
310
|
| `WEBULL_MAX_ORDER_NOTIONAL_HKD` | Max order value for HK market (HKD) | `80000` |
|
|
@@ -322,7 +316,7 @@ Add to your MCP configuration:
|
|
|
322
316
|
| `WEBULL_AUDIT_LOG_FILE` | Audit log file path | stderr only |
|
|
323
317
|
| `WEBULL_LOG_LEVEL` | SDK log level | `WARNING` |
|
|
324
318
|
|
|
325
|
-
> **Note:** `WEBULL_REGION_ID=us` represents **Webull US** ([developer.webull.com](https://developer.webull.com/apis/home)), `WEBULL_REGION_ID=hk` represents **Webull Hong Kong** ([developer.webull.hk](https://developer.webull.hk/apis/home)), `WEBULL_REGION_ID=jp` represents **Webull Japan** ([developer.webull.co.jp](https://developer.webull.co.jp/)), `WEBULL_REGION_ID=sg` represents **Webull Singapore** ([developer.webull.com.sg](https://developer.webull.com.sg/apis/home)), `WEBULL_REGION_ID=
|
|
319
|
+
> **Note:** `WEBULL_REGION_ID=us` represents **Webull US** ([developer.webull.com](https://developer.webull.com/apis/home)), `WEBULL_REGION_ID=hk` represents **Webull Hong Kong** ([developer.webull.hk](https://developer.webull.hk/apis/home)), `WEBULL_REGION_ID=jp` represents **Webull Japan** ([developer.webull.co.jp](https://developer.webull.co.jp/)), `WEBULL_REGION_ID=sg` represents **Webull Singapore** ([developer.webull.com.sg](https://developer.webull.com.sg/apis/home)), `WEBULL_REGION_ID=my` represents **Webull Malaysia** ([developer.webull.com.my](https://developer.webull.com.my/apis/home)), `WEBULL_REGION_ID=uk` represents **Webull UK** ([developer.webull-uk.com](https://developer.webull-uk.com/apis/home)), `WEBULL_REGION_ID=mx` represents **Webull Mexico** ([developer.webull.com.mx](https://developer.webull.com.mx/apis/home)), `WEBULL_REGION_ID=br` represents **Webull Brazil** ([developer.webull.com.br](https://developer.webull.com.br/apis/home)), and `WEBULL_REGION_ID=za` represents **Webull South Africa** ([developer.webull.co.za](https://developer.webull.co.za/apis/home)).
|
|
326
320
|
|
|
327
321
|
See [.env.example](.env.example) for full configuration template.
|
|
328
322
|
|
|
@@ -370,28 +364,28 @@ See [.env.example](.env.example) for full configuration template.
|
|
|
370
364
|
|
|
371
365
|
### Region Differences
|
|
372
366
|
|
|
373
|
-
| Feature | US | HK | JP | SG |
|
|
374
|
-
|
|
375
|
-
| Stock Trading | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
376
|
-
| Option Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
377
|
-
| Futures Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
378
|
-
| Crypto Trading | Yes | No | No | No | No | No | No | No | No |
|
|
379
|
-
| Event Contracts | Yes | No | No | No | No | No | No | No | No |
|
|
380
|
-
| Combo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
381
|
-
| Option Strategies | Yes | No | No | No | No | No | No | No | No |
|
|
382
|
-
| Algo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
383
|
-
| Screener | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
384
|
-
| Watchlist | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
385
|
-
| Fundamental (Company/Analyst) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
386
|
-
| Stock/Fund Fundamentals | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
387
|
-
| Financial Statements | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
388
|
-
| NOII (Auction Imbalance) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
389
|
-
| Markets | US | US, HK, CN | US, JP | US | US | US | US | US | US |
|
|
390
|
-
| Instrument Categories | US_STOCK, US_ETF | US_STOCK, US_ETF, HK_STOCK, CN_STOCK | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF |
|
|
391
|
-
| Order Types | LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT, TRAILING_STOP_LOSS, etc. | LIMIT, MARKET, ENHANCED_LIMIT, AT_AUCTION, AT_AUCTION_LIMIT, etc. | JP market: LIMIT, MARKET — US market: LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT |
|
|
392
|
-
| Time-in-Force | DAY, GTC | US market: DAY, GTC, GTD — HK market: DAY, GTC — CN market: DAY | JP market: DAY — US market: DAY, GTC, GTD | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC |
|
|
393
|
-
| Trading Sessions | ALL, CORE, NIGHT | CORE, ALL_DAY, NIGHT, ALL | CORE, ALL, NIGHT, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY |
|
|
394
|
-
| JP Order Fields | — | — | `account_tax_type` required (GENERAL or SPECIFIC); `margin_type` (ONE_DAY or INDEFINITE) and `position_intent` optional margin-account-only fields; `close_contracts` optional | — | — | — | — | — | — |
|
|
367
|
+
| Feature | US | HK | JP | SG | MY | UK | MX | BR | ZA |
|
|
368
|
+
|-----------------------------|----|----|----|----|----|-----|----|----|----|
|
|
369
|
+
| Stock Trading | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
370
|
+
| Option Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
371
|
+
| Futures Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
372
|
+
| Crypto Trading | Yes | No | No | No | No | No | No | No | No |
|
|
373
|
+
| Event Contracts | Yes | No | No | No | No | No | No | No | No |
|
|
374
|
+
| Combo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
375
|
+
| Option Strategies | Yes | No | No | No | No | No | No | No | No |
|
|
376
|
+
| Algo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
377
|
+
| Screener | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
378
|
+
| Watchlist | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
379
|
+
| Fundamental (Company/Analyst) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
380
|
+
| Stock/Fund Fundamentals | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
381
|
+
| Financial Statements | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
382
|
+
| NOII (Auction Imbalance) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
383
|
+
| Markets | US | US, HK, CN | US, JP | US | US | US | US | US | US |
|
|
384
|
+
| Instrument Categories | US_STOCK, US_ETF | US_STOCK, US_ETF, HK_STOCK, CN_STOCK | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF |
|
|
385
|
+
| Order Types | LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT, TRAILING_STOP_LOSS, etc. | LIMIT, MARKET, ENHANCED_LIMIT, AT_AUCTION, AT_AUCTION_LIMIT, etc. | JP market: LIMIT, MARKET — US market: LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT |
|
|
386
|
+
| Time-in-Force | DAY, GTC | US market: DAY, GTC, GTD — HK market: DAY, GTC — CN market: DAY | JP market: DAY — US market: DAY, GTC, GTD | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC |
|
|
387
|
+
| Trading Sessions | ALL, CORE, NIGHT | CORE, ALL_DAY, NIGHT, ALL | CORE, ALL, NIGHT, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY |
|
|
388
|
+
| JP Order Fields | — | — | `account_tax_type` required (GENERAL or SPECIFIC); `margin_type` (ONE_DAY or INDEFINITE) and `position_intent` optional margin-account-only fields; `close_contracts` optional | — | — | — | — | — | — |
|
|
395
389
|
|
|
396
390
|
> **Note:** Screener (Gainers/Losers/Active), Fundamental (Company/Analyst), and NOII currently only support querying US stock data (`US_STOCK` category). Stock/Fund Fundamentals, Financial Statements, and the extended Screener (Sectors/Dividend/52W) are available in all regions; supported `category` values vary by endpoint (commonly `US_STOCK`, `HK_STOCK`, `CN_STOCK`, `JP_STOCK`). Watchlist supports US stocks and HK stocks.
|
|
397
391
|
|
|
@@ -438,7 +432,7 @@ All commands accept `--env-file PATH` to specify a custom `.env` file location (
|
|
|
438
432
|
- **Review before trading** — Always review order details proposed by the AI before confirming. Use `preview_stock_order` / `preview_option_order` before placing orders.
|
|
439
433
|
- **Use toolset filtering** — Set `WEBULL_TOOLSETS=account,market-data` to disable trading tools entirely if you only need read-only access. Valid toolsets: `account`, `market-data`, `trading`, `instrument`.
|
|
440
434
|
- **Default sandbox** — The server defaults to UAT (sandbox) environment. You must explicitly set `WEBULL_ENVIRONMENT=prod` for live trading.
|
|
441
|
-
- **Dependency security** — `fastmcp` is pinned to version `3.0.2` and `webull-openapi-python-sdk` is pinned to `
|
|
435
|
+
- **Dependency security** — `fastmcp` is pinned to version `3.0.2` and `webull-openapi-python-sdk` is pinned to `3.0.0`. Users are responsible for monitoring and updating third-party dependencies for security patches. Review release notes before upgrading.
|
|
442
436
|
|
|
443
437
|
---
|
|
444
438
|
|
|
@@ -479,12 +473,9 @@ Subscribe to quotes:
|
|
|
479
473
|
- HK: [webullapp.hk/quote](https://www.webullapp.hk/quote) | [Guide](https://developer.webull.hk/apis/docs/market-data-api/subscribe-quotes)
|
|
480
474
|
- JP: [webull.co.jp/pricing](https://www.webull.co.jp/pricing) | [Guide](https://developer.webull.co.jp/api-doc/market-data/subscribe-quotes/)
|
|
481
475
|
- SG: [webull.com.sg/quote](https://www.webull.com.sg/quote) | [Guide](https://developer.webull.com.sg/apis/docs/market-data-api/subscribe-quotes)
|
|
482
|
-
- TH: [webull.co.th/quote](https://www.webull.co.th/quote) | [Guide](https://developer.webull.co.th/apis/docs/market-data-api/subscribe-quotes)
|
|
483
476
|
- MY: [webull.com.my/quote](https://www.webull.com.my/quote) | [Guide](https://developer.webull.com.my/apis/docs/market-data-api/subscribe-quotes)
|
|
484
477
|
- UK: [webull-uk.com/quote](https://www.webull-uk.com/quote) | [Guide](https://developer.webull-uk.com/apis/docs/market-data-api/subscribe-quotes)
|
|
485
|
-
- EU: [webullapp.eu/quote](https://www.webullapp.eu/quote) | [Guide](https://developer.webull.eu/apis/docs/market-data-api/subscribe-quotes)
|
|
486
478
|
- ZA: [webullapp.co.za/quote](https://www.webullapp.co.za/quote) | [Guide](https://developer.webull.co.za/apis/docs/market-data-api/subscribe-quotes)
|
|
487
|
-
- AU: [webullapp.com.au/quote](https://www.webullapp.com.au/quote) | [Guide](https://developer.webull.com.au/apis/docs/market-data-api/subscribe-quotes)
|
|
488
479
|
- MX: [webull.com.mx/quote](https://www.webull.com.mx/quote) | [Guide](https://developer.webull.com.mx/apis/docs/market-data-api/subscribe-quotes)
|
|
489
480
|
- BR: [webull.com.br/quote](https://www.webull.com.br/quote) | [Guide](https://developer.webull.com.br/apis/docs/market-data-api/subscribe-quotes)
|
|
490
481
|
|
|
@@ -521,7 +512,7 @@ webull-openapi-mcp/
|
|
|
521
512
|
│ ├── server.py # MCP server setup and tool registration
|
|
522
513
|
│ ├── sdk_client.py # Webull SDK adapter (ApiClient, TradeClient, DataClient)
|
|
523
514
|
│ ├── config.py # Configuration loading and validation
|
|
524
|
-
│ ├── region_config.py # Region-specific settings (US, HK, JP, SG,
|
|
515
|
+
│ ├── region_config.py # Region-specific settings (US, HK, JP, SG, MY, UK, MX, BR, ZA)
|
|
525
516
|
│ ├── guards.py # Order validation (price, quantity, notional, region rules)
|
|
526
517
|
│ ├── audit.py # Audit logging for order operations
|
|
527
518
|
│ ├── errors.py # Exception definitions and SDK error handling
|
|
@@ -19,7 +19,7 @@ See [DISCLAIMER.md](DISCLAIMER.md) for the full disclaimer.
|
|
|
19
19
|
|
|
20
20
|
## Features
|
|
21
21
|
|
|
22
|
-
- **Multi-Region Support** — US, HK, JP, SG,
|
|
22
|
+
- **Multi-Region Support** — US, HK, JP, SG, MY, UK, MX, BR, and ZA regions with region-specific order types, trading sessions, and validation
|
|
23
23
|
- **Market Data** — Real-time snapshots, tick data, quotes (depth), footprint, and OHLCV bars for stocks, options, futures, crypto, and event contracts
|
|
24
24
|
- **NOII Data** — Net Order Imbalance Indicator bars and snapshots for US stock opening/closing auctions
|
|
25
25
|
- **Screener** — Top gainers/losers, most active, market sectors, high dividend, and 52-week high/low rankings
|
|
@@ -116,12 +116,9 @@ Here are some prompts you can use with your AI assistant:
|
|
|
116
116
|
- HK: [developer.webull.hk](https://developer.webull.hk/apis/home)
|
|
117
117
|
- JP: [developer.webull.co.jp](https://developer.webull.co.jp/)
|
|
118
118
|
- SG: [developer.webull.com.sg](https://developer.webull.com.sg/apis/home)
|
|
119
|
-
- TH: [developer.webull.co.th](https://developer.webull.co.th/apis/home)
|
|
120
119
|
- MY: [developer.webull.com.my](https://developer.webull.com.my/apis/home)
|
|
121
120
|
- UK: [developer.webull-uk.com](https://developer.webull-uk.com/apis/home)
|
|
122
|
-
- EU: [developer.webull.eu](https://developer.webull.eu/apis/home)
|
|
123
121
|
- ZA: [developer.webull.co.za](https://developer.webull.co.za/apis/home)
|
|
124
|
-
- AU: [developer.webull.com.au](https://developer.webull.com.au/apis/home)
|
|
125
122
|
- MX: [developer.webull.com.mx](https://developer.webull.com.mx/apis/home)
|
|
126
123
|
- BR: [developer.webull.com.br](https://developer.webull.com.br/apis/home)
|
|
127
124
|
2. **API Credentials** — Obtain your `App Key` and `App Secret`
|
|
@@ -130,12 +127,9 @@ Here are some prompts you can use with your AI assistant:
|
|
|
130
127
|
- HK: [webullapp.hk/quote](https://www.webullapp.hk/quote) | [Guide](https://developer.webull.hk/apis/docs/market-data-api/subscribe-quotes)
|
|
131
128
|
- JP: [webull.co.jp/pricing](https://www.webull.co.jp/pricing) | [Guide](https://developer.webull.co.jp/api-doc/market-data/subscribe-quotes/)
|
|
132
129
|
- SG: [webull.com.sg/quote](https://www.webull.com.sg/quote) | [Guide](https://developer.webull.com.sg/apis/docs/market-data-api/subscribe-quotes)
|
|
133
|
-
- TH: [webull.co.th/quote](https://www.webull.co.th/quote) | [Guide](https://developer.webull.co.th/apis/docs/market-data-api/subscribe-quotes)
|
|
134
130
|
- MY: [webull.com.my/quote](https://www.webull.com.my/quote) | [Guide](https://developer.webull.com.my/apis/docs/market-data-api/subscribe-quotes)
|
|
135
131
|
- UK: [webull-uk.com/quote](https://www.webull-uk.com/quote) | [Guide](https://developer.webull-uk.com/apis/docs/market-data-api/subscribe-quotes)
|
|
136
|
-
- EU: [webullapp.eu/quote](https://www.webullapp.eu/quote) | [Guide](https://developer.webull.eu/apis/docs/market-data-api/subscribe-quotes)
|
|
137
132
|
- ZA: [webullapp.co.za/quote](https://www.webullapp.co.za/quote) | [Guide](https://developer.webull.co.za/apis/docs/market-data-api/subscribe-quotes)
|
|
138
|
-
- AU: [webullapp.com.au/quote](https://www.webullapp.com.au/quote) | [Guide](https://developer.webull.com.au/apis/docs/market-data-api/subscribe-quotes)
|
|
139
133
|
- MX: [webull.com.mx/quote](https://www.webull.com.mx/quote) | [Guide](https://developer.webull.com.mx/apis/docs/market-data-api/subscribe-quotes)
|
|
140
134
|
- BR: [webull.com.br/quote](https://www.webull.com.br/quote) | [Guide](https://developer.webull.com.br/apis/docs/market-data-api/subscribe-quotes)
|
|
141
135
|
4. **Python 3.10+**
|
|
@@ -280,7 +274,7 @@ Add to your MCP configuration:
|
|
|
280
274
|
| `WEBULL_APP_KEY` | App Key (required) | — |
|
|
281
275
|
| `WEBULL_APP_SECRET` | App Secret (required) | — |
|
|
282
276
|
| `WEBULL_ENVIRONMENT` | `uat` (sandbox) or `prod` | `uat` |
|
|
283
|
-
| `WEBULL_REGION_ID` | `us`, `hk`, `jp`, `sg`, `
|
|
277
|
+
| `WEBULL_REGION_ID` | `us`, `hk`, `jp`, `sg`, `my`, `uk`, `mx`, `br`, or `za` | `us` |
|
|
284
278
|
| `WEBULL_TOOLSETS` | Enabled tool categories (comma-separated). Valid values: `account`, `market-data`, `trading`, `instrument` | (all enabled) |
|
|
285
279
|
| `WEBULL_MAX_ORDER_NOTIONAL_USD` | Max order value for US market (USD) | `10000` |
|
|
286
280
|
| `WEBULL_MAX_ORDER_NOTIONAL_HKD` | Max order value for HK market (HKD) | `80000` |
|
|
@@ -292,7 +286,7 @@ Add to your MCP configuration:
|
|
|
292
286
|
| `WEBULL_AUDIT_LOG_FILE` | Audit log file path | stderr only |
|
|
293
287
|
| `WEBULL_LOG_LEVEL` | SDK log level | `WARNING` |
|
|
294
288
|
|
|
295
|
-
> **Note:** `WEBULL_REGION_ID=us` represents **Webull US** ([developer.webull.com](https://developer.webull.com/apis/home)), `WEBULL_REGION_ID=hk` represents **Webull Hong Kong** ([developer.webull.hk](https://developer.webull.hk/apis/home)), `WEBULL_REGION_ID=jp` represents **Webull Japan** ([developer.webull.co.jp](https://developer.webull.co.jp/)), `WEBULL_REGION_ID=sg` represents **Webull Singapore** ([developer.webull.com.sg](https://developer.webull.com.sg/apis/home)), `WEBULL_REGION_ID=
|
|
289
|
+
> **Note:** `WEBULL_REGION_ID=us` represents **Webull US** ([developer.webull.com](https://developer.webull.com/apis/home)), `WEBULL_REGION_ID=hk` represents **Webull Hong Kong** ([developer.webull.hk](https://developer.webull.hk/apis/home)), `WEBULL_REGION_ID=jp` represents **Webull Japan** ([developer.webull.co.jp](https://developer.webull.co.jp/)), `WEBULL_REGION_ID=sg` represents **Webull Singapore** ([developer.webull.com.sg](https://developer.webull.com.sg/apis/home)), `WEBULL_REGION_ID=my` represents **Webull Malaysia** ([developer.webull.com.my](https://developer.webull.com.my/apis/home)), `WEBULL_REGION_ID=uk` represents **Webull UK** ([developer.webull-uk.com](https://developer.webull-uk.com/apis/home)), `WEBULL_REGION_ID=mx` represents **Webull Mexico** ([developer.webull.com.mx](https://developer.webull.com.mx/apis/home)), `WEBULL_REGION_ID=br` represents **Webull Brazil** ([developer.webull.com.br](https://developer.webull.com.br/apis/home)), and `WEBULL_REGION_ID=za` represents **Webull South Africa** ([developer.webull.co.za](https://developer.webull.co.za/apis/home)).
|
|
296
290
|
|
|
297
291
|
See [.env.example](.env.example) for full configuration template.
|
|
298
292
|
|
|
@@ -340,28 +334,28 @@ See [.env.example](.env.example) for full configuration template.
|
|
|
340
334
|
|
|
341
335
|
### Region Differences
|
|
342
336
|
|
|
343
|
-
| Feature | US | HK | JP | SG |
|
|
344
|
-
|
|
345
|
-
| Stock Trading | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
346
|
-
| Option Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
347
|
-
| Futures Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
348
|
-
| Crypto Trading | Yes | No | No | No | No | No | No | No | No |
|
|
349
|
-
| Event Contracts | Yes | No | No | No | No | No | No | No | No |
|
|
350
|
-
| Combo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
351
|
-
| Option Strategies | Yes | No | No | No | No | No | No | No | No |
|
|
352
|
-
| Algo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
353
|
-
| Screener | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
354
|
-
| Watchlist | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
355
|
-
| Fundamental (Company/Analyst) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
356
|
-
| Stock/Fund Fundamentals | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
357
|
-
| Financial Statements | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
358
|
-
| NOII (Auction Imbalance) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
359
|
-
| Markets | US | US, HK, CN | US, JP | US | US | US | US | US | US |
|
|
360
|
-
| Instrument Categories | US_STOCK, US_ETF | US_STOCK, US_ETF, HK_STOCK, CN_STOCK | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF |
|
|
361
|
-
| Order Types | LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT, TRAILING_STOP_LOSS, etc. | LIMIT, MARKET, ENHANCED_LIMIT, AT_AUCTION, AT_AUCTION_LIMIT, etc. | JP market: LIMIT, MARKET — US market: LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT |
|
|
362
|
-
| Time-in-Force | DAY, GTC | US market: DAY, GTC, GTD — HK market: DAY, GTC — CN market: DAY | JP market: DAY — US market: DAY, GTC, GTD | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC |
|
|
363
|
-
| Trading Sessions | ALL, CORE, NIGHT | CORE, ALL_DAY, NIGHT, ALL | CORE, ALL, NIGHT, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY |
|
|
364
|
-
| JP Order Fields | — | — | `account_tax_type` required (GENERAL or SPECIFIC); `margin_type` (ONE_DAY or INDEFINITE) and `position_intent` optional margin-account-only fields; `close_contracts` optional | — | — | — | — | — | — |
|
|
337
|
+
| Feature | US | HK | JP | SG | MY | UK | MX | BR | ZA |
|
|
338
|
+
|-----------------------------|----|----|----|----|----|-----|----|----|----|
|
|
339
|
+
| Stock Trading | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
340
|
+
| Option Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
341
|
+
| Futures Trading | Yes | Yes | No | No | No | No | No | No | No |
|
|
342
|
+
| Crypto Trading | Yes | No | No | No | No | No | No | No | No |
|
|
343
|
+
| Event Contracts | Yes | No | No | No | No | No | No | No | No |
|
|
344
|
+
| Combo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
345
|
+
| Option Strategies | Yes | No | No | No | No | No | No | No | No |
|
|
346
|
+
| Algo Orders | Yes | No | No | No | No | No | No | No | No |
|
|
347
|
+
| Screener | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
348
|
+
| Watchlist | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
349
|
+
| Fundamental (Company/Analyst) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
350
|
+
| Stock/Fund Fundamentals | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
351
|
+
| Financial Statements | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
352
|
+
| NOII (Auction Imbalance) | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes |
|
|
353
|
+
| Markets | US | US, HK, CN | US, JP | US | US | US | US | US | US |
|
|
354
|
+
| Instrument Categories | US_STOCK, US_ETF | US_STOCK, US_ETF, HK_STOCK, CN_STOCK | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF | US_STOCK, US_ETF |
|
|
355
|
+
| Order Types | LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT, TRAILING_STOP_LOSS, etc. | LIMIT, MARKET, ENHANCED_LIMIT, AT_AUCTION, AT_AUCTION_LIMIT, etc. | JP market: LIMIT, MARKET — US market: LIMIT, MARKET, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT | MARKET, LIMIT, STOP_LOSS, STOP_LOSS_LIMIT |
|
|
356
|
+
| Time-in-Force | DAY, GTC | US market: DAY, GTC, GTD — HK market: DAY, GTC — CN market: DAY | JP market: DAY — US market: DAY, GTC, GTD | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC | DAY, GTC |
|
|
357
|
+
| Trading Sessions | ALL, CORE, NIGHT | CORE, ALL_DAY, NIGHT, ALL | CORE, ALL, NIGHT, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY | NIGHT, ALL, CORE, ALL_DAY |
|
|
358
|
+
| JP Order Fields | — | — | `account_tax_type` required (GENERAL or SPECIFIC); `margin_type` (ONE_DAY or INDEFINITE) and `position_intent` optional margin-account-only fields; `close_contracts` optional | — | — | — | — | — | — |
|
|
365
359
|
|
|
366
360
|
> **Note:** Screener (Gainers/Losers/Active), Fundamental (Company/Analyst), and NOII currently only support querying US stock data (`US_STOCK` category). Stock/Fund Fundamentals, Financial Statements, and the extended Screener (Sectors/Dividend/52W) are available in all regions; supported `category` values vary by endpoint (commonly `US_STOCK`, `HK_STOCK`, `CN_STOCK`, `JP_STOCK`). Watchlist supports US stocks and HK stocks.
|
|
367
361
|
|
|
@@ -408,7 +402,7 @@ All commands accept `--env-file PATH` to specify a custom `.env` file location (
|
|
|
408
402
|
- **Review before trading** — Always review order details proposed by the AI before confirming. Use `preview_stock_order` / `preview_option_order` before placing orders.
|
|
409
403
|
- **Use toolset filtering** — Set `WEBULL_TOOLSETS=account,market-data` to disable trading tools entirely if you only need read-only access. Valid toolsets: `account`, `market-data`, `trading`, `instrument`.
|
|
410
404
|
- **Default sandbox** — The server defaults to UAT (sandbox) environment. You must explicitly set `WEBULL_ENVIRONMENT=prod` for live trading.
|
|
411
|
-
- **Dependency security** — `fastmcp` is pinned to version `3.0.2` and `webull-openapi-python-sdk` is pinned to `
|
|
405
|
+
- **Dependency security** — `fastmcp` is pinned to version `3.0.2` and `webull-openapi-python-sdk` is pinned to `3.0.0`. Users are responsible for monitoring and updating third-party dependencies for security patches. Review release notes before upgrading.
|
|
412
406
|
|
|
413
407
|
---
|
|
414
408
|
|
|
@@ -449,12 +443,9 @@ Subscribe to quotes:
|
|
|
449
443
|
- HK: [webullapp.hk/quote](https://www.webullapp.hk/quote) | [Guide](https://developer.webull.hk/apis/docs/market-data-api/subscribe-quotes)
|
|
450
444
|
- JP: [webull.co.jp/pricing](https://www.webull.co.jp/pricing) | [Guide](https://developer.webull.co.jp/api-doc/market-data/subscribe-quotes/)
|
|
451
445
|
- SG: [webull.com.sg/quote](https://www.webull.com.sg/quote) | [Guide](https://developer.webull.com.sg/apis/docs/market-data-api/subscribe-quotes)
|
|
452
|
-
- TH: [webull.co.th/quote](https://www.webull.co.th/quote) | [Guide](https://developer.webull.co.th/apis/docs/market-data-api/subscribe-quotes)
|
|
453
446
|
- MY: [webull.com.my/quote](https://www.webull.com.my/quote) | [Guide](https://developer.webull.com.my/apis/docs/market-data-api/subscribe-quotes)
|
|
454
447
|
- UK: [webull-uk.com/quote](https://www.webull-uk.com/quote) | [Guide](https://developer.webull-uk.com/apis/docs/market-data-api/subscribe-quotes)
|
|
455
|
-
- EU: [webullapp.eu/quote](https://www.webullapp.eu/quote) | [Guide](https://developer.webull.eu/apis/docs/market-data-api/subscribe-quotes)
|
|
456
448
|
- ZA: [webullapp.co.za/quote](https://www.webullapp.co.za/quote) | [Guide](https://developer.webull.co.za/apis/docs/market-data-api/subscribe-quotes)
|
|
457
|
-
- AU: [webullapp.com.au/quote](https://www.webullapp.com.au/quote) | [Guide](https://developer.webull.com.au/apis/docs/market-data-api/subscribe-quotes)
|
|
458
449
|
- MX: [webull.com.mx/quote](https://www.webull.com.mx/quote) | [Guide](https://developer.webull.com.mx/apis/docs/market-data-api/subscribe-quotes)
|
|
459
450
|
- BR: [webull.com.br/quote](https://www.webull.com.br/quote) | [Guide](https://developer.webull.com.br/apis/docs/market-data-api/subscribe-quotes)
|
|
460
451
|
|
|
@@ -491,7 +482,7 @@ webull-openapi-mcp/
|
|
|
491
482
|
│ ├── server.py # MCP server setup and tool registration
|
|
492
483
|
│ ├── sdk_client.py # Webull SDK adapter (ApiClient, TradeClient, DataClient)
|
|
493
484
|
│ ├── config.py # Configuration loading and validation
|
|
494
|
-
│ ├── region_config.py # Region-specific settings (US, HK, JP, SG,
|
|
485
|
+
│ ├── region_config.py # Region-specific settings (US, HK, JP, SG, MY, UK, MX, BR, ZA)
|
|
495
486
|
│ ├── guards.py # Order validation (price, quantity, notional, region rules)
|
|
496
487
|
│ ├── audit.py # Audit logging for order operations
|
|
497
488
|
│ ├── errors.py # Exception definitions and SDK error handling
|
|
@@ -194,7 +194,7 @@ def build_manifest(
|
|
|
194
194
|
"region_id": {
|
|
195
195
|
"type": "string",
|
|
196
196
|
"title": "Region",
|
|
197
|
-
"description": "Webull region: us, hk, jp, sg,
|
|
197
|
+
"description": "Webull region: us, hk, jp, sg, my, uk, mx, br, or za.",
|
|
198
198
|
"default": "us",
|
|
199
199
|
"required": True,
|
|
200
200
|
},
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "webull-openapi-mcp"
|
|
7
|
-
version = "1.2.
|
|
7
|
+
version = "1.2.4"
|
|
8
8
|
description = "MCP Server for Webull OpenAPI - enables AI assistants to securely access Webull trading and market data"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = "Apache-2.0"
|
|
@@ -24,7 +24,7 @@ dependencies = [
|
|
|
24
24
|
"fastmcp==3.0.2",
|
|
25
25
|
"click",
|
|
26
26
|
"python-dotenv",
|
|
27
|
-
"webull-openapi-python-sdk==
|
|
27
|
+
"webull-openapi-python-sdk==3.0.0",
|
|
28
28
|
]
|
|
29
29
|
|
|
30
30
|
[project.urls]
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"name": "io.github.webull-inc/webull-openapi-mcp",
|
|
4
4
|
"title": "Webull OpenAPI",
|
|
5
5
|
"description": "MCP server for Webull OpenAPI: trading and market data access for AI assistants",
|
|
6
|
-
"version": "1.2.
|
|
6
|
+
"version": "1.2.4",
|
|
7
7
|
"repository": {
|
|
8
8
|
"url": "https://github.com/webull-inc/webull-openapi-mcp",
|
|
9
9
|
"source": "github"
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"registryType": "pypi",
|
|
14
14
|
"registryBaseUrl": "https://pypi.org",
|
|
15
15
|
"identifier": "webull-openapi-mcp",
|
|
16
|
-
"version": "1.2.
|
|
16
|
+
"version": "1.2.4",
|
|
17
17
|
"runtimeHint": "uvx",
|
|
18
18
|
"transport": {
|
|
19
19
|
"type": "stdio"
|
|
@@ -199,14 +199,14 @@ def test_new_tools_registered_for_supported_regions(region):
|
|
|
199
199
|
assert not missing, f"{region} missing: {missing}"
|
|
200
200
|
|
|
201
201
|
|
|
202
|
-
@pytest.mark.parametrize("region", ["sg", "
|
|
202
|
+
@pytest.mark.parametrize("region", ["sg", "my", "uk", "mx", "br"])
|
|
203
203
|
def test_new_tools_absent_for_unsupported_regions(region):
|
|
204
204
|
names = _build_server_tools(region)
|
|
205
205
|
present = [t for t in EXPECTED_TOOLS if t in names]
|
|
206
|
-
assert
|
|
206
|
+
assert present, f"{region} should not expose: {present}"
|
|
207
207
|
|
|
208
208
|
|
|
209
|
-
@pytest.mark.parametrize("region", ["us", "hk", "jp", "sg", "
|
|
209
|
+
@pytest.mark.parametrize("region", ["us", "hk", "jp", "sg", "my", "uk", "mx", "br"])
|
|
210
210
|
def test_legacy_tools_available_in_all_regions(region):
|
|
211
211
|
names = _build_server_tools(region)
|
|
212
212
|
missing = [t for t in LEGACY_TOOLS if t not in names]
|
|
@@ -27,10 +27,10 @@ class TestUATEndpoints:
|
|
|
27
27
|
assert UAT_ENDPOINTS["default_region"] == "us"
|
|
28
28
|
|
|
29
29
|
def test_regions_list(self):
|
|
30
|
-
assert set(UAT_ENDPOINTS["regions"]) == {"us", "hk", "jp", "sg", "
|
|
30
|
+
assert set(UAT_ENDPOINTS["regions"]) == {"us", "hk", "jp", "sg", "my", "uk", "mx", "br", "za"}
|
|
31
31
|
|
|
32
32
|
def test_each_region_has_all_api_types(self):
|
|
33
|
-
for region in ("us", "hk", "jp", "sg", "
|
|
33
|
+
for region in ("us", "hk", "jp", "sg", "my", "uk", "mx", "br", "za"):
|
|
34
34
|
mapping = UAT_ENDPOINTS["region_mapping"][region]
|
|
35
35
|
assert "api" in mapping
|
|
36
36
|
assert "quotes-api" in mapping
|
|
@@ -152,7 +152,7 @@ WEBULL_APP_SECRET={app_secret}
|
|
|
152
152
|
# API environment: uat or prod (default: uat)
|
|
153
153
|
WEBULL_ENVIRONMENT={environment}
|
|
154
154
|
|
|
155
|
-
# Optional: Region ID (default: us). Supported: us, hk, jp, sg,
|
|
155
|
+
# Optional: Region ID (default: us). Supported: us, hk, jp, sg, my, uk, mx, br, za
|
|
156
156
|
# WEBULL_REGION_ID=us
|
|
157
157
|
|
|
158
158
|
# Optional: Risk control parameters
|
|
@@ -35,6 +35,9 @@ VALID_POSITION_INTENTS: frozenset[str] = frozenset({
|
|
|
35
35
|
"SELL_TO_CLOSE",
|
|
36
36
|
})
|
|
37
37
|
|
|
38
|
+
# Option leg-in / leg-out values (US only)
|
|
39
|
+
VALID_LEG_IN_OUT: frozenset[str] = frozenset({"LEG_IN", "LEG_OUT"})
|
|
40
|
+
|
|
38
41
|
# Trading session types
|
|
39
42
|
VALID_TRADING_SESSIONS: frozenset[str] = frozenset({"ALL", "CORE", "NIGHT"})
|
|
40
43
|
|