GithubHelp home page GithubHelp logo

Question About Movie Rating about tmdbsimple HOT 1 CLOSED

celiao avatar celiao commented on July 27, 2024
Question About Movie Rating

from tmdbsimple.

Comments (1)

celiao avatar celiao commented on July 27, 2024

Thanks for letting me know you like this package. I had fun developing it.

The method you want is releases(). Countries have different rating systems, so releases() will return release data for each country, including:

  • The ISO 3166 country code
  • The certification (or movie rating)
  • The release date
  • A primary release flag

Here's an example of how to extract the certification (or movie rating) information for each country:

>>> import tmdbsimple as tmdb
>>> tmdb.API_KEY = 'YOUR_API_KEY_HERE'
>>> movie = tmdb.Movies(603)
>>> response = movie.releases()
>>> for country in movie.countries:
...      print(country['iso_3166_1'] + ': ' + country['certification'])
...
US: R
CZ: 12
NO: A
GB: 15
IT: T
DE: 16
FI: K-16
BR: 12 anos
HU: 12
NL: 12
JP: PG-12
CA: 14A
AQ:
FR: U
BG: C
KR: 12세 관람가
AU: M

Check out The Movie Database documentation for more information about the endpoints, which correspond to the methods in tmdbsimple. For example, go to the REFERENCE section of the menu on the left side. Click on Movies, then click on /movie/{id}/releases, then click on GET. From the Response on the right, you can determine how to extract the information of interest.

from tmdbsimple.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.