SpotifyApi class
Accesspoint for the spotify api
Example usage:
var credentials = SpotifyApiCredentials('my_id', 'my_secret');
var spotify = SpotifyApi(credentials);
var shows = spotify.shows.get('id);
...
- Inheritance
-
- Object
- SpotifyApiBase
- SpotifyApi
Constructors
- SpotifyApi(SpotifyApiCredentials credentials, {dynamic onCredentialsRefreshed(SpotifyApiCredentials)?})
- SpotifyApi.fromAuthCodeGrant(AuthorizationCodeGrant grant, String responseUri)
-
SpotifyApi.fromClient(FutureOr<
Client> client) - SpotifyApi.withAccessToken(String accessToken)
Properties
- albums → Albums
-
no setterinherited
- artists → Artists
-
no setterinherited
- audioAnalysis → AudioAnalysisEndpoint
-
no setterinherited
- audiobooks → Audiobooks
-
no setterinherited
- audioFeatures → AudioFeatures
-
no setterinherited
- browse → Browse
-
no setterinherited
- categories → Categories
-
no setterinherited
- chapters → Chapters
-
no setterinherited
-
client
→ FutureOr<
Client> -
no setterinherited
- episodes → Episodes
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- loggingDetail ← LoggingDetail
-
no getterinherited
- markets → Markets
-
no setterinherited
- me → Me
-
no setterinherited
- player → PlayerEndpoint
-
no setterinherited
- playlists → Playlists
-
no setterinherited
- recommendations → RecommendationsEndpoint
-
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- search → Search
-
no setterinherited
- shows → Shows
-
no setterinherited
- spotifyClient → SpotifyClient
-
no setterinherited
- tracks → Tracks
-
no setterinherited
- users → Users
-
no setterinherited
Methods
-
enableLogging(
{required bool enable, LoggingDetail loggingDetail = LoggingDetail.simple, SpotifyLogger? logger}) → void -
enables logging of the requests and responses on the debug console.loggingDetailcontrols the logging verbosity. Default's set to LoggingDetail.simple. If requiredloggeris also possible for e.g. saving logs into a file etc.inherited -
expandLink(
String url) → Future< String> -
Expands shortened spotify
urlinherited -
getCredentials(
) → Future< SpotifyApiCredentials> -
inherited
-
handleResponseWithBody(
Response response) → String -
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
asyncFromCredentials(
SpotifyApiCredentials credentials, {dynamic onCredentialsRefreshed(SpotifyApiCredentials)?}) → Future< SpotifyApi> -
override
-
generateCodeVerifier(
) → String - Generates a cryptographically secure code verifier for PKCE flows.