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

# Historical

> Provides detailed historical data for options tickers, including price metrics, trading volumes, Greeks, and implied volatility. This endpoint is particularly useful for analyzing past market conditions for specific options on various exchanges.

<Warning>
  The maximum time range (difference between `startDate` and `endDate`) is **1 hour**.
</Warning>

<Note>
  If the `startDate` and `endDate` query parameters are not provided, the API will return the data from the previous 1 hour.
</Note>


## OpenAPI

````yaml get /options/tickers/{instrument}
openapi: 3.1.0
info:
  title: market-api
  version: '2'
servers:
  - url: https://api.amberdata.com/markets
security:
  - ApiKeyAuth: []
paths:
  /options/tickers/{instrument}:
    get:
      summary: Historical
      description: >-
        Provides detailed historical data for options tickers, including price
        metrics, trading volumes, Greeks, and implied volatility. This endpoint
        is particularly useful for analyzing past market conditions for specific
        options on various exchanges.
      operationId: options-tickers-historical
      parameters:
        - name: instrument
          in: path
          description: The instrument for which to retrieve the requested data.
          schema:
            type: string
            default: BTC-27DEC24-100000-C
          required: true
        - name: exchange
          in: query
          description: >-
            The exchange(s) for which to retrieve the requested data (comma
            separated). **[Default]** All available exchanges.
          required: true
          schema:
            type: string
            default: bybit
        - name: startDate
          in: query
          description: >-
            **[Optional]** Payload only includes data after this date
            (inclusive). **[Defaults]** Beginning of the current hour (max time
            range is 1 hour). **[Formats]** `ms* | milliseconds | iso8601`
            **[Examples]** `1578531600 | 1578531600000 | 2020-09-01T01:00:00`
          schema:
            type: string
            format: date-time
        - name: endDate
          in: query
          description: >-
            **[Optional]** Payload only includes data before this date
            (exclusive). **[Defaults]** One hour after the beginning of the
            current hour (max time range is 1 hour). **[Formats]** `seconds |
            milliseconds | iso8601` **[Examples]** `1578531600 | 1578531600000 |
            2020-09-01T01:00:00`
          schema:
            type: string
            format: date-time
        - name: timeFormat
          in: query
          description: >-
            **[Optional]** Time format of the timestamps in the return payload.
            **[Defaults]** `milliseconds | ms* | iso | iso8601 | hr |
            human_readable`
          schema:
            type: string
        - name: sortDirection
          in: query
          description: >-
            **[Optional]** Specifies the direction in which the data is sorted
            (by timestamp).   **[Defaults]** asc (ascending order).   **[Usage
            Conditions]** This parameter can only be used if the `startDate` and
            `endDate` timeframe is within the most recent 24 hours, or if the
            `startDate` and `endDate` parameters are not used at all.  
            **[Examples]** ascending | descending | asc | desc
          schema:
            type: string
        - name: Accept-Encoding
          in: header
          required: true
          description: ''
          schema:
            type: string
            default: gzip, deflate, br
        - name: api-version
          in: header
          schema:
            type: string
      responses:
        '200':
          description: '200'
          content:
            application/json:
              examples:
                Success:
                  value:
                    status: 200
                    title: OK
                    description: Successful request
                    payload:
                      metadata:
                        next: >-
                          https://api.amberdata.com/markets/options/tickers/BTC-16AUG24-50000-C?cursor=N4IgpgHgxgFghgOwOZhALhAIwJ6YJYAuIANCFAK4BOAzgPaXoLkA2zp1BclBAInAajQBGAOwAmCQDYAzNICscgAxjppMAgAmfAelETpAFnGSAnAA5ZpPAijNyGsAFUE1cgAc39ARoCi0eMhg1OgAZnDM1GCkBHgAtmAAYvSx-OggsXiseJFQtJrBpCHJqRgAVnQIJCB03ADSYNhpelKyCsrSAPqKHTj4BF0dAEIAKgDCALRCkgCCjgDiYgbjSoqr46MgAL5AA
                        api-version: '2023-09-30'
                      data:
                        - instrument: BTC-16AUG24-50000-C
                          exchange: bybit
                          exchangeTimestamp: 1722260870023
                          exchangeTimestampNanoseconds: 0
                          bid: 0
                          mid: 0
                          ask: 0
                          last: 0
                          bidVolume: 0
                          askVolume: 0
                          lastVolume: null
                          baseVolume: null
                          quoteVolume: null
                          sequence: null
                          underlyingPrice: 69793.36
                          underlyingIndex: null
                          settlementPrice: null
                          markPrice: 19806.40225084
                          low: 0
                          high: 0
                          volume: 0
                          volumeUSD: null
                          priceChange: 0
                          openInterest: 0
                          minPrice: null
                          maxPrice: null
                          markIv: 0.5997
                          interestRate: null
                          indexPrice: 69398.4
                          rho: null
                          vega: 2.16053057
                          delta: 0.99516469
                          gamma: 0.00000152
                          theta: -3.64786985
                          bidIv: 0
                          askIv: 0
                          estimatedDeliveryPrice: null
                          state: null
                          askTimestamp: null
                          bidTimestamp: null
                          askTimestampNanoseconds: null
                          bidTimestampNanoseconds: null
              schema:
                oneOf:
                  - title: Success
                    type: object
                    properties:
                      status:
                        type: integer
                        example: 200
                        default: 0
                      title:
                        type: string
                        example: OK
                      description:
                        type: string
                        example: Successful request
                      payload:
                        type: object
                        properties:
                          metadata:
                            type: object
                            properties:
                              next:
                                type: string
                                example: >-
                                  https://api.amberdata.com/markets/options/tickers/BTC-16AUG24-50000-C?cursor=N4IgpgHgxgFghgOwOZhALhAIwJ6YJYAuIANCFAK4BOAzgPaXoLkA2zp1BclBAInAajQBGAOwAmCQDYAzNICscgAxjppMAgAmfAelETpAFnGSAnAA5ZpPAijNyGsAFUE1cgAc39ARoCi0eMhg1OgAZnDM1GCkBHgAtmAAYvSx-OggsXiseJFQtJrBpCHJqRgAVnQIJCB03ADSYNhpelKyCsrSAPqKHTj4BF0dAEIAKgDCALRCkgCCjgDiYgbjSoqr46MgAL5AA
                              api-version:
                                type: string
                                example: '2023-09-30'
                          data:
                            type: array
                            items:
                              type: object
                              properties:
                                instrument:
                                  type: string
                                  example: BTC-16AUG24-50000-C
                                exchange:
                                  type: string
                                  example: bybit
                                exchangeTimestamp:
                                  type: integer
                                  example: 1722260870023
                                  default: 0
                                exchangeTimestampNanoseconds:
                                  type: integer
                                  example: 0
                                  default: 0
                                bid:
                                  type: integer
                                  example: 0
                                  default: 0
                                mid:
                                  type: integer
                                  example: 0
                                  default: 0
                                ask:
                                  type: integer
                                  example: 0
                                  default: 0
                                last:
                                  type: integer
                                  example: 0
                                  default: 0
                                bidVolume:
                                  type: integer
                                  example: 0
                                  default: 0
                                askVolume:
                                  type: integer
                                  example: 0
                                  default: 0
                                lastVolume: {}
                                baseVolume: {}
                                quoteVolume: {}
                                sequence: {}
                                underlyingPrice:
                                  type: number
                                  example: 69793.36
                                  default: 0
                                underlyingIndex: {}
                                settlementPrice: {}
                                markPrice:
                                  type: number
                                  example: 19806.40225084
                                  default: 0
                                low:
                                  type: integer
                                  example: 0
                                  default: 0
                                high:
                                  type: integer
                                  example: 0
                                  default: 0
                                volume:
                                  type: integer
                                  example: 0
                                  default: 0
                                volumeUSD: {}
                                priceChange:
                                  type: integer
                                  example: 0
                                  default: 0
                                openInterest:
                                  type: integer
                                  example: 0
                                  default: 0
                                minPrice: {}
                                maxPrice: {}
                                markIv:
                                  type: number
                                  example: 0.5997
                                  default: 0
                                interestRate: {}
                                indexPrice:
                                  type: number
                                  example: 69398.4
                                  default: 0
                                rho: {}
                                vega:
                                  type: number
                                  example: 2.16053057
                                  default: 0
                                delta:
                                  type: number
                                  example: 0.99516469
                                  default: 0
                                gamma:
                                  type: number
                                  example: 0.00000152
                                  default: 0
                                theta:
                                  type: number
                                  example: -3.64786985
                                  default: 0
                                bidIv:
                                  type: integer
                                  example: 0
                                  default: 0
                                askIv:
                                  type: integer
                                  example: 0
                                  default: 0
                                estimatedDeliveryPrice: {}
                                state: {}
                                askTimestamp: {}
                                bidTimestamp: {}
                                askTimestampNanoseconds: {}
                                bidTimestampNanoseconds: {}
      deprecated: false
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````