RSS-Bridge / rss-bridge

The RSS feed for websites missing it
https://rss-bridge.org/bridge01/
The Unlicense
7.29k stars 1.03k forks source link

Spotify: Support for search api endpoint #3543

Closed jinithin closed 1 year ago

jinithin commented 1 year ago

Currently shows, playlists and artists are supported by the Spotify bridge.
A way to fetch items using the search function would be great as well.
An example is fetching the latest albums from a label.

Web API example:

ENDPOINT: https://api.spotify.com/v1/search
q: label:"warp records" tag:new
type: album
market: se
{
  "albums": {
    "href": "https://api.spotify.com/v1/search?query=label%3A%22warp+records%22+tag%3Anew&type=album&market=SE&locale=en-GB%2Cen%3Bq%3D0.5&offset=0&limit=20",
    "items": [
      {
        "album_type": "single",
        "artists": [
          {
            "external_urls": {
              "spotify": "https://open.spotify.com/artist/6x1AtSAbU8AQSj2bLmIRMv"
            },
            "href": "https://api.spotify.com/v1/artists/6x1AtSAbU8AQSj2bLmIRMv",
            "id": "6x1AtSAbU8AQSj2bLmIRMv",
            "name": "solar lodges",
            "type": "artist",
            "uri": "spotify:artist:6x1AtSAbU8AQSj2bLmIRMv"
          }
        ],
        "external_urls": {
          "spotify": "https://open.spotify.com/album/1rySqrQcxrZIGpFHbksfvI"
        },
        "href": "https://api.spotify.com/v1/albums/1rySqrQcxrZIGpFHbksfvI",
        "id": "1rySqrQcxrZIGpFHbksfvI",
        "images": [
          {
            "height": 640,
            "url": "https://i.scdn.co/image/ab67616d0000b273ed5d2eb492351aa4f3d96518",
            "width": 640
          },
          {
            "height": 300,
            "url": "https://i.scdn.co/image/ab67616d00001e02ed5d2eb492351aa4f3d96518",
            "width": 300
          },
          {
            "height": 64,
            "url": "https://i.scdn.co/image/ab67616d00004851ed5d2eb492351aa4f3d96518",
            "width": 64
          }
        ],
        "is_playable": true,
        "name": "Turquoise",
        "release_date": "2023-07-05",
        "release_date_precision": "day",
        "total_tracks": 1,
        "type": "album",
        "uri": "spotify:album:1rySqrQcxrZIGpFHbksfvI"
      }
    ],
    "limit": 20,
    "next": null,
    "offset": 0,
    "previous": null,
    "total": 1
  }
}
dvikan commented 1 year ago

@Paroleen

dvikan commented 1 year ago

fixed in https://github.com/RSS-Bridge/rss-bridge/pull/3548