> ## Documentation Index
> Fetch the complete documentation index at: https://docs.polyorderbooks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get token price history

> Get historical prices (probabilities from 0.0 to 1.0) for a specific token.

**Pagination limits:**
- Default `limit`: 100 points per page
- Maximum `limit`: 200 points per page
- Use `cursor` from `metadata.next_cursor` to fetch the next page

**Aggregation:** Prices are averaged when aggregating to higher resolutions.

**Format:** JSON only.



## OpenAPI

````yaml /openapi.json get /v1/tokens/{token_id}/prices
openapi: 3.1.0
info:
  title: PolyOrderbooks API
  description: >
    # PolyOrderbooks API


    Historical Polymarket **crypto** market data — discovery, prices, liquidity
    metrics, and L2 order books. Read paths query our historical data store;
    they never call Polymarket live.


    ## Base URL


    `https://api.polyorderbooks.com`


    ## Authentication


    All `/v1/*` data routes require an API key.


    Send `X-API-Key: pob_…` or `Authorization: Bearer pob_…`. Dashboard JWT
    session tokens are **not** accepted on data routes.


    ## Plans (hosted)


    | Plan | Req/min | Req/day | Finest resolution | History |

    | --- | --- | --- | --- | --- |

    | Starter | 60 | 1,000 | 60s | 7 days |

    | Pro | 300 | 50,000 | 1s | 31 days |

    | Scale | 1,000 | 200,000 | 1s | 90 days |


    ## Workflow


    1. `GET /v1/markets` — discover

    2. `GET /v1/markets/{id_or_slug}` — detail

    3. `GET /v1/markets/{id_or_slug}/books` — history
  version: 0.1.0
servers:
  - url: https://api.polyorderbooks.com
    description: Production
security: []
tags:
  - name: Discovery
    description: >-
      Discover series, events, and markets. Use returned ids or slugs in History
      endpoints.
  - name: History
    description: Historical metrics, prices, and L2 order book snapshots.
  - name: Utility
    description: Usage and account metadata.
