> This page is for WebSocket.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://okx-demo.ferndocs.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://okx-demo.ferndocs.com/_mcp/server.

# Estimated Price

GET /ws/v5/public

Reference: https://okx-demo.ferndocs.com/ws/web-socket-api/estimated-price/estimated-price

## AsyncAPI Specification

```yaml
asyncapi: 2.6.0
info:
  title: Estimated Price
  version: subpackage_estimated-price.estimated-price
channels:
  /ws/v5/public:
    publish:
      operationId: subpackage_estimated-price.estimated-price-publish
      summary: Server message
      message:
        name: subscribe
        payload:
          $ref: '#/components/schemas/estimatedPrice_EstimatedPricePush'
    subscribe:
      operationId: subpackage_estimated-price.estimated-price-subscribe
      summary: Client message
      message:
        name: publish
        payload:
          $ref: '#/components/schemas/estimatedPrice_EstimatedPriceRequest'
servers:
  Production:
    url: wss://ws.okx.com:8443/
    protocol: wss
    x-default: true
components:
  schemas:
    estimatedPrice_EstimatedPriceArg:
      type: object
      properties:
        channel:
          type: string
          description: Channel name.
        instType:
          type: string
          description: Subscription filter, echoed back.
        instFamily:
          type: string
          description: Subscription filter, echoed back.
      required:
        - channel
      title: EstimatedPriceArg
    estimatedPrice_EstimatedPriceData:
      type: object
      properties:
        instType:
          type: string
          description: Instrument type, FUTURES or OPTION.
        instId:
          type: string
          description: Instrument ID, e.g. BTC-USD-200214.
        settlePx:
          type: string
          description: Estimated delivery/exercise price.
        ts:
          type: string
          description: Data return time, Unix timestamp in milliseconds.
      description: One estimated-price data element.
      title: EstimatedPriceData
    estimatedPrice_EstimatedPricePush:
      type: object
      properties:
        arg:
          $ref: '#/components/schemas/estimatedPrice_EstimatedPriceArg'
          description: Subscribed channel, echoed back.
        data:
          type: array
          items:
            $ref: '#/components/schemas/estimatedPrice_EstimatedPriceData'
          description: >-
            Subscribed data, pushed on update. For candlesticks each element is
            a string array [ts, o, h, l, c, ...].
        event:
          type: string
          description: >-
            On subscription acknowledgments and errors: `subscribe`,
            `unsubscribe`, or `error`.
        id:
          type: string
          description: Request ID, echoed on acknowledgments and errors.
        code:
          type: string
          description: Error code (error events only).
        msg:
          type: string
          description: Error message (error events only).
        connId:
          type: string
          description: WebSocket connection ID.
      description: >-
        Estimated delivery price of a FUTURES contract or exercise price of an
        OPTION; only available and pushed within the last hour before
        delivery/exercise.
      title: EstimatedPricePush
    estimatedPrice_EstimatedPriceSubArg:
      type: object
      properties:
        channel:
          type: string
          description: Channel name.
        instType:
          type: string
          description: Instrument type.
        instId:
          type: string
          description: >-
            Instrument ID, e.g. BTC-USD-200214. Either instId or instFamily is
            required.
        instFamily:
          type: string
          description: >-
            Instrument family, e.g. BTC-USD. Either instId or instFamily is
            required.
      required:
        - channel
      title: EstimatedPriceSubArg
    estimatedPrice_EstimatedPriceRequest:
      type: object
      properties:
        op:
          type: string
          description: Operation. `subscribe` or `unsubscribe`.
        args:
          type: array
          items:
            $ref: '#/components/schemas/estimatedPrice_EstimatedPriceSubArg'
          description: Channels to subscribe to.
      required:
        - op
        - args
      description: Subscribe to the estimated-price channel.
      title: EstimatedPriceRequest

```