# QS Market Data Feed

## Market Data Update

Updates indicative book or quotes.

{% tabs %}
{% tab title="Event Schema" %}

```json
{
  "event": "marketDataUpdate", // event type, required
  "reqId": <string>, // id of this update, required 
  "instrument": <string>, // name of the instrument, conditionally required
  "streamId": <string>, // id of the quote stream, conditionally required
  "levels": {
    "asks": <array[[uint64,int64]]>, // first element - price, second - size
    "bids": <array[[uint64,int64]]> // first element - price, second - size
  } // book snapshot
}
```

Either `streamId` or `instrument` must be provided. The `instrument` can be used to identify the stream if it is associated with the API key used for the connection.

The maker connection will be closed if the market data (MD) update is invalid.

The price must be greater than 0.

The size must be greater than 0 and rounded to the balance step of the corresponding asset.
{% endtab %}

{% tab title="Event Example" %}

```json
{
  "event": "marketDataUpdate",
  "reqId": "5",
  "streamId": "82de13e8-2f7e-4359-962e-19c104cabe54",
  "levels": {
    "asks": [[100000000, 100000000]],
    "bids": [[1000000000, 1000000000]]
  }
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://faq.finerymarkets.com/api-reference/websocket-api/qs-for-liquidity-providers/qs-market-data-feed.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
