Orchdio API documentation
  • ๐Ÿ‘‹Welcome!
  • Quick Start
  • Reference
    • API Reference
      • ๐Ÿ”’ Authentication
        • Spotify
        • Deezer
        • Apple Music
      • โš›๏ธEntity
        • Track
        • Playlist
      • ๐Ÿ“‘Library management
        • Add playlist to library
      • ๐Ÿ‘ฅAccount management
        • Account information
        • Library playlists
        • Library artists
        • Library albums
        • Listening history
      • ๐ŸชWebhooks
  • โš—๏ธMiscellaneous
    • Target platform values
    • ๐Ÿ”ฎShowcases
    • FAQ (The frequent "whats" and "whys")
Powered by GitBook
On this page
  1. Reference
  2. API Reference
  3. Account management

Listening history

Fetch the user's platform library listening history

PreviousLibrary albumsNextWebhooks

Last updated 2 years ago

This endpoint requires that you use your private key. It is recommended to make the request from your own backend and make a request to that endpoint from the frontend of you app. This is to prevent accidentally leaking your private keys

If you notice your keys have been accidentally exposed, you can revoke from the . You'll get get new keys you can then update where the old keys were (securely) used.

The response looks like:

// Some code
{
   "data":[
      {
         "url":"https://open.spotify.com/track/5dpvif8JsQSy39O2QaUkaf",
         "artists":[
            "Richie Rich",
            "C-Bo"
         ],
         "released":"2020-04-20",
         "duration":"4:02",
         "duration_milli":242967,
         "explicit":true,
         "title":"Smoke",
         "preview":"https://p.scdn.co/mp3-preview/96bdcee2a61f5e9588a2107f02232fae6298d916?cid=8d367c0bbfe142d494bcbf1cf2e30f06",
         "album":"The Grow Room",
         "id":"5dpvif8JsQSy39O2QaUkaf",
         "cover":"https://i.scdn.co/image/ab67616d0000b273a778e6e494917d2697db2038"
      }
   ],
   "message": "Spotify listening returned",
   "status": 200
}
๐Ÿ‘ฅ
dashboard
get
Path parameters
userIdanyRequired

The Orchdio ID of the user

Example: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11
platformstring ยท enumRequired

The platform to get the albums from

Example: spotifyPossible values:
Header parameters
x-orchdio-keystring ยท uuidRequired

Your private key

Example: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11
Responses
200
Successful response
application/json
Responseany

Get the user's tracks history

401
Unauthorized
application/json
500
Internal server error
application/json
get
GET /v1/account/{userId}/{platform}/history/tracks HTTP/1.1
Host: api.orchdio.dev
x-orchdio-key: a0eebc99-9c0b-4ef8-bb6d-6bb9bd380a11
Accept: */*

No content