> For the complete documentation index, see [llms.txt](https://developer.aiodds.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.aiodds.com/explore/core-concepts/backup-safe-mode.md).

# Backup Safe Mode

### How It Works

When Backup Safe Mode is activated:

* Existing pre-match and in-play **Bookmaker Odds** for the affected bookmaker are closed.
* AiOdds switches to backup odds for that bookmaker.
* Backup odds continue to update through the normal Bookmaker Odds delivery flow.
* Backup odds are designed to remain accurate and closely aligned with the original bookmaker's markets and odds structure.

This helps operators keep receiving timely odds updates even when the bookmaker source is temporarily unavailable.

### Backup Field

The backup state is indicated by the new `backup` field in the **Bookmaker Odds** data structure.

For protobuf-based delivery, this field is available in `odds.proto`:

```protobuf
1uint32 backup = 18;
```

Field values:

* `backup = 0`: Bookmaker Odds
* `backup = 1`: backup odds

### WebSocket and Snapshot Availability

The `backup` field is available in **Bookmaker Odds** data delivered through:

* Bookmaker Odds WebSocket updates
* Bookmaker Odds snapshot data

For WebSocket users, this means the `backup` field can be monitored in real-time odds updates from the Bookmaker Odds stream.

For snapshot users, this means the `backup` field can also be used when initializing or rebuilding odds state from snapshot data.

### Recommended Usage

Operators can monitor the `backup` field to identify whether odds are coming from the bookmaker source or the backup odds solution.

Recommended handling:

* Treat `backup = 0` as normal Bookmaker Odds.
* Treat `backup = 1` as backup odds.
* Use `backup = 1` as a signal that the bookmaker source may be temporarily unavailable.
* Apply internal risk rules if needed, such as lower limits, manual review, or temporary market protection.
* Log backup periods for operational review and source quality monitoring.

### Summary

Backup Safe Mode improves the continuity of **Bookmaker Odds** delivery by switching supported bookmakers to backup odds when source data is interrupted.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://developer.aiodds.com/explore/core-concepts/backup-safe-mode.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
