Gap
PolymarketUSWebSocketConfig defines a watchTimeoutMs option, but PolymarketUSExchange has no options wrapper to accept it at all — unlike sibling PolymarketExchange, which threads an equivalent config through to its WebSocket client. For polymarket_us, the config is entirely unreachable, even by a core consumer bypassing the SDKs — this is a step deeper than #1052 ("PolymarketExchangeOptions.websocket not passable through either SDK"), where plain Polymarket's config is wired in core, just not SDK-exposed.
Note: PolymarketUSConfig's gatewayUrl has the same problem in miniature — it's only settable via the POLYMARKET_US_GATEWAY_URL env var, with no per-instance override path; folding that into this same issue since it's the same root cause (missing options wrapper).
Core
core/src/exchanges/polymarket_us/websocket.ts:30-33 — defines PolymarketUSWebSocketConfig { watchTimeoutMs?: number }; PolymarketUSWebSocket's constructor accepts it as an optional third param (default {}).
core/src/exchanges/polymarket_us/index.ts:452-458 (ensureWs()) — always calls new PolymarketUSWebSocket(this.client, this.normalizer) — the config argument is never supplied.
core/src/exchanges/polymarket_us/index.ts:74 — the constructor accepts only credentials?: ExchangeCredentials, with no PolymarketUSExchangeOptions { credentials?; websocket? } wrapper, unlike the sibling pattern at core/src/exchanges/polymarket/index.ts:54-88.
core/src/exchanges/polymarket_us/config.ts:25-35 — getPolymarketUSConfig() lets credentials.baseUrl override apiUrl per-instance, but gatewayUrl can only come from the POLYMARKET_US_GATEWAY_URL env var.
- Confirmed via grep that every call site (
core/scripts/smoke-polymarket-us.ts:78, find-active-polymarket-us.ts:11, inspect-polymarket-us.ts:8, exchange-factory.ts:122) constructs PolymarketUSExchange with zero or bare {apiKey, privateKey} — none can inject a watch timeout or gateway URL override.
TypeScript SDK
N/A directly (nothing in core to expose) — but for context, sdks/typescript/pmxt/client.ts's PolymarketUS class has no websocket option either, consistent with core lacking one.
Python SDK
N/A directly — same, sdks/python/pmxt/_exchanges.py's PolymarketUS/Polymarket_us classes have no websocket option.
Evidence
core/src/exchanges/polymarket_us/index.ts:452-458,74 vs. core/src/exchanges/polymarket/index.ts:54-88 — direct comparison shows Polymarket has the options-wrapper plumbing that PolymarketUS lacks entirely.
Impact
Neither a polymarket_us SDK user nor a direct core consumer can configure the WebSocket watch timeout or override the gateway URL per-instance — the only lever available is the global POLYMARKET_US_GATEWAY_URL environment variable.
Found by automated Core-to-SDK surface coverage audit
Gap
PolymarketUSWebSocketConfigdefines awatchTimeoutMsoption, butPolymarketUSExchangehas no options wrapper to accept it at all — unlike siblingPolymarketExchange, which threads an equivalent config through to its WebSocket client. Forpolymarket_us, the config is entirely unreachable, even by a core consumer bypassing the SDKs — this is a step deeper than #1052 ("PolymarketExchangeOptions.websocketnot passable through either SDK"), where plain Polymarket's config is wired in core, just not SDK-exposed.Note:
PolymarketUSConfig'sgatewayUrlhas the same problem in miniature — it's only settable via thePOLYMARKET_US_GATEWAY_URLenv var, with no per-instance override path; folding that into this same issue since it's the same root cause (missing options wrapper).Core
core/src/exchanges/polymarket_us/websocket.ts:30-33— definesPolymarketUSWebSocketConfig { watchTimeoutMs?: number };PolymarketUSWebSocket's constructor accepts it as an optional third param (default{}).core/src/exchanges/polymarket_us/index.ts:452-458(ensureWs()) — always callsnew PolymarketUSWebSocket(this.client, this.normalizer)— the config argument is never supplied.core/src/exchanges/polymarket_us/index.ts:74— the constructor accepts onlycredentials?: ExchangeCredentials, with noPolymarketUSExchangeOptions { credentials?; websocket? }wrapper, unlike the sibling pattern atcore/src/exchanges/polymarket/index.ts:54-88.core/src/exchanges/polymarket_us/config.ts:25-35—getPolymarketUSConfig()letscredentials.baseUrloverrideapiUrlper-instance, butgatewayUrlcan only come from thePOLYMARKET_US_GATEWAY_URLenv var.core/scripts/smoke-polymarket-us.ts:78,find-active-polymarket-us.ts:11,inspect-polymarket-us.ts:8,exchange-factory.ts:122) constructsPolymarketUSExchangewith zero or bare{apiKey, privateKey}— none can inject a watch timeout or gateway URL override.TypeScript SDK
N/A directly (nothing in core to expose) — but for context,
sdks/typescript/pmxt/client.ts'sPolymarketUSclass has nowebsocketoption either, consistent with core lacking one.Python SDK
N/A directly — same,
sdks/python/pmxt/_exchanges.py'sPolymarketUS/Polymarket_usclasses have nowebsocketoption.Evidence
core/src/exchanges/polymarket_us/index.ts:452-458,74vs.core/src/exchanges/polymarket/index.ts:54-88— direct comparison shows Polymarket has the options-wrapper plumbing that PolymarketUS lacks entirely.Impact
Neither a
polymarket_usSDK user nor a direct core consumer can configure the WebSocket watch timeout or override the gateway URL per-instance — the only lever available is the globalPOLYMARKET_US_GATEWAY_URLenvironment variable.Found by automated Core-to-SDK surface coverage audit