WebService::TVDB - Interface to http://thetvdb.com/
version 1.130350
my $tvdb = WebService::TVDB->new(api_key => 'ABC123', language => 'English', max_retries => 10); my $series_list = $tvdb->search('men behaving badly'); my $series = @{$series_list}[0]; # $series is a WebService::TVDB::Series say $series->SeriesName; say $series->Overview; # fetches full series data $series->fetch(); say $series->Rating; say $series->Status; for my $episode (@{ $series->episodes }){ # $episode is a WebService::TVDB::Episode say $episode->Overview; say $episode->FirstAired; } for my $actor (@{ $series->actors }){ # $actor is a WebService::TVDB::Actor say $actor->Name; say $actor->Role; } for my $banner (@{ $series->banners }){ # $banner is a WebService::TVDB::Banner say $banner->Rating; say $banner->url; } # can also get by id my $series = $tvdb->get(76213); # already done a fetch() say $series->SeriesName; say $series->Overview; say $series->Rating; say $series->Status;
WebService::TVDB is an interface to http://thetvdb.com/.
Creates a new WebService::TVDB object. Takes the following parameters:
This is your API key. If not passed in here, we will look in ~/.tvdb. Otherwise we will die.
The language you want tour results in. "See WebService::TVDB::Languages" for a list of languages. Defaults to English.
The amount of times we will try to get the series if our call to the URL failes. Defaults to 10.
Searches the TVDB and returns a list of WebService::TVDB::Series as the result.
Get a single WebService::TVDB::Series by series id.
To use this module, you will need an API key from http://thetvdb.com/?tab=apiregister.
You can pass this key into the constructor, or save it to ~/.tvdb.
Andrew Jones <andrew@arjones.co.uk>
This software is copyright (c) 2013 by Andrew Jones.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install WebService::TVDB, copy and paste the appropriate command in to your terminal.
cpanm
cpanm WebService::TVDB
CPAN shell
perl -MCPAN -e shell install WebService::TVDB
For more information on module installation, please visit the detailed CPAN module installation guide.