The Movie Database Support

Hello !

First, thanks for all the hard work on the documentation and API !

I'm trying to set up my auth flow for the Tmdb API, however, I'm struggling to understand the exact authorisation scope of the various tokens.

From my understanding of the documentation:

  1. The Read Only Access Token (read token) is to be used as an API key and only grant read access for v4
  2. The api_key serves the same purpose forv3
  3. The Access Token (write token) is to be used for Account & List endpoints in v4
  4. The session_id is to be used for Account & List endpoints in v3
  5. The Guest session_id is only for rating shows/movies/episodes in v3

However, it seems that:

  1. The read-only token for v4grants access to all accounts & lists endpoints in v3 or v4 regardless (for GET at least, not POST/DELETE it seems)
  2. The session_id + api_key works on v4 endpoints (without v4 read or write token)
  3. All account_id query parameters for those endpoints are ignored in favour of the token or session id holder

So in the end I'm confused about which token I should use.

  1. Can I use v4 access token or session_id+api_key interchangeably for all endpoints? Same for api_key and read-only token ?
  2. What is the point of converting a write token to a session id if the former works as is?
  3. Are all GET endpoints for Account & Lists accessible with read-only tokens? If so doesn't that mean I leak the api_key account's holder information if I bundle my app with a read-only token instead of api_key?
  4. What is the point of object_account_id (v4) and account_id (v3) if the return is based on the auth token holder?

Thanks for any insight you can provide :)

2 replies (on page 1 of 1)

Jump to last post

Hi @dvcol,

The v3 API key and v4 access token can be treated as one and the same. They provide access to any of the public read methods. For example, unless a list is marked as private, either way of authenticating can be used to get a list. Lists are public by default so this would be the case for the vast majority of lists.

A session ID, or user authorized access token is required to do any user specific actions like rate a movie, or access private lists.

@travisbell said:

Hi @dvcol,

The v3 API key and v4 access token can be treated as one and the same. They provide access to any of the public read methods. For example, unless a list is marked as private, either way of authenticating can be used to get a list. Lists are public by default so this would be the case for the vast majority of lists.

A session ID, or user authorized access token is required to do any user specific actions like rate a movie, or access private lists.

but im able to mark a movie as favorite on any account without session_id or access_token but only with api key

Can't find a movie or TV show? Login to create it.

Global

s focus the search bar
p open profile menu
esc close an open window
? open keyboard shortcut window

On media pages

b go back (or to parent when applicable)
e go to edit page

On TV season pages

(right arrow) go to next season
(left arrow) go to previous season

On TV episode pages

(right arrow) go to next episode
(left arrow) go to previous episode

On all image pages

a open add image window

On all edit pages

t open translation selector
ctrl+ s submit form

On discussion pages

n create new discussion
w toggle watching status
p toggle public/private
c toggle close/open
a open activity
r reply to discussion
l go to last reply
ctrl+ enter submit your message
(right arrow) next page
(left arrow) previous page

Settings

Want to rate or add this item to a list?

உள் நுழை