Copy baseURL: wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify
To obtain x-api-key please contact the team. You can find more information at the "Connect With Us" section
Authentication
All requests require a valid API key to be included in the x-api-key header.
Fetch Played Tracks by Spotify Id
GET
https://
<baseURL>
/played-tracks
Fetches the played tracks of the authenticated Spotify user
This endpoint will only work if the user has connected their Spotify account to the platform.
Query Parameters
200: OK 400: ERROR
Copy {
"isError" : boolean ,
"data" : [
{
"track" : {
"album" : {
"album_type" : string ,
"artists" : [
{
"external_urls" : {
"spotify" : string
} ,
"href" : string ,
"id" : string ,
"name" : string ,
"type" : string ,
"uri" : string
}
] ,
"available_markets" : [string] ,
"external_urls" : {
"spotify" : string
} ,
"href" : string ,
"id" : string ,
"images" : [
{
"height" : number ,
"url" : string ,
"width" : number
}
] ,
"name" : string ,
"release_date" : string ,
"release_date_precision" : string ,
"total_tracks" : number ,
"type" : string ,
"uri" : string
} ,
"artists" : [
{
"external_urls" : {
"spotify" : string
} ,
"href" : string ,
"id" : string ,
"name" : string ,
"type" : string ,
"uri" : string
}
] ,
"available_markets" : [string] ,
"disc_number" : number ,
"duration_ms" : number ,
"explicit" : boolean ,
"external_ids" : {
"isrc" : string
} ,
"external_urls" : {
"spotify" : string
} ,
"href" : string ,
"id" : string ,
"is_local" : boolean ,
"name" : string ,
"popularity" : number ,
"preview_url" : string ,
"track_number" : number ,
"type" : string ,
"uri" : string
} ,
"played_at" : string ,
"context" : {
"type" : string ,
"href" : string ,
"external_urls" : {
"spotify" : string
} ,
"uri" : string
}
}
] ,
"message" : string
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/played-tracks?spotifyId=kemarikun' \
--header 'x-api-key: <apiKey>'
Fetch Saved Tracks by Spotify Id
GET
https://
<baseURL>
/saved-tracks
Fetches the saved tracks of the authenticated Spotify user
This endpoint will only work if the user has connected their Spotify account to the platform.
Query Parameters
200: OK 400: ERROR
*** same format as played-tracks above
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/save-tracks?spotifyId=kemarikun' \
--header 'x-api-key: <apiKey>'
Fetch Saved Albums by Spotify Id
GET
https://
<baseURL>
/saved-albums
Fetches the saved albums of the authenticated Spotify user
This endpoint will only work if the user has connected their Spotify account to the platform.
Query Parameters
200: OK 400: ERROR
Copy {
"isError" : boolean ,
"data" : [
{
"albumId" : string ,
"albumName" : string ,
"albumTotalTracks" : number ,
"albumPopularity" : string ,
"albumImages" : [
{
"url" : string ,
"height" : number ,
"width" : number
}
] ,
"albumType" : string ,
"albumAvailableMarkets" : string ,
"albumExternalUrls" : {
"spotify" : string
} ,
"albumHref" : string ,
"albumReleaseDate" : string ,
"albumReleaseDatePrecision" : string ,
"albumUri" : string ,
"albumExternalIds" : string ,
"albumGenres" : string ,
"albumLabel" : string
}
] ,
"message" : string
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/save-albums?spotifyId=kemarikun' \
--header 'x-api-key: <apiKey>'
Fetch Saved Playlists by Spotify Id
GET
https://
<baseURL>
/saved-playlists
Fetches the saved playlists of the authenticated Spotify user
This endpoint will only work if the user has connected their Spotify account to the platform.
Query Parameters
200: OK 400: ERROR
Copy {
"isError" : boolean ,
"data" : [
{
"playlistId" : string ,
"playlistName" : string ,
"playlistDescription" : string ,
"playlistImages" : [
{
"height" : number ,
"url" : string ,
"width" : number
}
] ,
"playlistExternalUrls" : {
"spotify" : string
} ,
"playlistHref" : string ,
"playlistType" : string ,
"playlistUri" : string ,
"playlistCollaborative" : boolean ,
"playlistFollowers" : number ,
"playlistSnapshotId" : string
}
] ,
"message" : string
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/save-playlists?spotifyId=kemarikun' \
--header 'x-api-key: <apiKey>'
Fetch Playlists Tracks by Spotify Id
GET
https://
<baseURL>
/playlist/tracks
Fetches the playlists tracks of the authenticated Spotify user with the specified playlist
This endpoint will only work if the user has connected their Spotify account to the platform.
Query Parameters
The playlistId of the playlist
200: OK 400: ERROR
Copy {
"isError" : boolean ,
"data" : {
"id" : string ,
"name" : string ,
"description" : string ,
"images" : [
{
"height" : number ,
"url" : string ,
"width" : number
}
] ,
"owner" : {
"id" : string ,
"displayName" : string
} ,
"tracks" : [
{
"id" : string ,
"name" : string ,
"album" : string ,
"artists" : [string]
}
] ,
"externalUrls" : {
"spotify" : string
}
} ,
"message" : string
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/playlist/tracks?spotifyId=kemarikun&playlistId=5nizWu5c54NkpA2Eu6Y2S0' \
--header 'x-api-key: <apiKey>'
Fetch Album Tracks by Spotify Id
GET
https://
<baseURL>
/album/tracks
Fetches the playlists tracks of the authenticated Spotify user with the specified playlist
This endpoint will only work if the user has connected their Spotify account to the platform.
Query Parameters
200: OK 400: ERROR
Copy {
"isError" : boolean ,
"data" : {
"id" : string ,
"name" : string ,
"images" : [
{
"url" : string ,
"height" : number ,
"width" : number
}
] ,
"artists" : [
{
"id" : string ,
"name" : string
}
] ,
"releaseDate" : string ,
"totalTracks" : number ,
"externalUrls" : {
"spotify" : string
}
} ,
"message" : string
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/album/tracks?spotifyId=b3fl33vskh6j2vfmtym7pqzuu&albumId=0aC3Wk3HT8ot5nBQdcqqGJ' \
--header 'x-api-key: <apiKey>'
Fetch Spotify User by Wallet Address
GET
https://
<baseURL>
/wallet-spotify-data
Fetches the details of a Spotify user by their wallet address
Query Parameters
The registered wallet address of the user
200: OK 400: ERROR
Copy {
"isError" : boolean ,
"data" : {
"spotifyUser" : {
"id" : string ,
"display_name" : string ,
"external_urls" : string ,
"href" : string ,
"images" : [] ,
"type" : string ,
"uri" : string ,
"followers" : number ,
"lastSynced" : string ,
"createdAt" : string ,
"updatedAt" : string
} ,
"tracks" : (same as the one in played-tracks endpoint)
} ,
"message" : string
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/wallet-spotify-data?walletAddress=0xAc842FB63f6ACf603EA6f088e53A1a210617133b' \
--header 'x-api-key: <apiKey>'
Fetch Top Artists and Genres by Spotify User
GET
https://
<baseURL>
/top
Fetches the names of top artists in mentioned time period and also their respective genres given the Spotify user
Query Parameters
optional, string. Can only pass in 3 values, 'long_term ', 'medium_term ', 'short_term '. If this param is not passed, execution defaults to 'long_term '
200: OK 400: ERROR
Copy {
"isError" : false ,
"data" : {
"names" : [
"Ed Sheeran" ,
....
] ,
"genres" : [
"pop" ,
....
]
} ,
"message" : ""
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Copy curl --location 'https://wv2h4to5qa.execute-api.us-east-2.amazonaws.com/dev/spotify/top' \
--header 'x-api-key: <apiKey>'
Fetch Saved Shows by Spotify User
GET
https://
<baseURL>
/saved-shows
Fetches the podcasts saved given the Spotify user. This does not include the episodes saved only the metadata of the podcast
Query Parameters
200: OK 400:ERROR
Copy {
"isError" : false ,
"data" : [
{
"id" : "0woBZZkgalxmLWHdo9ELnn" ,
"name" : "The Riddler: Secrets in the Dark " ,
"description": "A masked vigilante is on the loose, murdering notorious super-villains all over Gotham City… and all clues point to the suspect being the Caped Crusader himself, Batman. Now, with a target on his head, the charming yet deadly Edward Nygma, better known as The Riddler, is forced to break out of Arkham Asylum and team up with the Caped Crusader. The unlikely duo must solve the mystery before they too, become victims. The Riddler: Secrets in the Dark stars Hasan Minhaj, Colman Domingo, and Gina Rodriguez and was produced by Phantom Four & Wolf at the Door in association with Blue Ribbon Content and DC for Spotify. © & ™ DC",
"explicit" : false ,
"externalUrls" : {
"spotify" : "https://open.spotify.com/show/0woBZZkgalxmLWHdo9ELnn"
} ,
"href" : "https://api.spotify.com/v1/shows/0woBZZkgalxmLWHdo9ELnn" ,
"images" : [
{
"height" : 640 ,
"url" : "https://i.scdn.co/image/ab6765630000ba8ac25409725525a7d3c18d1b16" ,
"width" : 640
} ,
{
"height" : 300 ,
"url" : "https://i.scdn.co/image/ab67656300005f1fc25409725525a7d3c18d1b16" ,
"width" : 300
} ,
{
"height" : 64 ,
"url" : "https://i.scdn.co/image/ab6765630000f68dc25409725525a7d3c18d1b16" ,
"width" : 64
}
] ,
"type" : "show" ,
"totalEpisodes" : 10 ,
"uri" : "spotify:show:0woBZZkgalxmLWHdo9ELnn" ,
"languages" : [
"en"
] ,
"isExternallyHosted" : false ,
"mediaType" : "mixed" ,
"publisher" : "Warner Bros. / Spotify Studios " ,
"added_at" : "2023-10-10T14:18:24.000Z"
}
] ,
"message" : ""
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }
Fetch Saved Episodes by Spotify User
GET
https://
<baseURL>
/saved-episodes
Fetches the podcasts episodes saved given the Spotify user.
Query Parameters
200: OK 400:ERROR
Copy {
"isError" : false ,
"data" : [
{
"id" : "35P4FJyefoLK6ZOMmfc508" ,
"name" : "07. A Head Full of Riddles" ,
"audioPreviewUrl" : "https://podz-content.spotifycdn.com/audio/clips/6p4LLtyx4TVaqK7iZylf6O/clip_631850_695550.mp3" ,
"description" : "The Riddler and Batman risk everything to end The Messenger's apocalyptic crusade. Learn more about your ad choices. Visit podcastchoices.com/adchoices" ,
"durationMs" : 1114200 ,
"explicit" : false ,
"externalUrls" : {
"spotify" : "https://open.spotify.com/episode/35P4FJyefoLK6ZOMmfc508"
} ,
"href" : "https://api.spotify.com/v1/episodes/35P4FJyefoLK6ZOMmfc508" ,
"images" : [
{
"height" : 640 ,
"url" : "https://i.scdn.co/image/ab6765630000ba8a4886da8fa40bb7e57f2956ae" ,
"width" : 640
} ,
{
"height" : 300 ,
"url" : "https://i.scdn.co/image/ab67656300005f1f4886da8fa40bb7e57f2956ae" ,
"width" : 300
} ,
{
"height" : 64 ,
"url" : "https://i.scdn.co/image/ab6765630000f68d4886da8fa40bb7e57f2956ae" ,
"width" : 64
}
] ,
"isExternallyHosted" : false ,
"isPlayable" : true ,
"language" : "en" ,
"languages" : [
"en"
] ,
"releaseDate" : "2023-10-10" ,
"releaseDatePrecision" : "day" ,
"type" : "episode" ,
"uri" : "spotify:episode:35P4FJyefoLK6ZOMmfc508" ,
"restrictions" : null ,
"showId" : "0woBZZkgalxmLWHdo9ELnn" ,
"added_at" : "2024-04-19T07:26:13.000Z"
}
] ,
"message" : ""
}
Copy { "message" : "spotifyId is required" }
or
{ "message" : "Please wait a few minutes for us to process and fetch your data" }