paths:
  /v1/tokens/{token_id}/prices:
    get:
      tags:
        - History
      summary: Get token price history
      description: >-
        Get historical prices (probabilities from 0.0 to 1.0) for a specific
        token.


        **Pagination limits:**

        - Default `limit`: 100 points per page

        - Maximum `limit`: 200 points per page

        - Use `cursor` from `metadata.next_cursor` to fetch the next page


        **Aggregation:** Prices are averaged when aggregating to higher
        resolutions.


        **Format:** JSON only.
      operationId: get_token_prices_v1_tokens__token_id__prices_get
      parameters:
        - name: token_id
          in: path
          required: true
          schema:
            type: string
            minLength: 1
            maxLength: 200
            description: Token ID.
            examples:
              - '12345'
            title: Token Id
          description: Token ID.
        - name: start_ts
          in: query
          required: true
          schema:
            type: string
            description: Inclusive range start. Accepts ISO 8601 timestamp or Unix seconds.
            examples:
              - '2025-09-01T00:00:00Z'
              - '1756684800'
            title: Start Ts
          description: Inclusive range start. Accepts ISO 8601 timestamp or Unix seconds.
        - name: end_ts
          in: query
          required: true
          schema:
            type: string
            description: Exclusive range end. Accepts ISO 8601 timestamp or Unix seconds.
            examples:
              - '2025-09-05T00:00:00Z'
              - '1757030400'
            title: End Ts
          description: Exclusive range end. Accepts ISO 8601 timestamp or Unix seconds.
        - name: resolution
          in: query
          required: true
          schema:
            $ref: '#/components/schemas/Resolution'
            description: Aggregation bucket size.
          description: Aggregation bucket size.
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            description: >-
              Maximum number of points to return in this page. Default: 100,
              max: 200.
            examples:
              - 100
            default: 100
            title: Limit
          description: >-
            Maximum number of points to return in this page. Default: 100, max:
            200.
        - name: cursor
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Opaque cursor from a previous response metadata.next_cursor.
            title: Cursor
          description: Opaque cursor from a previous response metadata.next_cursor.
      responses:
        '200':
          description: Historical prices for a single token.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PricesResponseSingleToken'
        '400':
          description: Invalid timestamp format, limit, or cursor.
          content:
            application/json:
              examples:
                invalid_limit:
                  value:
                    detail: 'limit too large. Requested: 201, Maximum: 200'
                invalid_cursor:
                  value:
                    detail: Invalid pagination cursor
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: API key is missing, invalid, or expired.
          content:
            application/json:
              example:
                detail: Invalid or expired API key.
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: >-
            Plan does not allow the requested data point, granularity, or date
            range.
          content:
            application/json:
              example:
                detail: Your plan does not allow historical order books.
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Requested resource (market or token) was not found.
          content:
            application/json:
              examples:
                market:
                  value:
                    detail: 'Market not found: 618831'
                token:
                  value:
                    detail: 'Token not found: 12345'
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation error for one or more request parameters.
          content:
            application/json:
              example:
                detail:
                  - loc:
                      - query
                      - resolution
                    msg: >-
                      Unsupported resolution '2m'. Allowed: 10m, 15m, 1d, 1h,
                      1m, 1s, 5m, 60s, 6h
                    type: enum
        '429':
          description: Rate limit exceeded for the current API key.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                detail: Rate limit exceeded. Please try again later.
        '500':
          description: Unexpected server-side error.
          content:
            application/json:
              example:
                detail: Failed to fetch data.
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    Resolution:
      type: string
      enum:
        - 1s
        - 1m
        - 5m
        - 10m
        - 15m
        - 1h
        - 6h
        - 1d
      title: Resolution
      description: Supported time resolutions for historical endpoints.
    PricesResponseSingleToken:
      properties:
        market_id:
          type: string
          title: Market Id
          description: Canonical market ID.
          examples:
            - '618831'
        token_id:
          type: string
          title: Token Id
          description: Requested token ID.
          examples:
            - '12345'
        token_label:
          type: string
          title: Token Label
          description: Human-readable token label.
          examples:
            - 'Yes'
        resolution:
          type: string
          title: Resolution
          description: Applied resolution.
          examples:
            - 1h
        data:
          items:
            $ref: '#/components/schemas/PriceDataPoint'
          type: array
          title: Data
          description: Chronological time series points for the selected token.
        metadata:
          $ref: '#/components/schemas/HistoryPageMetadata'
          description: Pagination metadata for this history page.
      type: object
      title: PricesResponseSingleToken
      description: Response for `GET /tokens/{token_id}/prices`.
      example:
        data:
          - p: 0.71
            t: '2025-09-05T10:00:00Z'
          - p: 0.73
            t: '2025-09-05T11:00:00Z'
        market_id: '618831'
        metadata:
          count: 2
          limit: 100
        resolution: 1h
        token_id: '12345'
        token_label: 'Yes'
    ErrorResponse:
      properties:
        detail:
          type: string
          title: Detail
          description: Human-readable error description.
      type: object
      title: ErrorResponse
      description: Generic API error response.
    PriceDataPoint:
      properties:
        t:
          type: string
          format: date-time
          title: T
          description: Bucket timestamp in ISO 8601 format.
          examples:
            - '2025-09-05T12:00:00Z'
        p:
          type: number
          title: P
          description: Token price/probability between 0.0 and 1.0.
          examples:
            - 0.73
      type: object
      title: PriceDataPoint
      description: Single token price data point.
    HistoryPageMetadata:
      properties:
        count:
          type: integer
          title: Count
          description: Number of points returned in this page.
        limit:
          type: integer
          title: Limit
          description: Effective page limit used for this response.
        next_cursor:
          anyOf:
            - type: string
            - type: 'null'
          title: Next Cursor
          description: Opaque cursor for the next page. Null when the page is complete.
      type: object
      title: HistoryPageMetadata
      description: Pagination metadata for history responses.

````