The Movie Database support

I'm following this steps:

  1. Get new request_id with: https://api.themoviedb.org/3/authentication/token/new
  2. Then get permission for this request_id: https://www.themoviedb.org/authenticate/${requestToken}?redirect_to=http://localhost:3000/new_session
  3. After try create new session_id with permitted request_id: const url = "https://api.themoviedb.org/3/authentication/session/new"; const options = { method: "POST", headers: { accept: "application/json", "content-type": "application/json", Authorization: Bearer ${requestToken}, }, };

But got error: { status_code: 7, status_message: 'Invalid API key: You must be granted a valid key.', success: false }

Am I doing right?

3 svar (på side 1 af 1)

Jump to last post

@novi-movies said:

But got error: { status_code: 7, status_message: 'Invalid API key: You must be granted a valid key.', success: false }

Am I doing right?

DId you forget to put your API key?

@waffiqaziz said:

@novi-movies said:

But got error: { status_code: 7, status_message: 'Invalid API key: You must be granted a valid key.', success: false }

Am I doing right?

DId you forget to put your API key?

In my profile api settings (https://www.themoviedb.org/settings/api) two types of keys: "API Key" and "API Read Access Token". I didn't find out in what cases I have to use the "API Key". But you are right that if I use my "API Read Access Token" the request will succseed. But I was sure than I have to use new request_token to get new session_id.

@novi-movies said:

I didn't find out in what cases I have to use the "API Key".

API KEY uses as parameter

https://api.themoviedb.org/3/trending/all/week?api_key={{TMDB_API_KEY}}

while API Read Access Token as bearer token

Kan du ikke finde en film eller TV-serie? Log in og opret den.

Global

s focus the search bar
p open profile menu
esc luk et åbent vindue
? open keyboard shortcut window

På mediesider

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

På alle billedesider

a open add image window

On all edit pages

t open translation selector
ctrl+ s submit form

På diskussionssider

n opret ny diskussion
w toggle watching status
p toggle public/private
c toggle close/open
a åben aktivitet
r reply to discussion
l go to last reply
ctrl+ enter submit your message
(right arrow) next page
(left arrow) previous page

Indstillinger

Want to rate or add this item to a list?

Log ind