The DiscRecord API
Send an ISBN, barcode, product code or Open Library ID and get back everything DiscRecord knows about the releases that carry it, including cover images.
1. Get a free key
Create an account (or log in), then apply on your API keys page. You'll be asked for your application's name and what you'll use it for, and the key is issued straight away.
2. Send it with each request
As a header (best), or as ?api_key= on the address:
curl -H "X-API-Key: YOUR_KEY" "https://discrecord.org/api/v1/lookup?code=1-56585-327-X"
Requests
| Request | Returns |
|---|---|
| GET /api/v1/lookup?code=… | Every release carrying that code |
| GET /api/v1/releases/{id} | One release |
| GET /api/v1/titles/{id} | A title and all of its releases |
| GET /api/v1/search?q=…&page=… | Releases matching words in the title, author, publisher or series, 25 a page |
| GET /api/v1/people/{slug} | A person's roles and releases, 25 a page. The slug is the end of their page address, e.g. cassandra-campbell |
| GET /api/v1/publishers/{slug} | A publisher's releases, 25 a page, e.g. the-teaching-company |
Codes the lookup understands
Type codes however they're printed; dashes and spaces don't matter, and neither does upper or lower case.
- ISBN-10 and ISBN-13 are treated as the same book: either finds releases stored with the other.
- UPC-A and EAN-13 barcodes: a 12-digit UPC also matches its 13-digit EAN form.
- Product codes such as
PC340-01, and Open Library IDs such asOL31975134M.
A code can match more than one release. All four parts of a course may share one ISBN, for example, so check
count and the product codes in each result.
What comes back
{
"code": "1-56585-327-X",
"count": 4,
"results": [{
"id": 1,
"url": "https://discrecord.org/release/1",
"title": { "kind": "course", "title": "The History of Ancient Rome", "creator": "Professor Garrett G. Fagan" },
"label": "Part 1", "format": "audio cd", "part": 1, "parts": 4, "year": 1999,
"identifiers": [ { "type": "sku", "value": "PC340-01", "location": "Back of insert, small vertical barcode" } ],
"contents": [ { "item": "audio cd", "quantity": 6, "name": "Audio CDs" } ],
"tracks": [ { "number": 1, "name": "Introduction", "minutes": 30 } ],
"images": [ { "kind": "front", "url": "https://discrecord.org/img/…jpg" } ]
}, …]
}
Each release has the same fields as a line of the daily download file. Fields with no value are left out.
Limits and errors
- 60 requests a minute per key. Past that you get
429with aRetry-Afterheader. 401: missing, wrong or revoked key.404: nothing found.400: something missing from the request.- For anything in bulk, such as copying the whole catalog, use the daily download instead; it's faster for you and kinder to the site.
- The API can be called from a web page in the browser (CORS is open), but anyone can read a key placed in a web page, so keep keys in server-side code where you can.
License
The data is public domain (CC0 1.0). Cover scans and other images belong to their rights holders; showing them to identify a release is how they're meant to be used.