CLOB Read (Public)
Get Neg Risk Query
PM-compat query-string alias for GET /v1/neg-risk/{token_id}.
GET
Get Neg Risk Query
Query Parameters
PM-compat round 2 (audit 2026-05-19 AF-5): py-clob-client builds the neg-risk URL as {host}/neg-risk?token_id=X (hardcoded query form). Polysim historically exposed only the path form /v1/neg-risk/{token_id}, which 404'd.
Response
Successful Response
Previous
Get Neg RiskPolymarket-compat ``GET /neg-risk/{token_id}``.
Returns whether the market routes through Polymarket's
negative-risk contract — the REAL upstream flag, not a stub.
PM-compat P1 batch (eval 2026-06-10, pm-compat finding): this
endpoint hardcoded ``false`` while polysim's own ``/v1/book``
reported ``neg_risk: true`` for the same token (the book passes
the upstream payload through). An SDK port branching on
``get_neg_risk()`` — e.g. to pick the neg-risk exchange adapter or
filter mutually-exclusive event groups — got data that contradicted
the book one call earlier. Single source now: the upstream CLOB
book payload, with fallbacks.
Resolution cascade:
1. Live CLOB ``/book`` payload's ``neg_risk`` bool (same source
``GET /v1/book`` serializes).
2. Last-known cached book (``orderbook:`` / ``clob:book:`` Redis
layers) when the live fetch blips.
3. Catalog classification off the market row's tags/category
(``_classify_neg_risk``) when no book is available at all.
4. ``404 {"error": "market not found"}`` — PM's live message
verbatim (probed 2026-06-11) — when the token resolves to no
known market.
Note: sim EXECUTION semantics don't change for neg-risk markets —
we report the real flag so routing/branching code behaves like it
would against PM, but fills still settle per the standard binary
flow (documented divergence).
Next
Get Neg Risk Query