Skip to main content
The mempool feed is Bravado’s low-latency fills stream. Settlements are decoded directly from the Polygon public mempool, so a fill reaches you ~1–2s before the venue’s own real-time feed reports it (measured against Polymarket RTDS: earlier on ~100% of trades, ~1.5–2s median). Every fill carries the full on-chain lifecycle — pending → mined → settled, and the negative states (reverted / dropped / replaced) — plus the owner wallet (EOA) behind the trading proxy.
The legacy connection at wss://stream.bravadotrade.com/ws requires a separately provisioned feed token. A Data API or Market Data HMAC key is not that token. The Console-managed connection is a separate rollout; see access and authentication. The public Live Trades feed mirrors the venue’s push feed and uses your Market Data credential; this feed adds the mempool lead, the settlement-truth lifecycle, and inline identity. Coverage today is Polymarket.
This feed is served directly from the feed edge (stream.bravadotrade.com), not proxied through partner-api.bravadotrade.com like the other APIs. That is deliberate: an extra proxy hop would add relay latency and erode the mempool lead that is the whole point of this feed. Connect to the edge host directly.

Access and authentication

Use a key created under WebSockets, not the separate Data API, Market Data REST, or Trade API products. A key display name can be customised; its product and stream.read scope determine eligibility. Do not send the API key itself as a feed bearer token. There are two connection contracts, and the token must match the socket: The Console-managed destinations are not generally available until coordinated release validation is complete. A 404 on those paths is a deployment issue, not a reason to rotate your API key. A 401 on the legacy socket means its feed token is missing, expired or refused. Contact support with the destination and error code; never send your API secret or token in a support message. During the managed rollout, eligible organisations use Mempool Fills in Console to obtain access without copying your API secret into the browser. Each reconnect obtains a fresh grant; expiry closes the previous connection. Your subscription, scope, credits and organisation permissions still apply. General plan prices do not override an account-specific commercial agreement. The HMAC path includes the canonical query: sort keys and percent-encode values using RFC 3986. Use authentication examples for the signing format. The direct legacy example below continues to require its provisioned feed token.

Connect

Pass an initial stream set and (optionally) a mode and replay count on the query string, and present your token as a Bearer header or a ?token= parameter. An invalid sender_gate or pending_ttl value is refused with HTTP 400 before the WebSocket upgrade.
All amounts are integer base units as decimal strings — 6-decimal micro-USDC and 6-decimal share units; token_id is an exact decimal string and price_micro is usdc * 1e6 / shares. Never parse these as floats.

Streams

Subscribe to the firehose or narrow to a token, market, or wallet. One connection may hold 120 streams.
A wallet matches a fill if it is any leg’s maker or signer, any leg’s on-chain taker, or the transaction sender — the operator rotates senders, so identity is never keyed on the sender alone. Related resolution and collateral streams (resolutions:polymarket:*, collateral:polymarket:*) and the UMA resolution lifecycle (uma:polymarket:*) are available over the same socket. The collateral:polymarket:* stream carries mined splits, merges, redemptions and conversions only: pending (mempool) collateral is not emitted.

The fill lifecycle

A fill is not one event — it is a sequence of status transitions for the same transaction. This is the “did it actually settle?” signal no post-block feed can give you. A matched signal upgrades to pending when the settle tx hits the mempool, or expires as a ghost fill if it never settles. Track a transaction by tx_hash, and dedupe by (tx_hash, status) — the same tx legitimately arrives once per transition.

Sender verification

A pending frame is emitted only for a transaction whose sender holds the exchange OPERATOR role on-chain; third-party calldata wearing another wallet’s name is rejected before it reaches any stream. A pending transaction is calldata in the public mempool. Anyone can broadcast calldata that names any wallet as maker or taker, but only Polymarket’s operators can actually settle a match on the exchange. Before a pending frame is emitted, we check the transaction sender against the exchange contract’s isOperator. The check uses a cache of known operators, so it normally adds no delay. A sender we have not seen before is held for the on-chain check and then emitted with its original ts_seen. A pending transaction whose sender fails the check never reaches a default stream, the replay buffer, or a wallet stream. mined, finalized, and reverted frames are unaffected: they come from block logs, which only the exchange can emit.

Seeing unverified pendings (sender_gate=off)

Connect with sender_gate=off if you want the raw mempool view, including transactions whose sender is unverified or not an operator:
  • Every pending frame, and the dropped or replaced frame that ends it, carries sender_verified. Unverified and rejected transactions carry sender_verified: false.
  • Frames that a default (sender_gate=on) client would not receive carry no seq. The seq of the frames you share with gated clients stays gap-free.
  • A transaction can arrive as pending with sender_verified: false and later again with sender_verified: true once its sender is verified. Dedupe on (tx_hash, status, sender_verified) on this connection.
  • A rejected transaction ends with a dropped frame when its pending window expires.

