Class GetUsersTopArtistsRequest

java.lang.Object
de.sonallux.spotify.api.apis.users.GetUsersTopArtistsRequest

public class GetUsersTopArtistsRequest extends Object

Get User's Top Artists request

Required OAuth scopes

user-top-read

Response

Pages of artists

  • Constructor Details

    • GetUsersTopArtistsRequest

      public GetUsersTopArtistsRequest(ApiClient apiClient)
      Get User's Top Artists request
      Parameters:
      apiClient -

      The API client

  • Method Details

    • timeRange

      public GetUsersTopArtistsRequest timeRange(String timeRange)
      Parameters:
      timeRange -

      Over what time frame the affinities are computed. Valid values: long_term (calculated from several years of data and including all new data as it becomes available), medium_term (approximately last 6 months), short_term (approximately last 4 weeks). Default: medium_term

      Returns:
      this request
    • limit

      public GetUsersTopArtistsRequest limit(int limit)
      Parameters:
      limit -

      The maximum number of items to return. Default: 20. Minimum: 1. Maximum: 50.

      Returns:
      this request
    • offset

      public GetUsersTopArtistsRequest offset(int offset)
      Parameters:
      offset -

      The index of the first item to return. Default: 0 (the first item). Use with limit to get the next set of items.

      Returns:
      this request
    • build

      public ApiCall<Paging<Artist>> build()
      Build the request into an executable api call
      Returns:
      an executable api call