Authentication class

The API uses OAuth2. If you know what's up with OAuth2, grab your library and starting rolling. If you have access to a web browser (mobile app, desktop app, website), use standard OAuth. If you don't have web browser access (media center plugins, smart watches, smart TVs, command line scripts, system services), use Device authentication.To obtain a client_id and client_secret, create an application on the Trakt website.

Here are some helpful links to get your started: Create a new API app: https://trakt.tv/oauth/applications/new View your API apps: https://trakt.tv/oauth/applications

Inheritance

Constructors

Authentication(TraktManager manager)

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

authorizeApplication({bool? signup}) Future<void>
Construct then redirect to this URL.
generateDeviceCodes({bool? signup}) Future<DeviceCodeResponse>
Generate new codes to start the device authentication process.
getAccessToken(String code) Future<AccessTokenResponse>
Use the authorization code GET parameter sent back to your redirect_uri to get an access_token.
getDeviceAccessToken(String code) Future<AccessTokenResponse>
Use the authorization code GET parameter sent back to your redirect_uri to get an access_token.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
refreshAccessToken({String? refreshToken}) Future<AccessTokenResponse>
Use the refresh_token to get a new access_token without asking the user to re-authenticate.
revokeAccessToken() Future<void>
An access_token can be revoked when a user signs out of their Trakt account in your app.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited