- Cost
- 1 credit
- Cached repeats
- 0 creditssend max_age_days, results kept 30 days
- Failed requests
- 0 credits
You send one of url or id.
Part of the Spotify Scraper API: 7 Spotify endpoints on one key.
Request
Send your key in the x-api-key header.
1curl -G "https://api.socialscrape.dev/v1/spotify/album" \2 -H "x-api-key: $SOCIALSCRAPE_API_KEY" \3 --data-urlencode 'id=5AEDGbliTTfjOB8TSm1sxt'1import os2import requests34params = {5 "id": "5AEDGbliTTfjOB8TSm1sxt",6}7res = requests.get(8 "https://api.socialscrape.dev/v1/spotify/album",9 headers={"x-api-key": os.environ["SOCIALSCRAPE_API_KEY"]},10 params=params,11 timeout=60,12)13body = res.json()1415if body["ok"]:16 print(body["data"])17else:18 print(body["error"]["code"], body["error"]["message"])1const url = new URL("https://api.socialscrape.dev/v1/spotify/album");2url.search = new URLSearchParams({3 id: "5AEDGbliTTfjOB8TSm1sxt",4}).toString();5const res = await fetch(url, {6 headers: { "x-api-key": process.env.SOCIALSCRAPE_API_KEY! },7});8const body = await res.json();910if (body.ok) {11 console.log(body.data);12} else {13 console.error(body.error.code, body.error.message);14}1{2 "nodes": [3 {4 "name": "SocialScrape Spotify album",5 "type": "n8n-nodes-base.httpRequest",6 "typeVersion": 4.2,7 "position": [8 0,9 010 ],11 "parameters": {12 "method": "GET",13 "url": "https://api.socialscrape.dev/v1/spotify/album",14 "sendQuery": true,15 "queryParameters": {16 "parameters": [17 {18 "name": "id",19 "value": "5AEDGbliTTfjOB8TSm1sxt"20 }21 ]22 },23 "sendHeaders": true,24 "headerParameters": {25 "parameters": [26 {27 "name": "x-api-key",28 "value": "={{ $env.SOCIALSCRAPE_API_KEY }}"29 }30 ]31 }32 }33 }34 ],35 "connections": {}36}Parameters
| Name | Type | Required | Description |
|---|---|---|---|
url | url | one of | Spotify album URL. |
id | string | one of | Spotify album id. |
Every request also accepts trim, raw and max_age_days.
Response
Sample from a recorded response, shortened. Values are examples, not your data.
1{2 "ok": true,3 "credits_charged": 1,4 "credits_remaining": 4999,5 "cached": false,6 "cached_at": null,7 "request_id": "req_29f4e13231054599921cc3e1",8 "data": {9 "object": "album",10 "platform": "spotify",11 "id": "5AEDGbliTTfjOB8TSm1sxt",12 "url": "https://open.spotify.com/album/5AEDGbliTTfjOB8TSm1sxt",13 "title": "Speak Now (Taylor's Version)",14 "artists": [15 "Taylor Swift"16 ],17 "released_at": "2023-07-07",18 "track_count": 22,19 "cover_url": "https://i.scdn.co/image/ab67616d0000b2730b04da4f224b51ff86e0a481",20 "label": "Taylor Swift",21 "tracks": [22 {23 "object": "song",24 "platform": "spotify",25 "id": "7G0gBu6nLdhFDPRLc0HdDG",26 "url": "https://open.spotify.com/track/7G0gBu6nLdhFDPRLc0HdDG",27 "title": "Mine (Taylor's Version)",28 "artists": [29 "Taylor Swift"30 ],31 "album": "Speak Now (Taylor's Version)",32 "duration_seconds": 231.706,33 "cover_url": "https://i.scdn.co/image/ab67616d0000b2730b04da4f224b51ff86e0a481",34 "preview_url": null,35 "released_at": "2023-07-07",36 "isrc": null,37 "explicit": false,38 "is_original": null,39 "stats": {40 "plays": 296875369,41 "uses": null,42 "likes": null43 },44 "extra": {45 "album_id": "5AEDGbliTTfjOB8TSm1sxt",46 "artist_ids": [47 "06HL4z0CvFAxyc27GXpf02"48 ],49 "disc_number": 1,50 "playable": true,51 "track_number": 1,52 "uri": "spotify:track:7G0gBu6nLdhFDPRLc0HdDG"53 }54 },55 {56 "object": "song",57 "platform": "spotify",58 "id": "3MytWN8L7shNYzGl4tAKRp",59 "url": "https://open.spotify.com/track/3MytWN8L7shNYzGl4tAKRp",60 "title": "Sparks Fly (Taylor’s Version)",61 "artists": [62 "Taylor Swift"63 ],64 "album": "Speak Now (Taylor's Version)",65 "duration_seconds": 261.23,66 "cover_url": "https://i.scdn.co/image/ab67616d0000b2730b04da4f224b51ff86e0a481",67 "preview_url": null,68 "released_at": "2023-07-07",69 "isrc": null,70 "explicit": false,71 "is_original": null,72 "stats": {73 "plays": 197955576,74 "uses": null,75 "likes": null76 },77 "extra": {78 "album_id": "5AEDGbliTTfjOB8TSm1sxt",79 "artist_ids": [80 "06HL4z0CvFAxyc27GXpf02"81 ],82 "disc_number": 1,83 "playable": true,84 "track_number": 2,85 "uri": "spotify:track:3MytWN8L7shNYzGl4tAKRp"86 }87 },88 {89 "object": "song",90 "platform": "spotify",91 "id": "79uDOz0zuuWS7HWxzMmTa2",92 "url": "https://open.spotify.com/track/79uDOz0zuuWS7HWxzMmTa2",93 "title": "Back To December (Taylor's Version)",94 "artists": [95 "Taylor Swift"96 ],97 "album": "Speak Now (Taylor's Version)",98 "duration_seconds": 294.189,99 "cover_url": "https://i.scdn.co/image/ab67616d0000b2730b04da4f224b51ff86e0a481",100 "preview_url": null,101 "released_at": "2023-07-07",102 "isrc": null,103 "explicit": false,104 "is_original": null,105 "stats": {106 "plays": 319451738,107 "uses": null,108 "likes": null109 },110 "extra": {111 "album_id": "5AEDGbliTTfjOB8TSm1sxt",112 "artist_ids": [113 "06HL4z0CvFAxyc27GXpf02"114 ],115 "disc_number": 1,116 "playable": true,117 "track_number": 3,118 "uri": "spotify:track:79uDOz0zuuWS7HWxzMmTa2"119 }120 }121 ],122 "extra": {123 "artist_ids": [124 "06HL4z0CvFAxyc27GXpf02"125 ],126 "artist_urls": [127 "https://open.spotify.com/artist/06HL4z0CvFAxyc27GXpf02"128 ],129 "copyright": [130 "© 2023 Taylor Swift",131 "℗ 2023 Taylor Swift"132 ],133 "disc_count": 1,134 "is_pre_release": false,135 "more_albums_by_artist": [136 {137 "cover_url": "https://i.scdn.co/image/ab67616d0000b273cf3de6b538d8b1ed73a4d5d1",138 "id": "4hF2gTGuPYlykYuphDxi8J",139 "release_date": "2026",140 "release_date_precision": "YEAR",141 "title": "The Life of a Showgirl: The Encore",142 "type": "album",143 "url": "https://open.spotify.com/album/4hF2gTGuPYlykYuphDxi8J"144 },145 {146 "cover_url": "https://i.scdn.co/image/ab67616d0000b273d7812467811a7da6e6a44902",147 "id": "4a6NzYL1YHRUgx9e3YZI6I",148 "release_date": "2025",149 "release_date_precision": "YEAR",150 "title": "The Life of a Showgirl",151 "type": "album",152 "url": "https://open.spotify.com/album/4a6NzYL1YHRUgx9e3YZI6I"153 },154 {155 "cover_url": "https://i.scdn.co/image/ab67616d0000b273e787cffec20aa2a396a61647",156 "id": "1NAmidJlEaVgA3MpcPFYGq",157 "release_date": "2019",158 "release_date_precision": "YEAR",159 "title": "Lover",160 "type": "album",161 "url": "https://open.spotify.com/album/1NAmidJlEaVgA3MpcPFYGq"162 }163 ]164 }165 },166 "cursor": null,167 "has_more": null168}Fields
One Album in data.
A field the platform does not give is null, never made up. Extra platform details are in extra.
| Field | Type | Always | Notes |
|---|---|---|---|
object | "album" | ||
platform | Platform | yes | |
id | string | yes | |
url | string or null | ||
title | string or null | ||
artists | string[] or null | ||
released_at | string (ISO 8601 date) or null | ||
track_count | integer or null | ||
cover_url | string or null | ||
label | string or null | ||
tracks | Song[] or null | ||
extra | object or null |
Full field list in the reference for this endpoint and the data models. Errors are listed under Errors.
Questions
Which errors can it return?
invalid_params (do not retry), unsupported_url (do not retry), not_found (do not retry). Account and platform errors from the errors list can also happen. A failure always costs 0 credits.
Is there an SDK call for it?
The Python client has client.spotify.album(...) and the TypeScript client client.spotify.album(). Both return the same envelope as the HTTP API. Install them from PyPI (socialscrape-sdk) or npm (socialscrape); plain HTTP works in any language.
Can an AI agent call it?
Yes. The MCP server, which you run on your own machine, reaches every built endpoint, with the same prices.