Developer guides
Step-by-step guides for building on the Diamond Exch API API. Every field and endpoint is in the API reference, and runnable examples in Node, Python, PHP and curl are on GitHub.
All guides
- Back and lay odds explained for exchange sites: How back and lay prices work on a betting exchange: decimal odds, available size, the price ladder, profit and liability, and how to read them from an odds API.
- Live exchange odds over SSE: a working client: Build a live exchange odds client with Server-Sent Events: snapshots, market updates, reconnecting without gaps and heartbeats, in Node and Python.
- Polling or streaming: how to fetch live odds: Should your betting site poll an odds API or keep a live stream open? Costs, latency and a working polling loop with ETags and a changes feed.
- Settling exchange bets from a results feed: Settle match odds and bookmaker bets automatically from a results feed: winners, voids, corrections and catching up after downtime, with code.