Read a game's rules
const url = 'https://api.thebgdb.org/v1/games/5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77/rules?edition=5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77%3Aoriginal&lang=fr';const options = {method: 'GET'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.thebgdb.org/v1/games/5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77/rules?edition=5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77%3Aoriginal&lang=fr'A game’s rules in plain words, for one edition and language, in up to six sections: summary, setup, turn, end of game, scoring and variants. Written by members, or drafted from an approved rulebook in our own words and checked by a moderator before it shows. editions lists every edition with the languages it has rules in.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The game’s id, as returned in every game object. The game’s slug is accepted too.
Example
5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77Query Parameters
Section titled “Query Parameters”An edition’s id from editions. Without it, the game’s original edition.
Example
5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77:originalA language code such as “en”, “fr” or “pt-BR”.
The language wanted. When the edition has no rules in it: its base language, then English, then the first in alphabetical order.
Example
frResponses
Section titled “Responses”The rules, and the editions to choose from.
object
object
object
Its address under the game (GET /games/{id}/editions/{slug}, and on the website /games/{game}/editions/{slug}): language, publisher and year, then a tag that never changes (fr-iello-2019-k3x9q2); original for the original edition. The tag keeps an older address finding the edition after its facts are corrected.
Null for the original edition.
The language it is printed in, when known.
object
The publisher’s product code or SKU, when known.
This edition’s own barcode (EAN-13), when a source states it. Null for the original edition: its barcode is the game’s ean.
The box of this edition (the game’s main cover for the original edition), as in the game’s covers: the same as covers.front. Null when the catalog has none.
object
The front and the back of this edition’s box, each a path on this API (/v1/media/…) when we hold a copy, otherwise null. The back is never a game’s cover.
object
object
object
The language shown; null when the edition has no rules.
The languages this edition has rules in.
The sections written so far, in reading order. A section the rulebook does not cover is left out, never made up.
object
Plain text with light formatting: paragraphs separated by a blank line, lines starting with - or 1. for lists, **bold**. Never HTML.
human: written by a member. job: drafted in our own words from the rulebook rulebookId, then checked by a moderator.
The member who wrote it.
The rulebook a drafted section was read from.
The rulebooks the drafted sections came from, with their files (see GET /games/{id}/rulebooks).
object
object
Its address under the game (GET /games/{id}/editions/{slug}, and on the website /games/{game}/editions/{slug}): language, publisher and year, then a tag that never changes (fr-iello-2019-k3x9q2); original for the original edition. The tag keeps an older address finding the edition after its facts are corrected.
Null for the original edition.
The language it is printed in, when known.
object
The publisher’s product code or SKU, when known.
This edition’s own barcode (EAN-13), when a source states it. Null for the original edition: its barcode is the game’s ean.
The box of this edition (the game’s main cover for the original edition), as in the game’s covers: the same as covers.front. Null when the catalog has none.
object
The front and the back of this edition’s box, each a path on this API (/v1/media/…) when we hold a copy, otherwise null. The back is never a game’s cover.
object
object
object
The languages it has something in.
Example
{ "data": { "edition": { "id": "5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77:original", "slug": "original", "name": null, "original": true, "language": null, "publisher": null, "year": 1995, "productCode": null, "ean": null, "cover": null, "covers": { "front": null, "back": null } }, "language": "en", "languages": [ "en" ], "sections": [ { "section": "summary", "body": "Settle an island: build roads, settlements and cities, trade resources, and be first to 10 victory points.", "origin": "human", "author": "Ada", "rulebookId": null, "updatedAt": "2026-11-22T10:00:00.000Z" } ], "rulebooks": [] }, "editions": [ { "id": "5c9b0f43-7a39-4f0c-8a4e-2f2d2b1d9a77:original", "slug": "original", "name": null, "original": true, "language": null, "publisher": null, "year": 1995, "productCode": null, "ean": null, "cover": null, "covers": { "front": null, "back": null }, "languages": [ "en" ] } ]}lang is not a language code.
object
What went wrong, in plain English words. The wording may change: act on code.
A stable name for this refusal, for programs and for showing the message in another language. A code is never renamed; new ones may be added.
The numbers the sentence names, when it names any: for example { "max": 20 } with daily_photo_limit.
object
Example
{ "error": "Game not found", "code": "game_not_found"}No game has this id, or it has no such edition.
object
What went wrong, in plain English words. The wording may change: act on code.
A stable name for this refusal, for programs and for showing the message in another language. A code is never renamed; new ones may be added.
The numbers the sentence names, when it names any: for example { "max": 20 } with daily_photo_limit.
object
Example
{ "error": "Game not found", "code": "game_not_found"}Too many requests, or too many of these sent today (code says which).
object
What went wrong, in plain English words. The wording may change: act on code.
A stable name for this refusal, for programs and for showing the message in another language. A code is never renamed; new ones may be added.
The numbers the sentence names, when it names any: for example { "max": 20 } with daily_photo_limit.
object
Example
{ "error": "Game not found", "code": "game_not_found"}