> ## 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 market details

> Get detailed information about a specific market by ID or slug.

Returns full market information, including tokens, description, and resolution status.



## OpenAPI

````yaml /openapi.json get /v1/markets/{id_or_slug}
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/markets/{id_or_slug}:
    get:
      tags:
        - Discovery
      summary: Get market details
      description: >-
        Get detailed information about a specific market by ID or slug.


        Returns full market information, including tokens, description, and
        resolution status.
      operationId: get_market_detail_v1_markets__id_or_slug__get
      parameters:
        - name: id_or_slug
          in: path
          required: true
          schema:
            type: string
            minLength: 1
            maxLength: 200
            description: Market ID or market slug.
            examples:
              - '618831'
            title: Id Or Slug
          description: Market ID or market slug.
      responses:
        '200':
          description: Detailed market object with tokens and resolution metadata.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MarketDetailResponse'
        '401':
          description: API key is missing, invalid, or expired.
          content:
            application/json:
              example:
                detail: Invalid or expired API key.
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Market ID/slug does not exist.
          content:
            application/json:
              example:
                detail: 'Market not found: nonexistent_market_id'
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: Validation error for one or more request parameters.
          content:
            application/json:
              example:
                detail:
                  - loc:
                      - query
                      - limit
                    msg: Input should be less than or equal to 1000
                    type: less_than_equal
        '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:
    MarketDetailResponse:
      properties:
        id:
          type: string
          title: Id
          description: Unique market identifier.
          examples:
            - '618831'
        slug:
          type: string
          title: Slug
          description: Stable URL-friendly market slug.
          examples:
            - will-candidate-x-win-2025
        question:
          anyOf:
            - type: string
            - type: 'null'
          title: Question
          description: Human-readable market question.
          examples:
            - Will Candidate X win the 2025 election?
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: Long-form market description, if available.
          examples:
            - Resolves to YES if Candidate X wins the 2025 election.
        status:
          type: string
          title: Status
          description: Current market status.
          examples:
            - open
        start_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Start Date
          description: Market start timestamp in ISO 8601 format.
          examples:
            - '2025-09-01T00:00:00Z'
        end_date:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: End Date
          description: Market end timestamp in ISO 8601 format.
          examples:
            - '2025-11-05T23:59:59Z'
        closed_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Closed At
          description: Timestamp when the market was closed.
          examples:
            - '2025-11-06T03:00:00Z'
        resolved_token_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolved Token Id
          description: Winning token identifier when market is resolved.
          examples:
            - '12345'
        resolved_token_label:
          anyOf:
            - type: string
            - type: 'null'
          title: Resolved Token Label
          description: Winning token label when market is resolved.
          examples:
            - 'Yes'
        tokens:
          items:
            $ref: '#/components/schemas/TokenInfo'
          type: array
          title: Tokens
          description: All tokens for the market.
      type: object
      title: MarketDetailResponse
      description: Detailed response for `GET /markets/{id_or_slug}`.
      example:
        description: Resolves to YES if Candidate X wins the 2025 election.
        end_date: '2025-11-05T23:59:59Z'
        id: '618831'
        question: Will Candidate X win the 2025 election?
        slug: will-candidate-x-win-2025
        start_date: '2025-09-01T00:00:00Z'
        status: open
        tokens:
          - id: '12345'
            label: 'Yes'
          - id: '12346'
            label: 'No'
    ErrorResponse:
      properties:
        detail:
          type: string
          title: Detail
          description: Human-readable error description.
      type: object
      title: ErrorResponse
      description: Generic API error response.
    TokenInfo:
      properties:
        id:
          type: string
          title: Id
          description: Unique token identifier.
          examples:
            - '12345'
        label:
          type: string
          title: Label
          description: Human-readable token label shown to users.
          examples:
            - 'Yes'
      type: object
      title: TokenInfo
      description: Token metadata for a market.

````