Client pending TTL

By default a pending fill that never settles is closed by the server’s dropped frame. Set pending_ttl (a Go duration such as 10s, clamped to 2s–120s) to close it sooner for your connection only. When your TTL elapses you receive a dropped frame with no seq and a pending_ttl_ms field set to the TTL that fired. The server’s own later dropped for that transaction is suppressed for you, but a later mined or replaced frame is still delivered, so treat a TTL dropped as “stopped waiting”, not “did not settle”.

The fill frame

string
The lifecycle transition (see the table above).
boolean
false for provisional (matched/pending) amounts from calldata; true once log-derived (mined).
boolean
Whether we observed the settle tx in the mempool before the block.
boolean
On pending frames, and the dropped/replaced frame that ends a pending: whether the sender was verified as an exchange operator (see Sender verification). Always present in mode=full. In compact mode it is present only on sender_gate=off connections. Absent when not determined; it is never defaulted to true or false.
integer
Only on a dropped frame produced by your connection’s pending_ttl: the TTL in milliseconds that fired.
string
Which upstream produced this frame: polymarket-clob (a matched signal) or mempool.
string
The Polygon transaction hash — the key you track a fill by.
integer
Per-stream sequence, increasing within a connection; resets when a stream is re-established (a fresh status frame marks the reset).
integer
First mempool observation (unix ms).
integer
When we emitted the frame (unix ms). Subtract from ts_seen to measure your own delivery latency.
array
integer
On mined/reverted: how far ahead of the block we saw the tx in the mempool.
integer
On mined/finalized/reverted: the Polygon block.
boolean
true if re-sent from the recent buffer because you connected with replay=N. Backfill of what you missed; may interleave with the first live frames — dedupe by (tx_hash, status).
Modes. compact (default) omits from/nonce/gas/source and the per-leg signer/fee/order_hash/log_index/title/slug/image; request mode=full for those. owner is present in both modes when known. sender_verified is always present on pending frames in mode=full, and in compact only with sender_gate=off.

Subscribe, unsubscribe, and replay in band

Beyond the query string, manage subscriptions over the socket. replay=N (0–500) backfills up to N recent fills per stream before live frames — so a reconnecting client recovers what it missed.

Filtered subscriptions

The stream names above route by a single dimension (token, market, or wallet). For a compound query — a wallet and a minimum size, or only settled fills in a set of markets — subscribe with a filters object instead. op is accepted as a synonym of type.
The server replies with a subscribed ack carrying a subscription_id; every fill matching that subscription then arrives as a normal fill frame whose stream is the subscription_id:

Filter fields

status accepts the raw lifecycle tokens pending, mined, reverted, finalized, dropped, replaced, reorged, matched, plus three coarse aliases: settled = mined + finalized, reverted = reverted + dropped + reorged, pending = pending + matched.

Logic and semantics

  • OR within a field, AND across fields: {"wallets":["A","B"],"min_notional":"5000"} means (A or B) AND notional ≥ 5000.
  • Any-leg: a settlement matches a token / wallet / min_* clause when some leg satisfies it (the same any-leg rule the stream names use). status is the settlement’s single lifecycle state.
  • Amounts are exact integers — compared against the fill’s base-unit shares / usdc, never a float.
  • Multiple subscriptions per connection, each with its own subscription_id and sequence; a fill matching several of your subscriptions arrives once per matching subscription. Filtered and stream-name subscriptions share the 120-per-connection cap.

Managing a filtered subscription

Replace a subscription’s filter (not reconnecting) or drop it by id:
update_subscription replaces the whole filter; the mempool feed does not take add/remove deltas (a delta is rejected with INVALID_REQUEST rather than silently ignored). Acks: filter_updated, unsubscribed. A bad filter returns INVALID_FILTER and leaves existing subscriptions untouched.

Stream health and errors

A status frame is sent on subscribe and whenever a stream’s health changes:
state is live or degraded; on degraded, reason is one of upstream_disconnected, heads_stale, pending_silent, reorg_depth_exceeded. error frames carry a code: TOO_MANY_STREAMS, BAD_STREAM, UNAUTHORIZED, SLOW_CONSUMER, BAD_MESSAGE, and — for filtered subscriptions — INVALID_FILTER, INVALID_REQUEST, UNKNOWN_SUBSCRIPTION. A client whose send queue backs up is disconnected (SLOW_CONSUMER, close 1013) rather than buffered — one slow consumer never delays another.
  • Live Trades — the authenticated, venue-mirrored trade feed
  • UMA Resolution — the uma:polymarket:* lifecycle over REST + WebSocket
  • Order Books — live books for outcome tokens
  • Data API — cross-reference the owner wallet’s PnL, positions, and history
For splits, merges, redemptions, converts, resolutions and condition/token registration, see the versioned on-chain protocol.