AllSubs’s vast collection of movie and TV series subtitles is now accessible via a simple API.
Usage example:
http://api.allsubs.org/index.php?search=heroes+season+4&language=en&limit=3
where
search is the search string
language is the language for the subtitles; if left empty all languages will be shown.
Available languages are: en, sq, ar, bg, zh, hr, cs, da, nl, et, fi, fr, ka, de, el, he, hi, hu, it, ja, ko, lv, lt, mk, no, pl, pt, ro, ru, sk, sl, es, sv, tr, vn
limit how many results to display, default is 10
Note:
- this API can be used by anyone. Anyway, we reserve the right to restrict access in case of abuse or excessiv traffic
- feel free to add a link back to our site if you’re using our API. Its not a requirement but it would be nice
- there is always room for improvements; should you have questions/suggestions don’t hesitate to contact us
Here’s a sample PHP code that you could use to read API’s results:
<?
$xml_request_url = ‘http://api.allsubs.org/index.php?search=heroes+season+4&language=en&limit=3′;
$xml = new SimpleXMLElement($xml_request_url, null, true);
echo “<BR>”.$xml->title;
echo “<BR>”.$xml->link;
echo “<BR>”.$xml->description;
echo “<BR>”.$xml->language;
echo “<BR>”.$xml->results;
echo “<BR>”.$xml->found_results;
foreach ( $xml->items->item as $item )
{
echo “<BR>Title :”.$item->title;
echo “<BR>Link :”.$item->link;
echo “<BR>Filename :”.$item->filename;
echo “<BR>Files in archive :”.$item->files_in_archive;
echo “<BR>Languages :”.$item->languages;
echo “<BR>Added on :”.$item->added_on;
echo “<BR>”;
}
?>

19 Responses
April 5th, 2010 at 8:50 am
nice work
April 19th, 2010 at 2:23 pm
The &-char (and) isn’t escaped in the files_in_archive-tag so the XML is invalid. Otherwise it looks nice.
May 18th, 2010 at 7:44 pm
how do you download the resulted subtitles ?
May 25th, 2010 at 9:27 am
Do you have an API for your movie trailers?
August 5th, 2010 at 1:55 pm
API is good idea but should be able to search by file hash
September 1st, 2010 at 9:51 am
Good idea but we don’t have the file hash. If you’d have an idea on how to get that then we could add it on site/search
September 15th, 2010 at 12:56 pm
Thanks m8! will be using this 4 sure in my new app!
October 12th, 2010 at 2:20 am
agreed, an api for the trailers would be great
November 14th, 2010 at 9:41 am
do you provide search by movie hash as opensubtitles.org?
November 15th, 2010 at 4:18 pm
No, we don’t offer this feature as we don’t know how to collect this data.
If you have any advice on this we’d be glad to add this feature.
November 23rd, 2010 at 4:35 pm
@Lupu- Right on! the problem is downloading from this site, not the searching. So difficult b/c when the captcha is legible- stacked letters, anyone? then it just keeps repeating, like it’s broke or case-sensitive or worse. This site takes so long to get a single download it’s lost the flava
December 7th, 2010 at 5:49 pm
Thanks for sharing with us the difficulties you’re having with the CAPTCHA we’re using.
It is on our TODO list, we’ll try to find a better way in the following weeks.
Should you have other suggestions please don’t hesitate to share them with us.
December 15th, 2010 at 10:55 am
The API request response should have an XML tag at the beginning, could you add this to the response?
AllSubs API: Subtitles Search
http://www.allsubs.org
en-us
1
24
http://www.allsubs.org/subs-download/heroes+season+4/1223435/
heroes-season-4-english-heroes-season-4-en.zip
Heroes – 4×01-02 – Orientation.HDTV.FQM.en.srt|Heroes – 4×17 – The Art of Deception.HDTV.2HD.en.srt|Heroes – 4×07 – Strange Attractors.HDTV.LOL.en.srt|Heroes – 4×08 – Once Upon a Time in Texas.HDTV.2HD.en.srt|Heroes – 4×07 – Strange Attractors.720p HDTV.DIMENSION.en.srt|Heroes – 4×05 – Hysterical Blindness.720p HDTV.X264.en.srt|Heroes – 4×09 – Shadowboxing.HDTV.LOL.en.srt|Heroes – 4×16 – Pass Fail.HDTV.LOL.en.srt|Heroes – 4×04 – Acceptance.HDTV.en.srt|Heroes – 4×01-02 – Orientation.720p HDTV.DIMENSION.en.srt|Heroes – 4×06 – Tabula Rasa.HDTV.NoTV.en.srt|Heroes – 4×10 – Brother’s Keeper.HDTV.FQM.en.srt|Heroes – 4×04 – Acceptance.HDTV.FQM.en.srt|Heroes – 4×14 – Let It Bleed.720p HDTV.DIMENSION.en.srt|Heroes – 4×06 – Tabula Rasa.720p HDTV.SiTV.en.srt|Heroes – 4×08 – Once Upon a Time in Texas.HDTV.NoTV.en.srt|Heroes – 4×12 – The Fifth Stage.HDTV.LOL.en.srt|Heroes – 4×19 – Brave New World.HDTV.LOL.en.srt|Heroes – 4×15 – Close to You.720p HDTV.DIMENSION.en.srt|Heroes – 4×03 – Ink.720p HDTV.DIMENSION.en.srt|Heroes – 4×11 – Thanksgiving.720p HDTV.DIMENSION.en.srt|Heroes – 4×13 – Upon This Rock.720p HDTV.DIMENSION.en.srt|Heroes – 4×13 – Upon This Rock.HDTV.LOL.en.srt|Heroes – 4×14 – Let It Bleed.HDTV.LOL.en.srt|Heroes – 4×15 – Close to You.HDTV.LOL.en.srt|Heroes – 4×12 – The Fifth Stage.720p HDTV.DIMENSION.en.srt|Heroes – 4×18 – The Wall.HDTV.LOL.en.srt|Heroes – 4×08 – Once Upon a Time in Texas.720p HDTV.CTU.en.srt|Heroes – 4×17 – The Art of Deception.HDTV.CTU.en.srt|Heroes – 4×09 – Shadowboxing.720p HDTV.DIMENSION.en.srt|Heroes – 4×10 – Brother’s Keeper.720p HDTV.DIMENSION.en.srt|Heroes – 4×04 – Acceptance.720p HDTV.CTU.en.srt|Heroes – 4×11 – Thanksgiving.HDTV.FQM.en.srt|Heroes – 4×03 – Ink.HDTV.FQM.en.srt|Heroes – 4×05 – Hysterical Blindness.HDTV.XII.en.srt|
en
2010-02-16
December 21st, 2010 at 3:19 pm
Good idea but we don’t have the file hash. If you’d have an idea on how to get that then we could add it on site/search
January 3rd, 2011 at 5:28 am
We made this change, thanks for your suggestion.
January 21st, 2011 at 10:04 am
Nice work.
I believe that a good add-on would be the returning xml to contain the official movie name and the movie’s year
January 21st, 2011 at 9:58 pm
Well, it would be indeed but unfortunately that’s not so easy to implement because of AllSubs special approach that has its limitations.
February 22nd, 2011 at 6:55 pm
It would be nice if I could see the ratings in the xml.
March 19th, 2011 at 2:00 pm
Good idea, thanks for it, we’ll try to implement it.
Leave a Comment