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

# Token Price History



## OpenAPI

````yaml openapi.json GET /gateway/v1/market/price
openapi: 3.1.0
info:
  title: Hermod
  version: 0.0.1
servers:
  - url: https://api.asksurf.ai
security: []
paths:
  /gateway/v1/market/price:
    get:
      tags:
        - Market
      summary: Token Price History
      description: >-
        Returns historical price data points for a token over a specified time
        range.


        **Time range options:**

        - Predefined: `1d`, `7d`, `14d`, `30d`, `90d`, `180d`, `365d`, `max`

        - Custom: use `from` / `to` (Unix seconds or `YYYY-MM-DD`)


        **Granularity** is automatic based on range:

        - `1d` → 5-minute intervals

        - `7d`–`90d` → hourly

        - `180d`+ → daily
      operationId: market-price
      parameters:
        - description: >-
            Single token ticker symbol like `BTC`, `ETH`, or `SOL` (multi-symbol
            not supported)
          explode: false
          in: query
          name: symbol
          required: true
          schema:
            description: >-
              Single token ticker symbol like `BTC`, `ETH`, or `SOL`
              (multi-symbol not supported)
            examples:
              - BTC
            type: string
        - description: >-
            Predefined time range for historical data. Ignored when `from`/`to`
            are set. Can be `1d`, `7d`, `14d`, `30d`, `90d`, `180d`, `365d`, or
            `max`.
          explode: false
          in: query
          name: time_range
          schema:
            default: 30d
            description: >-
              Predefined time range for historical data. Ignored when
              `from`/`to` are set. Can be `1d`, `7d`, `14d`, `30d`, `90d`,
              `180d`, `365d`, or `max`.
            enum:
              - 1d
              - 7d
              - 14d
              - 30d
              - 90d
              - 180d
              - 365d
              - max
            examples:
              - 30d
            type: string
        - description: >-
            Start of custom date range (Unix timestamp or YYYY-MM-DD). Must be
            used together with `to`. Overrides `time_range` when set.
          explode: false
          in: query
          name: from
          schema:
            description: >-
              Start of custom date range (Unix timestamp or YYYY-MM-DD). Must be
              used together with `to`. Overrides `time_range` when set.
            examples:
              - '2025-01-01'
            type: string
        - description: >-
            End of custom date range (Unix timestamp or YYYY-MM-DD). Must be
            used together with `from`. Overrides `time_range` when set.
          explode: false
          in: query
          name: to
          schema:
            description: >-
              End of custom date range (Unix timestamp or YYYY-MM-DD). Must be
              used together with `from`. Overrides `time_range` when set.
            examples:
              - '2025-03-01'
            type: string
        - description: Quote currency like `usd`, `eur`, or `btc`
          explode: false
          in: query
          name: currency
          schema:
            default: usd
            description: Quote currency like `usd`, `eur`, or `btc`
            examples:
              - usd
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SimpleListResponseMarketMetricPoint'
          description: OK
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DataAPIError'
          description: Error
      security:
        - AccessToken: []
components:
  schemas:
    SimpleListResponseMarketMetricPoint:
      additionalProperties: false
      properties:
        $schema:
          description: A URL to the JSON Schema for this object.
          examples:
            - >-
              https://example.com/schemas/SimpleListResponseMarketMetricPoint.json
          format: uri
          readOnly: true
          type: string
        data:
          items:
            $ref: '#/components/schemas/MarketMetricPoint'
          type:
            - array
            - 'null'
        meta:
          $ref: '#/components/schemas/ObjectResponseMeta'
      required:
        - data
        - meta
      type: object
    DataAPIError:
      additionalProperties: false
      properties:
        $schema:
          description: A URL to the JSON Schema for this object.
          examples:
            - https://example.com/schemas/DataAPIError.json
          format: uri
          readOnly: true
          type: string
        error:
          $ref: '#/components/schemas/DataAPIErrorDetail'
      required:
        - error
      type: object
    MarketMetricPoint:
      additionalProperties: false
      properties:
        metric:
          description: Metric name like `nupl`, `sopr`, or `price`
          type: string
        symbol:
          description: Token symbol this data point belongs to
          type: string
        timestamp:
          description: Unix timestamp in seconds for this data point
          format: int64
          type: integer
        value:
          description: Metric value at this timestamp
          format: double
          type: number
      required:
        - value
        - timestamp
      type: object
    ObjectResponseMeta:
      additionalProperties: false
      properties:
        cached:
          description: Whether this response was served from cache
          type: boolean
        credits_used:
          description: Credits deducted for this request
          format: int64
          type: integer
      required:
        - credits_used
        - cached
      type: object
    DataAPIErrorDetail:
      additionalProperties: false
      properties:
        code:
          type: string
        message:
          type: string
      required:
        - code
        - message
      type: object

````