Get Spotify catalog information for multiple artists identified by their Spotify IDs.

get_artist_albums(id, include_groups = c("album", "single", "appears_on",
  "compilation"), market = NULL, limit = 20, offset = 0,
  authorization = get_spotify_access_token(),
  include_meta_info = FALSE)

Arguments

id

The Spotify ID for the artist.

include_groups

Optional. A character vector of keywords that will be used to filter the response. If not supplied, all album types will be returned. Valid values are:
"album"
"single"
"appears_on"
"compilation"
For example: include_groups = c("album", "single")

market

Optional.
An ISO 3166-1 alpha-2 country code or the string "from_token".
Supply this parameter to limit the response to one particular geographical market. For example, for albums available in Sweden: market = "SE".
If not given, results will be returned for all markets and you are likely to get duplicate results per album, one for each market in which the album is available!

limit

Optional.
Maximum number of results to return.
Default: 20
Minimum: 1
Maximum: 50

offset

Optional.
The index of the first album to return.
Default: 0 (i.e., the first album).
Use with limit to get the next set of albums.

authorization

Required. A valid access token from the Spotify Accounts service. See the https://developer.spotify.com/documentation/general/guides/authorization-guide/ for more details. Defaults to spotifyr::get_spotify_access_token()

include_meta_info

Optional. Boolean indicating whether to include full result, with meta information such as "total", and "limit". Defaults to FALSE.

Value

Returns a data frame of results containing artist data. See https://developer.spotify.com/documentation/web-api/reference/artists/get-several-artists/ for more information.