Поддръжка на The Movie Database

Hi, I was working just fine a few minutes ago with the API, and now I'm getting this error.

{
status_code: 7,
status_message: "Invalid API key: You must be granted a valid key.",
success: false
}

What did I do? Could you grant me access again, I'm just using the APIs for learning purposes.

Thank you

3 отговора (на страница 1 от общо 1)

Jump to last post

@MBerrio said:
Hello im getting and error code 7 401
Hi, I was working just fine a few minutes ago with the API, and now I'm getting this error.

{
status_code: 7,
status_message: "Invalid API key: You must be granted a valid key.",
success: false
}

What did I do? Could you grant me access again, I'm just using the APIs for learning purposes.
Thank you

Take a Test

Click to go to your Profile > API: https://www.themoviedb.org/settings/api
At the bottom of the page, below, you'll find the Example API Request.
https://api.themoviedb.org/3/movie/550?api_key=THE_KEY
Use this example to do a search using a new tab in your browser.
You will receive the basic data of the Movie Fight Club (1999)
https://www.themoviedb.org/movie/550-fight-club
If it works, your Key is OK.

When there is a problem, the TMDb Server sends a message.
Can you tell which message the server sent?
Here is a list of possible messages:
https://www.themoviedb.org/documentation/api/status-codes

If it does not work, let us know right here.

Hi, I did that and it seems the key is working fine with the fight club data; however, my dev tools show status code 7 in my react app when I make the requests. Also, I stated in the original message that the key was working fine in my react app and now I get that status code 7 and I haven't made any changes in my code, so I don't understand why I am getting that 401-status code 7, the only thing I did was to deploy it through Netlify free service to add it to my portfolio, and now is not working but also is not working in my localhost:3000 either, so what is the issue?

Thanks

@MBerrio said:
Hi, I did that and it seems the key is working fine with the fight club data;
however, my dev tools show status code 7 in my react app when I make the requests.
Also, I stated in the original message that the key was working fine in my react app

As the test worked, so I believe the problem may be in your code.

and now I get that status code 7 and I haven't made any changes in my code,
so I don't understand why I am getting that 401-status code 7,
the only thing I did was to deploy it through Netlify free service to add it to my portfolio,
and now is not working but also is not working in my localhost:3000 either, so what is the issue?
Thanks

The problem must be in the code that is building your API Request, or something like that,
and is sending the Request to the TMDb Server.

It is very common to find people here with this type of problem.
A little mistake, a copy and paste with an extra space, or less character, an exchange of characters,
a quote left, use a dash when it should be underline, in short a typo and the answer can be that.
Even if the API Key is correct. The Requisition is that it has a little mistake.

I will place 6 API requests here. The first 5 with error.
You can see that the API Key is correct but the answer is Invalid API key or could not be found.

1 https://api.themoviedb.org/3/movie/550&api_key=THE_KEY  
2 https://api.themoviedb.org/3/movie/550/api_key=THE_KEY  
3 https://api.themoviedb.org/3/movie/550?api-key=THE_KEY  
4 https://api.themoviedb.org/3/movie/550? api_key=THE_KEY    
5 https://api.themoviedb.org/3/movie/'550'?api_key=THE_KEY  
6 https://api.themoviedb.org/3/movie/550?api_key=THE_KEY    

My suggestion is to check if there is any way for you to view the API Request that your APP is sending to the TMDb server.
Not the construction of the code, but the requisition built, final.
If possible, post the Request here.
If this is not possible, then you need to check in your code if there is a mistake, like the mistake in the examples above.
The error is usually in this segment of the API Request: ....?api_key=12345....

Не можете да откриете филм или сериал? Влезте, за да го създадете.

Глобални

s фокусиране на лентата за търсене
p отваряне на меню "Профил"
esc затваряне на отворен прозорец
? отваряне на прозореца за клавишните комбинации

На страниците за медиите

b връщане назад
e към страницата за редактиране

На страниците за сезони

(стрелка надясно) към следващ сезон
(стрелка наляво) към предишния сезон

На страниците за епизоди

(стрелка надясно) към следващ епизод
(стрелка наляво) предишен епизод

На всички страници за изображения

a отваряне на прозорец за добавяне на изображение

На всички страници за редактиране

t меню за избор на език, на превода
ctrl+ s изпращане на форма

На страниците за дискусия

n създаване на нова дискусия
w статус на наблюдаване
p публична/лична
c затваряне/отваряне
a отваряне на действия
r отговаряне в дискусия
l към последния отговор
ctrl+ enter изпращане на вашето съобщение
(стрелка надясно) следваща страница
(стрелка наляво) предишна страница

Настройки

Искате ли да го оцените или добавите към списък?

Вход