for example, when i aceess /movie/popular and click the GET button ,the right side url is like this: http://api.themoviedb.org/3/movie/popular , then i input the api key like this:
api_key : xxxxxxxx
finally,i click the "CallResource" button ,the spinner option is "production", the result is "Invalid API key", but i am sure my key is ok. when i switch the spinner option to "Mock Server", the result is ok. i don't know why?
after,i use the volley lib to access this URL in the android demo and set the header like this:
headers.put("content-type","application/json");
headers.put("api_key", Constans.API_KEY);
then also the response is "401" .
plz help me !
forgive me , my english was so bad :)
Thanks :)
Can't find a movie or TV show? Login to create it.
Ma doonaysaa inaad qiimayso ama ku darto shaygan liiska?
Ma aha xubin?
Reply by a_bin
on August 20, 2015 at 5:53 AM
what can i input in the Headers ? (apiary.io right side console)
Reply by Travis Bell
on August 20, 2015 at 11:26 AM
Hi a_bin,
Apiary by default, expects the api key to be input as a header which we do not support. You will need to pass it in as a query parameter, i.e.:
Cheers.
Reply by a_bin
on August 20, 2015 at 10:10 PM
ok, thank u !