Get IMDB ratings without any scraping
Update (20150712): If you know Python, check out the awesome IMDbPY library. It does the hard work for you, you just need to call some simple functions. Here is the docs.
Update (20130130): imdbapi.com seems to have moved to omdbapi.com. Links below are updated accordingly.
Problem
You want to get some data (e.g. rating) of a movie from IMDB. How to do it without any web scraping?
Solution #1
Someone made a simple API for this task, available at http://www.omdbapi.com/. You can search by ID or title.
Examples:
- search by ID: http://www.omdbapi.com/?i=tt0137523&t=
- search by title: http://www.omdbapi.com/?i=&t=fight+club
The result is a JSON string that contains basic movie info, rating included.
Solution #2
IMDB has a secret API too, made for mobile applications (available at http://app.imdb.com/). Here they say “For use only by clients authorized in writing by IMDb. Authors and users of unauthorized clients accept full legal exposure/liability for their actions.” So what comes below is strictly for educational purposes.
Examples:
- search by ID: http://app.imdb.com/title/maindetails?tconst=tt0137523
- search by title: http://app.imdb.com/find?api=v1&appid=iphone1&locale=en_US&q=fight+club
The result is a JSON string. Find more info about this API here.
Related posts
- Get the IMDB rating of a movie (via scraping)
Thanks reddit.
Update (20120222)
Python code for solution #1 is here.
Blog Stats
- 990,411 hits
Random Post
Recent Posts
Categories
Archives
- December 2019 (1)
- November 2019 (3)
- September 2019 (1)
- August 2019 (2)
- June 2019 (3)
- May 2019 (1)
- March 2019 (1)
- February 2019 (4)
- January 2019 (1)
- December 2018 (3)
- November 2018 (5)
- October 2018 (9)
- September 2018 (1)
- August 2018 (1)
- June 2018 (1)
- May 2018 (3)
- April 2018 (2)
- March 2018 (5)
- February 2018 (1)
- January 2018 (7)
- December 2017 (9)
- November 2017 (4)
- October 2017 (7)
- September 2017 (10)
- August 2017 (1)
- July 2017 (2)
- June 2017 (2)
- May 2017 (5)
- April 2017 (3)
- March 2017 (3)
- February 2017 (4)
- January 2017 (10)
- December 2016 (1)
- November 2016 (2)
- October 2016 (7)
- September 2016 (5)
- August 2016 (10)
- July 2016 (4)
- June 2016 (11)
- May 2016 (11)
- April 2016 (5)
- March 2016 (11)
- February 2016 (9)
- January 2016 (2)
- December 2015 (7)
- November 2015 (7)
- October 2015 (9)
- September 2015 (8)
- August 2015 (11)
- July 2015 (5)
- June 2015 (5)
- May 2015 (11)
- April 2015 (7)
- March 2015 (9)
- February 2015 (5)
- January 2015 (7)
- December 2014 (13)
- November 2014 (18)
- October 2014 (2)
- September 2014 (5)
- July 2014 (10)
- June 2014 (7)
- May 2014 (10)
- April 2014 (3)
- March 2014 (3)
- February 2014 (13)
- January 2014 (8)
- December 2013 (9)
- November 2013 (10)
- October 2013 (10)
- September 2013 (15)
- August 2013 (6)
- July 2013 (7)
- June 2013 (12)
- May 2013 (12)
- April 2013 (20)
- March 2013 (10)
- February 2013 (7)
- January 2013 (26)
- December 2012 (18)
- November 2012 (13)
- October 2012 (9)
- September 2012 (8)
- August 2012 (7)
- July 2012 (3)
- June 2012 (9)
- May 2012 (16)
- April 2012 (32)
- March 2012 (18)
- February 2012 (17)
- January 2012 (12)
- December 2011 (8)
- November 2011 (18)
- October 2011 (18)
- September 2011 (32)
- August 2011 (13)
- July 2011 (16)
- June 2011 (6)
- May 2011 (14)
- April 2011 (30)
- March 2011 (45)
- February 2011 (42)
- January 2011 (28)
- December 2010 (14)
- November 2010 (29)
- October 2010 (15)
- September 2010 (5)