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

# All market contexts

> Perp-only, like GET /api/v1/asset_contexts: the same payload (24h volume, 24h change, open interest, prices) for every perp market, pushed on each state sync (throttled to 1/s). Spot contexts never appear here; they are served by /api/v1/spot/asset_contexts. Global topic; computed in memory from the rolling 24h fill window.



## AsyncAPI

````yaml api-reference/asyncapi.json allMarketContexts
id: allMarketContexts
title: All market contexts
description: >-
  Perp-only, like GET /api/v1/asset_contexts: the same payload (24h volume, 24h
  change, open interest, prices) for every perp market, pushed on each state
  sync (throttled to 1/s). Spot contexts never appear here; they are served by
  /api/v1/spot/asset_contexts. Global topic; computed in memory from the rolling
  24h fill window.
servers:
  - id: testnet
    protocol: wss
    host: api.testnet.aptoslabs.com/decibel/ws
    bindings: []
    variables: []
address: all_market_contexts
parameters: []
bindings: []
operations:
  - &ref_0
    id: receiveallMarketContexts
    title: Receiveall market contexts
    description: >-
      Receive updates for perp-only, like get /api/v1/asset_contexts: the same
      payload (24h volume, 24h change, open interest, prices) for every perp
      market, pushed on each state sync (throttled to 1/s). spot contexts never
      appear here; they are served by /api/v1/spot/asset_contexts. global topic;
      computed in memory from the rolling 24h fill window.
    type: receive
    messages:
      - &ref_1
        id: AllMarketContextsMessage
        payload:
          - name: AllMarketContextsMessage
            description: >-
              Perp-only, like GET /api/v1/asset_contexts: the same payload (24h
              volume, 24h change, open interest, prices) for every perp market,
              pushed on each state sync (throttled to 1/s). Spot contexts never
              appear here; they are served by /api/v1/spot/asset_contexts.
              Global topic; computed in memory from the rolling 24h fill window.
            type: object
            properties:
              - name: contexts
                type: array
                required: true
                properties:
                  - name: mark_price
                    type: number
                    required: true
                  - name: market
                    type: string
                    required: true
                  - name: mid_price
                    type: number
                    required: true
                  - name: open_interest
                    type: number
                    required: true
                  - name: oracle_price
                    type: number
                    required: true
                  - name: previous_day_price
                    type: number
                    required: true
                  - name: price_change_pct_24h
                    type: number
                    required: true
                  - name: volume_24h
                    type: number
                    required: true
              - name: topic
                type: string
                required: true
        headers: []
        jsonPayloadSchema:
          type: object
          required:
            - topic
            - contexts
          properties:
            contexts:
              type: array
              items:
                type: object
                required:
                  - market
                  - volume_24h
                  - open_interest
                  - mark_price
                  - mid_price
                  - oracle_price
                  - previous_day_price
                  - price_change_pct_24h
                properties:
                  mark_price:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-111>
                  market:
                    type: string
                    example: 0xmarket123...
                    x-parser-schema-id: <anonymous-schema-112>
                  mid_price:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-113>
                  open_interest:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-114>
                  oracle_price:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-115>
                  previous_day_price:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-116>
                  price_change_pct_24h:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-117>
                  volume_24h:
                    type: number
                    format: double
                    x-parser-schema-id: <anonymous-schema-118>
                x-parser-schema-id: AssetContextDto
              x-parser-schema-id: <anonymous-schema-110>
            topic:
              type: string
              x-parser-schema-id: <anonymous-schema-119>
          x-parser-schema-id: AllMarketContextsResponse
        title: All market contexts message
        description: >-
          Perp-only, like GET /api/v1/asset_contexts: the same payload (24h
          volume, 24h change, open interest, prices) for every perp market,
          pushed on each state sync (throttled to 1/s). Spot contexts never
          appear here; they are served by /api/v1/spot/asset_contexts. Global
          topic; computed in memory from the rolling 24h fill window.
        example: |-
          {
            "topic": "all_market_contexts",
            "contexts": [
              {
                "market": "BTC/USD",
                "volume_24h": 1250000,
                "open_interest": 125000.5,
                "mark_price": 50120.5,
                "mid_price": 50122.25,
                "oracle_price": 50125.75,
                "previous_day_price": 49000,
                "price_change_pct_24h": 2.29
              }
            ]
          }
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: AllMarketContextsMessage
          - id: x-parser-message-name
            value: AllMarketContextsMessage
    bindings: []
    extensions:
      - id: x-parser-unique-object-id
        value: allMarketContexts
sendOperations:
  - *ref_0
receiveOperations: []
sendMessages:
  - *ref_1
receiveMessages: []
extensions:
  - id: x-parser-unique-object-id
    value: allMarketContexts
securitySchemes: []

````