API · Spotify
GET /spotify/search
Search Spotify: artists, albums, tracks, playlists, podcasts and episodes.
| Request | GET /v1/spotify/search |
| Operation id | spotify.search.all |
| Cost | 1 credit, refunded if the call fails |
| Auth | API key: Authorization: Bearer <key> or x-api-key. |
Search Spotify: artists, albums, tracks, playlists, podcasts and episodes.
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
q | string | yes | Search words. Example: daft punk. |
type | string | no | Comma-separated kinds to keep: artist, album, track, playlist, show, episode. Default: all. |
limit | integer | no | Results per kind (default 10). |
after | string | no | Cursor: the previous page’s next_cursor. |
Responses
| Status | Meaning | Schema |
|---|---|---|
200 | Matches by kind. | SpotifySearchResponse |
400 | Invalid input. Nothing was charged. | Error |
401 | Missing or invalid API key. | Error |
402 | Not enough credits, a spend cap was reached, or payment is required. | Error |
403 | The target is private, or the account is suspended. | Error |
404 | No Spotify object by that id, or it is not public. | Error |
429 | Too many requests. Wait for Retry-After seconds. | Error |
503 | Spotify is temporarily unavailable. Retryable; nothing was charged. | Error |
SpotifySearchResponse fields
| Field | Type | Description |
|---|---|---|
artists | object | |
albums | object | |
tracks | object | |
playlists | object | |
shows | object | |
episodes | object | |
next_cursor | string | null |
Errors use one shape everywhere; see Errors for every code and what to do.