watchers

WATCHER: get a signed callback when a Polymarket outcome's...

WATCHER: get a signed callback when a Polymarket outcome's implied probability crosses a level. Arm once, pay once. Pass conditionId (the market's condition id) and outcomeIndex (0 = first outcome, usually Yes). conditionType 'above'/'below'; threshold is a probability 0–1 (e.g. 0.8). Fires once per crossing; bounded by maxFires/expiry. Prices via Polymarket. Signed (verify offline) + retried; recoverable via watchers.status. Returns a watcherId.

post/api/watchers/prediction-market

Request

  • Base URL: https://2s.io
  • URL: https://2s.io/api/watchers/prediction-market
  • Auth: API key in header PAYMENT-SIGNATURE

Request body

conditionIdstring required

Polymarket market conditionId (from predict.market / predict.markets).

outcomeIndexinteger

Which outcome to watch (0 = first, usually Yes). Default 0.

conditionType'above' | 'below' required

Fire when the probability goes above or below the threshold.

thresholdnumber required

Probability 0–1 to cross, e.g. 0.8.

callbackUrlstring uri required

Signed event POSTed here (verify X-2s-Signature). Any http(s) URL.

payloadobject

Arbitrary JSON echoed back in every callback.

expiresInSecondsinteger

Active window in seconds (default 30d, max 90d).

maxFiresinteger

Stop after this many callbacks (default 1).

labelstring

Optional free-text tag.

Response

(unresolved $ref)

Changes

No recorded changes to this operation across all 1 revision of this API.