# Keep Alive

Keep-alive messages are sent every 30 seconds and contain an array of live fixture IDs, **scoped to your in-play packages** - only fixtures you have ordered, and **only those with markets based on your odds settings configuration**. This message is used for discrepancy tests: you can compare the `ActiveEvent` list against your own records to detect missing or unexpected fixtures. The following fixture statuses are **included** in the Keep Alive message:

* **NSY** (Not Started Yet)
* **InProgress**
* **Postponed**
* **Interrupted**
* **LostCoverage**
* **AboutToStart**

`Note: When there are no events available (no orders/no live events), an empty KeepAlive message will be sent.`

{% tabs %}
{% tab title="JSON" %}

```json
{
   "KeepAlive": {
      "ActiveEvent": [
         "1234",
         "1111",
         "6213",
         "4021"
      ]
   }
}
```

{% endtab %}

{% tab title="XML" %}

```xml
<KeepAlive>
  <ActiveEvent>1234</ActiveEvent>
  <ActiveEvent>1111</ActiveEvent>
  <ActiveEvent>6213</ActiveEvent>
  <ActiveEvent>4021</ActiveEvent>
</KeepAlive>
```

{% endtab %}
{% endtabs %}

### **Model**

| **Element** | **Data Type** | **Description**           |
| ----------- | ------------- | ------------------------- |
| ActiveEvent | int           | FixtureId of a live event |


---

# 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://docs.lsports.eu/u/trade/integration/message-structure/keep-alive.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.
