tmdb_api 2.0.0-nullsafety tmdb_api: ^2.0.0-nullsafety copied to clipboard
Dart client-side API package for TMDB.org API (https://www.themoviedb.org/).
import 'package:tmdb_api/tmdb_api.dart';
void main(List<String> args) async {
//api with out console logs
final tmdb = TMDB(ApiKeys('Your API KEY', 'apiReadAccessTokenv4'));
print(await tmdb.v3.movies.getPouplar());
//api with showing all console logs
final tmdbWithLogs = TMDB(
ApiKeys('Your API KEY', 'apiReadAccessTokenv4'),
logConfig: ConfigLogger.showAll(),
);
print(await tmdbWithLogs.v3.movies.getPouplar());
//api with showing all console logs
final tmdbWithCustomLogs = TMDB(
ApiKeys('Your API KEY', 'apiReadAccessTokenv4'),
logConfig: ConfigLogger(
//must be true than only all other logs will be shown
showLogs: true,
showErrorLogs: true,
),
);
print(await tmdbWithCustomLogs.v3.movies.getPouplar());
}