Class GetCategoryRequest
- java.lang.Object
-
- de.sonallux.spotify.api.apis.browse.GetCategoryRequest
-
public class GetCategoryRequest extends Object
Get a Category requestResponse
On success, the HTTP status code in the response header is
200OK and the response body contains a category object in JSON format. On error, the header status code is an error code and the response body contains an error object.Once you have retrieved the category, you can use Get a Category's Playlists to drill down further.
-
-
Constructor Summary
Constructors Constructor Description GetCategoryRequest(ApiClient apiClient, String categoryId)Get a Category request
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ApiCall<Category>build()Build the request into an executable callGetCategoryRequestcountry(String country)A country: an ISO 3166-1 alpha-2 country code.GetCategoryRequestlocale(String locale)The desired language, consisting of an ISO 639-1 language code and an ISO 3166-1 alpha-2 country code, joined by an underscore.
-
-
-
Constructor Detail
-
GetCategoryRequest
public GetCategoryRequest(ApiClient apiClient, String categoryId)
Get a Category request
- Parameters:
apiClient-The API client
categoryId-The Spotify category ID for the category.
-
-
Method Detail
-
country
public GetCategoryRequest country(String country)
A country: an ISO 3166-1 alpha-2 country code. Provide this parameter to ensure that the category exists for a particular country.
-
locale
public GetCategoryRequest locale(String locale)
The desired language, consisting of an ISO 639-1 language code and an ISO 3166-1 alpha-2 country code, joined by an underscore. For example:
es_MX, meaning "Spanish (Mexico)". Provide this parameter if you want the category strings returned in a particular language. Note that, iflocaleis not supplied, or if the specified language is not available, the category strings returned will be in the Spotify default language (American English).
-
-