Skip to main content
Official client for the REST API. It covers the same surface as /v1 with typed responses, cursor iterators, and retries. Package: polymarketdata-sdk

Install

Dataframe helpers:

Authenticate

Pass the key, or set POLYMARKETDATA_API_KEY.

Surface map

Discovery to history

Resolutions

These match the API resolution enum:
  • Resolution.ONE_MIN (1m)
  • Resolution.TEN_MIN (10m)
  • Resolution.ONE_HOUR (1h)
  • Resolution.SIX_HOUR (6h)
  • Resolution.ONE_DAY (1d)

Dataframes

If you installed polymarketdata-sdk[dataframe]:
  • to_dataframe_metrics(...)
  • to_dataframe_prices(...)
  • to_dataframe_books(...)

Errors and retries

All SDK exceptions inherit from PolymarketDataError. The client retries 429 and 5xx with exponential backoff and jitter. Tune max_retries, retry_backoff_base, retry_backoff_max, and timeout on PolymarketDataClient.

Response metadata

SDK responses include:
  • .meta — HTTP metadata such as status_code and request_id
  • .raw — unmodified payload