CaTzil / service.subtitles.napisy24pl

Napisy24.pl is Addon for searching and downloading subtitles from KODI
GNU General Public License v2.0
8 stars 10 forks source link

API instead of parsing the site... #19

Closed sake12 closed 4 years ago

sake12 commented 8 years ago

Maybe you can use their API instead of parsing HTML?

Link is: http://napisy24.pl/libs/webapi.php?imdb=tt0068646 http://napisy24.pl/libs/webapi.php?title=Homeland%203x3

In return you get nice XML file...

CaTzil commented 8 years ago

There is a documentation of the API? The response to the query returns none standard XML, cause XML must have single root node.

sake12 commented 8 years ago

OK, so you have official API that uses hash to find subs, documentation is here: http://forum.napisy24.pl/viewtopic.php?f=9&t=142

and "unofficial" that searches through names. http://forum.napisy24.pl/viewtopic.php?f=26&t=226

You can see implementation of both here: http://areq.eu.org/dmnapi/

CaTzil commented 8 years ago

I don't want to restrict to md5 hash, cause it not always right, (especially if you stream your content...) The webapi.php?imdb=tt0068646 is irrelevant, Kodi doesn't give and IMDB Id. http://napisy24.pl/libs/webapi.php?title=Homeland%203x3 This is kinda good, but it return none standard API, so all the XML parsers will break on it.

d4m commented 8 years ago

Some time ago I wrote an addon using the official API, but never published it. https://github.com/d4m/service.subtitles.napisy24