Discogs API endpoint
Searches the Discogs database for releases, masters, artists and labels, optionally filtered to one `type`, with `page` and `per_page` (max 100). Release and master results carry country, year, formats, labels, genres, styles, catalog number and barcodes; artist and label results carry id, title and thumbnail.
/discogs/searchSearches Discogs releases, masters, artists, and labels. Rate-limited to 25 requests/min per IP.
Query parameters:
q (required) — search query.type (optional) — result type filter. Allowed values: release, master, artist, label. Omit to search across all types.page (optional, default 1).per_page (optional, default 50, max 100).Response includes page, pages, per_page, items (total across all pages), and results[]. Field availability on each result varies by type: release/master hits carry country, formats[], labels[], genres[], styles[], catno, barcodes[], master_id; artist/label hits are effectively just id, title, thumb. uri is always the absolute https://www.discogs.com/... page link.
| Field | Filled in, of 20 checked | Values in the sample |
|---|---|---|
| id | 20 | |
| type | 20 | release in all 20 |
| title | 20 | Daft Punk - Discovery (19), Daft Punk = ダフト・パンク* - Discover… (1) |
| year | 17 | 2,001 to 2,024, median 2,014 |
| country | 20 | Europe (8), US (5), Canada (2) and 5 more |
| genres | 20 | median 1 entry |
| styles | 20 | median 3 entries |
| formats | 20 | median 4 entries |
| labels | 20 | median 10 entries |
| catno | 20 | “V2940” and 10 other values |
| barcodes | 20 | median 10 entries |
| master_id | 20 | |
| uri | 20 | discogs.com |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| q | string | Yes | Search query | Daft Punk Discovery | |
| type | string | No | Result type filter Allowed values: release, master, artist, label. | ||
| page | integer | No | 1-based page number, default 1 | ||
| per_page | integer | No | Results per page, default 50, max 100 | ||
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/discogs/search?q=Daft+Punk+Discovery&type=release&page=1" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"query": "Daft Punk Discovery",
"type": "release",
"page": 1,
"pages": 4,
"per_page": 50,
"items": 171,
"results": [
{
"id": 2879,
"type": "release",
"title": "Daft Punk - Discovery",
"year": "2001",
"country": "Europe",
"genres": [
"Electronic"
],
"styles": [
"Disco",
"House"
],
"formats": [
"Vinyl",
"LP",
"Album",
"Stereo"
],
"labels": [
"Virgin"
],
"catno": "V2940",
"barcodes": [
"724384960612"
],
"master_id": 26647,
"uri": "https://www.discogs.com/release/2879-Daft-Punk-Discovery"
}
],
"source_url": "https://api.discogs.com/database/search?page=1&per_page=50&q=Daft+Punk+Discovery&type=release"
}
}Request schema
No body schema
Response schema
#/definitions/discogs.searchResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | discogs.SearchResponse | No | ||||
| data.items | integer | No | Total number of matching results across all pages. | |||
| data.page | integer | No | Page number returned. | |||
| data.pages | integer | No | Total number of pages. | |||
| data.per_page | integer | No | Number of results per page. | |||
| data.query | string | No | Search text that was run. | |||
| data.results | array | No | Matches on this page, one item per release, master, artist or label. | |||
| data.results[].barcodes | array | No | Barcodes printed on the release. Present for release and master hits. | |||
| data.results[].catno | string | No | Catalogue number of the release. Present for release and master hits. | |||
| data.results[].country | string | No | Country the release was issued in. Present for release and master hits. | |||
| data.results[].cover_image | string | No | URL of the cover image. | |||
| data.results[].formats | array | No | Formats of the release, for example `Vinyl` or `LP`. Present for release and master hits. | |||
| data.results[].genres | array | No | Genres of the release. Present for release and master hits. | |||
| data.results[].id | integer | No | Discogs id of the hit. Use it with the matching release, master, artist or label endpoint. | |||
| data.results[].labels | array | No | Names of the labels that issued the release. Present for release and master hits. | |||
| data.results[].master_id | integer | No | Discogs id of the master release this release belongs to, when there is one. | |||
| data.results[].styles | array | No | Styles of the release, more specific than genres. Present for release and master hits. | |||
| data.results[].thumb | string | No | URL of a thumbnail image. | |||
| data.results[].title | string | No | Title of the hit, for example `Daft Punk - Discovery` for a release. | |||
| data.results[].type | string | No | release | Kind of hit: `release`, `master`, `artist` or `label`. | ||
| data.results[].uri | string | No | https://www.discogs.com/release/2879-Daft-Punk-Discovery | Link to the hit's page on Discogs. | ||
| data.results[].year | string | No | Year of release, as Discogs lists it. | |||
| data.source_url | string | No | URL the data was read from. | |||
| data.type | string | No | Result type the search was limited to: `release`, `master`, `artist` or `label`. Omitted when all types were searched. | |||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 500 | Internal Server Error | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/discogs/search?q=Daft+Punk+Discovery&type=release&page=1" \
-H "x-api-key: $CRAWLORA_API_KEY"