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

# Oracle prices

> > **Endpoint:** `wss://api.testnet.arcus.xyz/v1/ws` — one socket multiplexes every channel and RPC request. Click **Connect**, then send the example subscribe message below to start receiving data.

Per-market oracle price updates sourced from the on-chain slinky aggregator. Pushes a new price on each oracle update.




## AsyncAPI

````yaml api-reference/asyncapi.yaml oraclePrices
id: oraclePrices
title: Oracle prices
description: >
  > **Endpoint:** `wss://api.testnet.arcus.xyz/v1/ws` — one socket multiplexes
  every channel and RPC request. Click **Connect**, then send the example
  subscribe message below to start receiving data.


  Per-market oracle price updates sourced from the on-chain slinky aggregator.
  Pushes a new price on each oracle update.
servers:
  - id: testnet
    protocol: wss
    host: api.testnet.arcus.xyz
    bindings: []
    variables: []
  - id: mainnet
    protocol: wss
    host: api.arcus.xyz
    bindings: []
    variables: []
address: /v1/ws?channel=oraclePrices
parameters: []
bindings: []
operations:
  - &ref_2
    id: subscribeOraclePrices
    title: Subscribe oracle prices
    type: receive
    messages:
      - &ref_4
        id: subscribe
        contentType: application/json
        payload:
          - name: Subscribe to a market channel
            type: object
            properties:
              - name: type
                type: string
                description: subscribe
                required: true
              - name: channel
                type: string
                enumValues:
                  - trades
                  - oraclePrices
                  - bbo
                required: true
              - name: id
                type: string
                description: Market display name (e.g. "BTC-USD").
                required: true
        headers: []
        jsonPayloadSchema:
          type: object
          required:
            - type
            - channel
            - id
          properties:
            type:
              type: string
              const: subscribe
              x-parser-schema-id: <anonymous-schema-37>
            channel:
              type: string
              enum:
                - trades
                - oraclePrices
                - bbo
              x-parser-schema-id: <anonymous-schema-38>
            id:
              type: string
              description: Market display name (e.g. "BTC-USD").
              example: BTC-USD
              x-parser-schema-id: <anonymous-schema-39>
          x-parser-schema-id: SubscribeByMarketPayload
        title: Subscribe to a market channel
        example: |-
          {
            "type": "subscribe",
            "channel": "trades",
            "id": "BTC-USD"
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: subscribe
    bindings: []
    extensions: &ref_1
      - id: x-parser-unique-object-id
        value: oraclePrices
  - &ref_3
    id: receiveOraclePrices
    title: Receive oracle prices
    type: send
    messages:
      - &ref_5
        id: update
        contentType: application/json
        payload:
          - allOf: &ref_0
              - type: object
                description: Common envelope for all server-pushed channel messages.
                required:
                  - type
                  - channel
                properties:
                  type:
                    type: string
                    enum:
                      - subscribed
                      - channel_data
                    description: >-
                      `subscribed` for the initial snapshot; `channel_data` for
                      updates.
                    x-parser-schema-id: <anonymous-schema-5>
                  channel:
                    type: string
                    description: Channel name.
                    x-parser-schema-id: <anonymous-schema-6>
                  id:
                    type: string
                    description: >-
                      Channel id (market or address). Absent for global
                      channels.
                    x-parser-schema-id: <anonymous-schema-7>
                  contents:
                    type: object
                    additionalProperties: true
                    description: Channel-specific payload. Schema varies by channel.
                    properties: {}
                    x-parser-schema-id: <anonymous-schema-8>
                x-parser-schema-id: ChannelDataEnvelope
              - type: object
                properties:
                  type:
                    const: channel_data
                    x-parser-schema-id: <anonymous-schema-90>
                  contents:
                    type: object
                    required:
                      - epochSeconds
                      - prices
                    properties:
                      epochSeconds:
                        type: integer
                        format: int64
                        description: Unix timestamp in seconds for the batch.
                        example: 1780410803
                        x-parser-schema-id: <anonymous-schema-92>
                      prices:
                        type: array
                        description: One entry per market updated in this batch.
                        items:
                          type: object
                          required:
                            - marketDisplayName
                            - marketId
                            - price
                            - markPrice
                          properties:
                            marketDisplayName:
                              type: string
                              description: Display name / ticker (e.g. "BTC-USD").
                              example: SLV-USD
                              x-parser-schema-id: <anonymous-schema-95>
                            marketId:
                              type: integer
                              minimum: 0
                              maximum: 65535
                              description: Perpetual market identifier (uint16).
                              example: 20
                              x-parser-schema-id: <anonymous-schema-96>
                            price:
                              type: string
                              description: Latest oracle price (decimal string).
                              example: '68.39'
                              x-parser-schema-id: <anonymous-schema-97>
                            markPrice:
                              type: string
                              description: >
                                Authoritative mark price stamped by go-core
                                (decimal string). "0" means unavailable; callers
                                must not fall back to `price`.
                              example: '68.39'
                              x-parser-schema-id: <anonymous-schema-98>
                          x-parser-schema-id: <anonymous-schema-94>
                        x-parser-schema-id: <anonymous-schema-93>
                    x-parser-schema-id: <anonymous-schema-91>
                x-parser-schema-id: <anonymous-schema-89>
            x-parser-schema-id: OraclePricesUpdatePayload
            name: Oracle Price Update
        headers: []
        jsonPayloadSchema:
          allOf: *ref_0
          x-parser-schema-id: OraclePricesUpdatePayload
        title: Oracle Price Update
        example: |-
          {
            "type": "channel_data",
            "channel": "oraclePrices",
            "contents": {
              "epochSeconds": 1780410803,
              "prices": [
                {
                  "marketDisplayName": "SLV-USD",
                  "marketId": 20,
                  "price": "68.39",
                  "markPrice": "68.39"
                },
                {
                  "marketDisplayName": "BTC-USD",
                  "marketId": 1,
                  "price": "94501.00",
                  "markPrice": "94500.50"
                }
              ]
            }
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: update
    bindings: []
    extensions: *ref_1
sendOperations:
  - *ref_2
receiveOperations:
  - *ref_3
sendMessages:
  - *ref_4
receiveMessages:
  - *ref_5
extensions:
  - id: x-parser-unique-object-id
    value: oraclePrices
securitySchemes: []

````