Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

get_genre_artists

Search for Artists by Genre


Description

Get Spotify Catalog information about artists belonging to a given genre.

Usage

get_genre_artists(
  genre = character(),
  market = NULL,
  limit = 20,
  offset = 0,
  authorization = get_spotify_access_token()
)

Arguments

genre

Required.
String of genre name to search for
For example: genre = "wonky".

market

Optional.
An ISO 3166-1 alpha-2 country code or the string "from_token".
If a country code is specified, only artists with content that is playable in that market is returned.
Note:
- If market is set to "from_token", and a valid access token is specified in the request header, only content playable in the country associated with the user account is returned.
- Users can view the country that is associated with their account in the account settings. A user must grant access to the user-read-private scope prior to when the access token is issued.

limit

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

offset

Optional.
The index of the first result to return.
Default: 0 (the first result).
Maximum offset (including limit): 10,000.
Use with limit to get the next page of search results.

authorization

Required. A valid access token from the Spotify Accounts service. See the Web API authorization guide for more details. Defaults to spotifyr::get_spotify_access_token()

Value

A data frame of the artists belonging to the genre with data and metadata about the artists in a tibble.

See Also

Examples

get_genre_artists('wonky')

spotifyr

R Wrapper for the 'Spotify' Web API

v2.2.1
MIT + file LICENSE
Authors
Charlie Thompson [aut], Daniel Antal [aut, cre] (<https://orcid.org/0000-0001-7513-6760>), Josiah Parry [aut] (<https://orcid.org/0000-0001-9910-865X>), Donal Phipps [aut], Tom Wolff [aut]
Initial release
2021-06-09

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.