The Movie Database Support

Hi, I'm trying to make a HTML5/Jquery app to use against The Movie Database API. So far so good, havn't had a single problem.

But I would like to understand the process of athenticating the user a bit better, cause I'm suspecting that I am doing it wrong to some degree.

As of now I:

  1. request token 2b. authenticate with login
  2. create a new session
  3. do stuff... (using https: https://api.themoviedb.org/3)

However, I'm doing it this way every time. Is the token, when validated with login once, a substitute for username and password for that user forever? If so I could just store the authenticated token localy and use the preffered 2a-method the next time? The expires_at:"..." parameter makes me confused.

Yes, I'm a novice :) You were to once.

Regards, me.

2 replies (on page 1 of 1)

Jump to last post

The token is just for validation. If a account has been successfully validated, you only need the session_id and append it to your request.

"The results of this query will return a session_id value. You should treat this value like a password. Store it securely. This is the value required in all of our write methods."

There's this document that helps explain the required steps as well: https://www.themoviedb.org/documentation/api/sessions

Cheers.

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?

Login