trakt_dart 0.4.0 trakt_dart: ^0.4.0 copied to clipboard
A Dart client-side API package for the Trakt.tv API, a database on what tv shows and movies everyone is watching.
track_dart #
A Trakt client library for dart.
To learn more about Trakt visit offical site
To learn more about the Trakt API visit offical site
Features #
Current API calls implemented:
- Added in v0.4.0: All Calendar, Checkin, Comment, Recommendation, and Scrobble requests
- Added in v0.3.0: All OAuth requests and remaining show requests that require OAuth
- Added in v0.2.0: All Certification, Country, Genre, Language, Lists, Network, and Search
- Added in v0.1.0: All Movie, Show, Season, Episode, People Requests the do not require OAuth
Note: This packaage is still in beta. File any issues you see or feature requests
Getting started #
-
Adding as dependencies
Add this to your package's pubspec.yaml file:
dependencies: trakt_dart: ^0.4.0
-
Import it
Now in your Dart code, you can use:
import 'package:trakt_dart/trakt_dart.dart';
Usage #
Initialize #
In order to make calls to the Trakt API, you must first inialize the TraktManager with your clientId and clientSecret. To get these, you must first register an account with Trakt, then complete the Create An App Application.
Once you have these values, initialize the TraktManager before making your first API call:
TraktManager.instance.initializeTraktMananager(
clientId: "${clientId}", clientSecret: "${clientSecret}");
Example Usage #
To call the trending movies endpoint:
final trendingMovies = await TraktManager.instance.getTrendingMovies(extendedFull: true);
Planned Work #
Since this is still a work in progress, I will be updating this package on a weekly bases until all of the endpoints are implmenented including OAuth.
To follow the progress, follow me on Twitter @damonique_b.