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

# ABP API Overview - Automated Bet Placing

> ABP v2 API overview. Place bets across 32 bookmakers through a single unified API with smart routing, partial fills, real-time tracking, and automated settlement.

## What is ABP?

The **Automated Bet Placing (ABP)** API by [55-Tech](https://55-tech.com/) lets you place bets across 32 bookmakers through a single integration. Instead of building and maintaining individual bookmaker connectors, ABP handles the entire lifecycle from bet placement through settlement.

**Core capabilities:**

* **Account management** — Full CRUD for bookmaker accounts with priority-based selection, per-account stake limits, and multi-currency support
* **Betslip retrieval** — Get real-time odds and limits for any fixture/outcome across all configured bookmakers before placing
* **Futures support** — Place bets on outright/futures markets using `futureId` and `participantId` (coming soon)
* **Smart order routing** — Place single or bulk orders; ABP automatically selects the best bookmaker by odds and limits
* **Bet tracking** — Monitor every bet from placement through confirmation and settlement with full audit trail
* **Position & PnL analytics** — Aggregated views of exposure and profit/loss grouped by bookmaker, account, or user reference

## Data flow

<Steps>
  <Step title="Discover fixtures & odds via OddsPapi v5">
    Your app consumes the [OddsPapi v5 API](https://docs.oddspapi.io/) to discover fixtures, markets, outcomes, and real-time odds across all supported bookmakers. OddsPapi is the data layer — ABP is the execution layer built on top of it. Fixture IDs and outcome IDs are shared between both APIs.
  </Step>

  <Step title="Fetch betslip from ABP">
    Before placing, call `GET /betslip?fixtureId=...&outcomeId=...&playerId=...` to get aggregated odds and limits from all your configured bookmaker accounts. For futures markets, use `futureId` instead of `fixtureId` along with `participantId`. ABP resolves stake limits (account > bookmaker > odds) and returns the effective min/max per bookmaker.
  </Step>

  <Step title="Place orders through ABP">
    Send `POST /place-orders` with one or more orders. Each order targets either a fixture (`fixtureId`) or a future (`futureId`). ABP routes each order to the best bookmaker(s) based on price, available limits, and account priority. Each bookmaker integration places the bet and reports back confirmation or decline.
  </Step>

  <Step title="Receive real-time updates via WebSocket">
    Connect to `WS /ws` to receive real-time pushes for order status changes, bet confirmations, settlements, balance updates, and system events. No polling needed.
  </Step>

  <Step title="Query history & analytics">
    Use `GET /orders`, `GET /bets` for order/bet history with keyset pagination, and `GET /positions`, `GET /pnl` for aggregated exposure and profit/loss analytics.
  </Step>
</Steps>

## Base URL

```
https://v2.55-tech.com
```

## Key concepts

### Orders vs bets

An **order** is your instruction to place a bet. A **bet** is the actual wager placed on a bookmaker. One order can result in multiple bets when using partial fills or multi-bookmaker routing.

### Request deduplication

Each order requires a unique `requestUuid` (UUID format). ABP uses server-side deduplication (30-minute TTL) to prevent duplicate placements. A duplicate order is silently skipped; if **every** order in a request is a duplicate, the request returns `409 Conflict`.

### Order lifecycle

```
PENDING → PROCESSING → FILLED / PARTIALLY_FILLED / REJECTED / EXPIRED / CANCELLED / FAILED
```

* **PENDING** — Order received and queued
* **PROCESSING** — Routing to bookmakers
* **FILLED** — All stake placed successfully
* **PARTIALLY\_FILLED** — Some stake placed, remaining expired or no capacity
* **REJECTED** — Failed validation (bad odds, invalid fixture, etc.)
* **EXPIRED** — Order `expiresAt` time reached (default: 5 seconds, max: 24 hours)
* **CANCELLED** — Explicitly cancelled by client
* **FAILED** — Internal error during placement

### Bet lifecycle

```
PENDING → PLACED → CONFIRMED / REJECTED / CANCELLED / FAILED / VOID
```

* **PENDING** — Bet created, awaiting bookmaker response
* **PLACED** — Sent to bookmaker, awaiting confirmation
* **CONFIRMED** — Bookmaker accepted the bet
* **REJECTED** — Bookmaker rejected the bet
* **CANCELLED** — Bet cancelled before confirmation
* **FAILED** — Internal error during placement
* **VOID** — Bet voided by bookmaker

### Settlement lifecycle

```
UNSETTLED → WON / LOST / VOID / HALF_WON / HALF_LOST / PUSH / CASHOUT
```

* **UNSETTLED** — Bet is live, awaiting result
* **WON** — Full win
* **LOST** — Full loss
* **VOID** — Bet voided (stake returned)
* **HALF\_WON** — Asian handicap partial win
* **HALF\_LOST** — Asian handicap partial loss
* **PUSH** — Stake returned (tie on the line)
* **CASHOUT** — Early withdrawal at negotiated price

### Account priority

Each bookmaker account has a `priority` field (higher = preferred). When placing an order, ABP selects the highest-priority active account first for each bookmaker.

### Limit cascade

Stake limits are resolved in priority order: **account limits > bookmaker limits > odds limits**.

For example, if an account has `minStake: 10`, the bookmaker default is `minStake: 1`, and the odds entry shows `limitMin: 5`, the effective minimum is `10` (from the account override).

### Futures (coming soon)

ABP supports **futures** (outright) markets alongside standard fixture-based markets. Instead of a `fixtureId`, futures use a `futureId` to identify the outright market and a `participantId` to specify the selection (e.g., a team or player to win a league/tournament).

**Key differences from fixture orders:**

|                   | Fixture orders                           | Futures orders                                        |
| ----------------- | ---------------------------------------- | ----------------------------------------------------- |
| Identifier        | `fixtureId`                              | `futureId`                                            |
| Selection         | `outcomeId` + `playerId`                 | `outcomeId` + `playerId` + `participantId`            |
| Betslip           | `GET /betslip?fixtureId=...`             | `GET /betslip?futureId=...`                           |
| Market key format | `fixtureId:bookmaker:outcomeId:playerId` | `futureId:bookmaker:outcomeId:playerId:participantId` |

**Current status:** The data model and betslip infrastructure are in place. Order placement and betslip retrieval for futures currently return `501 Not Implemented`. This will be enabled in an upcoming release.

### Bookmaker slugs

Bookmakers are identified by slug strings (e.g., `pinnacle`, `betfair-ex`, `polymarket`). Use `GET /bookmakers` to list all 32 supported bookmakers with their default stake limits.

## Endpoints at a glance

| Category       | Endpoints                                                                             | Description                                                         |
| -------------- | ------------------------------------------------------------------------------------- | ------------------------------------------------------------------- |
| **Accounts**   | `GET/POST/PATCH/DELETE /accounts`                                                     | Manage bookmaker accounts (credentials, balances, priority, limits) |
| **Betslip**    | `GET /betslip`                                                                        | Get live odds & limits before placing (fixtures and futures)        |
| **Orders**     | `POST /place-orders`, `POST /cancel-orders`, `POST /cancel-all-orders`, `GET /orders` | Place, cancel, and track orders                                     |
| **Bets**       | `GET /bets`, `GET /bets/{bet_id}`                                                     | View individual bet results                                         |
| **Analytics**  | `GET /positions`, `GET /pnl`                                                          | Aggregated exposure and P\&L                                        |
| **Bookmakers** | `GET /bookmakers`                                                                     | List all supported bookmakers                                       |
| **Markets**    | `GET /markets`                                                                        | Available markets and odds types                                    |
| **WebSocket**  | `WS /ws`                                                                              | Real-time updates                                                   |

## Supported bookmakers

**Traditional sportsbooks:** pinnacle, pinnacleb2b, betamapola, betcris, bookmaker.eu, cloudbet, cloudbetb2b, justbet, kaiyun, matchbook, monkeyline.vip, novig.us, 198bet, paradisewager, sharpbet, singbet, sports411.ag, 3et, 3et++

**Betting exchanges:** betfair-ex, smarkets, limitless-ex

**Prediction markets:** polymarket, polymarket.us, kalshi, predict.fun, prophetx, sx.bet, vertex, 4casters

**Punter platforms:** punter.io, punter.io++

## Resilience

ABP includes production-grade reliability features:

* **Circuit breakers** — Per-bookmaker circuit breakers prevent cascading failures and auto-recover
* **Retry with exponential backoff** — for transient failures
* **Emergency controls** — Orders may be temporarily paused during system maintenance
* **Rate limiting** — Per-API-key rate limits (configurable per client)

## Data source

ABP consumes real-time odds data from [OddsPapi v5](https://docs.oddspapi.io/). Fixture IDs and outcome IDs in ABP correspond directly to OddsPapi identifiers. Your app should use OddsPapi to discover fixtures and markets, then use ABP to execute bets.

## Frequently asked questions

<AccordionGroup>
  <Accordion title="Does ABP hedge or place bets directly?">
    ABP places bets **directly** with bookmakers — it is not a hedging or market-making engine. You send an order, ABP routes it to the best account(s), places the wager, and tracks it through settlement. The data layer is [OddsPapi v5](https://docs.oddspapi.io/); ABP is the execution layer on top.
  </Accordion>

  <Accordion title="What's the difference between an order and a bet?">
    An **order** is your instruction to place a wager. A **bet** is the actual wager placed at a bookmaker. One order can produce multiple bets when partial fills or multi-bookmaker routing apply. See [Concepts](/abp-api/concepts#orders-vs-bets).
  </Accordion>

  <Accordion title="How does idempotency / requestUuid work?">
    Each order carries a unique `requestUuid` (UUID format). ABP deduplicates server-side for **30 minutes** — a duplicate is silently skipped, and if **every** order in a request is a duplicate the request returns `409 Conflict`. Deep dive in [Concepts](/abp-api/concepts#idempotency-request-deduplication).
  </Accordion>

  <Accordion title="Does ABP support partial fills and multi-bookmaker routing?">
    Yes. Set `acceptPartialStake: true` to let a single order fill across multiple bets, and pass a `bookmakers` list (or omit it for auto-selection) to spread across venues. ABP enforces a weighted-average price constraint so your effective price stays at or above `orderPrice`. See [Order Placement](/abp-api/order-placement).
  </Accordion>

  <Accordion title="Which bookmakers are supported?">
    32 bookmakers across traditional sportsbooks, betting exchanges, prediction markets, and punter platforms. Capabilities (sweep, settlement, betslip) vary per venue — see the [Bookmaker capability matrix](/abp-api/bookmakers).
  </Accordion>

  <Accordion title="Can I test without placing real bets?">
    Yes. Set `testOrder: true` to run the full validation and routing path (limits, price checks, account selection) **without** sending a bet to the bookmaker — the fastest way to confirm your payload and IDs before going live. See [Quickstart](/abp-api/quickstart#step-3-place-an-order).
  </Accordion>

  <Accordion title="How reliable is ABP for production trading?">
    ABP runs per-bookmaker circuit breakers, retry with backoff, a two-tier emergency control, and reliable WebSocket delivery with ack/replay. Recovery from disconnects is bounded — reconcile any `seq` gaps via REST. See [Reliability & Operations](/abp-api/reliability).
  </Accordion>
</AccordionGroup>

## 💬 Ask an AI Assistant

Want to explore or ask questions about this API using your favorite AI?

Click one of the links below — each one opens the full docs bundle in the selected tool with a pre-filled prompt:

* [Ask ChatGPT](https://chatgpt.com/?prompt=Read+from+https%3A%2F%2Fdocs.55-tech.com%2Fllms-full.txt+and+help+me+with+this+API.)
* [Ask Claude](https://claude.ai/?prompt=Please+read+https%3A%2F%2Fdocs.55-tech.com%2Fllms-full.txt+and+help+me+use+this+API.)
* [Ask Perplexity](https://www.perplexity.ai/search?q=Read+from+https%3A%2F%2Fdocs.55-tech.com%2Fllms-full.txt)
* [Ask Gemini](https://gemini.google.com/app?query=Read+from+https%3A%2F%2Fdocs.55-tech.com%2Fllms-full.txt+and+help+me+use+this+API.)

## Next steps

<Columns cols={2}>
  <Card title="Authentication" icon="key" href="/abp-api/authentication">
    Set up your API key.
  </Card>

  <Card title="Quickstart" icon="rocket" href="/abp-api/quickstart">
    Place your first bet in 5 steps.
  </Card>

  <Card title="Order Placement" icon="bullseye-arrow" href="/abp-api/order-placement">
    How fills, pricing, and limits work.
  </Card>

  <Card title="Currency & Limits" icon="coins" href="/abp-api/currency">
    Denomination, conversion, and the limit cascade.
  </Card>
</Columns>
