enyo / node-tvdb

A node library for thetvdb.com
26 stars 12 forks source link

How to get seasons/episodes information? #12

Closed tbergeron closed 10 years ago

tbergeron commented 10 years ago

Hi,

I was checking this out: http://thetvdb.com/wiki/index.php?title=Programmers_API

Step 4: Get base information for each series
a. Retrieve <mirrorpath_zip>/api/<apikey>/series/<seriesid>/all/<language>.zip and extract <language>.xml and banners.xml.
b. Process the XML data in <language>.xml and store all <Series> data.
c. Download each series banner in banners.xml and prompt the user to see which they want to keep.
Note: Make sure you record <id> from each series, since it's returned in updates as <Series>.

Step 5: Get base information for each episode
a. Use <language>.xml from step 3 to find and store the data associated with your episode.
b. Use <filename> from results in step 5a to download the episode image from <mirrorpath_banners>/banners/<filename>.
Note: Make sure you record <id> from each episode, since it's returned in updates as <Episode>.

Is there any helper methods or something to deal with that part? How am I supposed to get seasons and episodes information using node-tvdb? Any example anywhere I could take a look at?

Thanks!

tbergeron commented 10 years ago

Nevermind, I just found out about:

tvdb.getInfo(show.id, function(err, results){
    console.log(err, results);
});