My API key was working until last month. However, When I checked my API key this month, I got 401 error with this message "Invalid API key: You must be granted a valid key". Can you explain me why my API key Invalid?
Non podes atopar unha película ou serie? Inicia sesión para creala.
Queres valorar ou engadir o elemento a unha listaxe?
Non es membro?
Resposta de ticao2 🇧🇷 pt-BR
no 16 de decembro do 2023 ás 9:11PM
Better make sure your API Key has been canceled.
And the safest way is to do the test below.
Take a Test
Using a computer, desktop or notebook.
On some mobile devices this test may not work correctly.
In the URL below, change THE_KEY to your API Key.
https://api.themoviedb.org/3/movie/550?api_key=THE_KEY
Use this example to do a search using a new tab or window 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.
If it does not work, let us know right here.
Resposta de tmdb88890333
no 18 de decembro do 2023 ás 7:04PM
I got this error message instead of basic data of the Movie Fight Club
{"adult":false,"backdrop_path":"/hZkgoQYus5vegHoetLkCJzb17zJ.jpg","belongs_to_collection":null,"budget":63000000,"genres":[{"id":18,"name":"Drama"}],"homepage":"http://www.foxmovies.com/movies/fight-club","id":550,"imdb_id":"tt0137523","original_language":"en","original_title":"Fight Club","overview":"A ticking-time-bomb insomniac and a slippery soap salesman channel primal male aggression into a shocking new form of therapy. Their concept catches on, with underground \"fight clubs\" forming in every town, until an eccentric gets in the way and ignites an out-of-control spiral toward oblivion.","popularity":85.845,"poster_path":"/pB8BM7pdSp6B6Ih7QZ4DrQ3PmJK.jpg","production_companies":[{"id":711,"logo_path":"/tEiIH5QesdheJmDAqQwvtN60727.png","name":"Fox 2000 Pictures","origin_country":"US"},{"id":508,"logo_path":"/7cxRWzi4LsVm4Utfpr1hfARNurT.png","name":"Regency Enterprises","origin_country":"US"},{"id":4700,"logo_path":"/A32wmjrs9Psf4zw0uaixF0GXfxq.png","name":"The Linson Company","origin_country":"US"},{"id":25,"logo_path":"/qZCc1lty5FzX30aOCVRBLzaVmcp.png","name":"20th Century Fox","origin_country":"US"},{"id":20555,"logo_path":"/hD8yEGUBlHOcfHYbujp71vD8gZp.png","name":"Taurus Film","origin_country":"DE"}],"production_countries":[{"iso_3166_1":"DE","name":"Germany"},{"iso_3166_1":"US","name":"United States of America"}],"release_date":"1999-10-15","revenue":100853753,"runtime":139,"spoken_languages":[{"english_name":"English","iso_639_1":"en","name":"English"}],"status":"Released","tagline":"Mischief. Mayhem. Soap.","title":"Fight Club","video":false,"vote_average":8.44,"vote_count":27672}
Also, when I check my api authentication, Still I got this message. "status_message": "Invalid API key: You must be granted a valid key."
If My api Key got canceled, Can I ask why it has been canceled?
Resposta de ticao2 🇧🇷 pt-BR
no 19 de decembro do 2023 ás 7:24AM
Sorry I do not understand.
You did the test I indicated above and
Choose one of the possibilities.
Resposta de tmdb88890333
no 19 de decembro do 2023 ás 6:58PM
Sorry, Now I understand.
The answer is 1,
I received the correct Fight Club Movie's basic "data", instead of go to https://www.themoviedb.org/movie/550-fight-club this page.
Resposta de ticao2 🇧🇷 pt-BR
no 20 de decembro do 2023 ás 7:20AM
With this test we know that your API Key is still valid.
How or where did you do this check?
It was using "Try it!" in the Documents?
The "Try it!" option in DOCs it only works with the "Access Token Auth" option.
It doesn't work if you select the "API Key Auth" option.
Your API Key validation test is done using your Token.
https://developer.themoviedb.org/reference/authentication-validate-key
If your Token works then your API Key must also work.
If you checked in another way, please let us know which way it was.
Resposta de kmcowan
no 20 de decembro do 2023 ás 12:01PM
Hello TMDB Support ...
I am also receiving this message.
"status_message": "Invalid API key: You must be granted a valid key.",
Please advise. I did take the test above and it failed.
https://developer.themoviedb.org/reference/authentication-validate-key
Resposta de ticao2 🇧🇷 pt-BR
no 20 de decembro do 2023 ás 12:59PM
Take a Test
Using a computer, desktop or notebook.
On some mobile devices this test may not work correctly.
In the URL below, change THE_KEY to your API Key.
https://api.themoviedb.org/3/movie/550?api_key=THE_KEY
Use this example to do a search using a new tab or window 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://developer.themoviedb.org/docs/errors
If it does not work, let us know right here.
Resposta de kmcowan
no 20 de decembro do 2023 ás 1:29PM
Yes, I tried both the aforementioned test above, as test as the authentication test page. I'm unable to get a 200 response now, although this key used to work.
Resposta de ticao2 🇧🇷 pt-BR
no 20 de decembro do 2023 ás 2:03PM
Tested API Key and it didn't work
Create a new topic requesting it with the title: Regenerate API Key.
It will be in this new topic that you will receive the information that your API Key has been regenerated.
Or
Go to this page in your profile.
https://www.themoviedb.org/settings/api
If you already have it and want it to be changed or regenerated,
request it here by clicking on "Regenerate Key":
Resposta de kmcowan
no 20 de decembro do 2023 ás 2:41PM
Thank you. I was able to regenerate the key.
Resposta de tmdb88890333
no 20 de decembro do 2023 ás 6:40PM
It was "Try it" for "API key Auth".
Even the result of test shows my API Key is still valid, still I got fail error message on my portfolio, movie db page. "Failed to load resource: the server responded with a status of 400 ()"
Also, my "API Key Auth" is show still failed on "API Reference - Authentication" page.
Resposta de ticao2 🇧🇷 pt-BR
no 21 de decembro do 2023 ás 10:56AM
I don't know if I understood correctly, but...
Then your API Key is valid.
Can you tell us which of these errors is occurring?
See the list of TMDb server error warnings here.
https://www.themoviedb.org/documentation/api/status-codes
In your case:
Nothing works on the DOC pages if the "API Key Auth" option is selected.
Only works with the "Access Token Auth" option.
Resposta de Markysan
no 22 de decembro do 2023 ás 5:58AM
My API Key is not working. Please help. {"status_code":7,"status_message":"Invalid API key: You must be granted a valid key.","success":false}I
Resposta de ticao2 🇧🇷 pt-BR
no 22 de decembro do 2023 ás 8:36AM
Read this conversation from the beginning.
First do the test indicated here:
https://www.themoviedb.org/talk/657d0eeeb7fbbd06e430013f#657e58cd8f26bc1f50751e92
If your API Request worked correctly, read this second explanation:
https://www.themoviedb.org/talk/657d0eeeb7fbbd06e430013f#6582dc0a8586785635f65e85
If your problem has not yet been resolved, follow these instructions:
https://www.themoviedb.org/talk/657d0eeeb7fbbd06e430013f#65833a81ea7b0e51fa270f0f