Hello,
I am trying to work my way through a tutorial that executes movie searches with the API, and I keep getting 401 results, so I am unable to proceed any further. My URL that I am sending with my http request is: http://api.themoviedb.org/3/Movie.search/en/xml/[API KEY]/gladiator
Is there something I am doing wrong in the formatting of the URL? I have a valid API Key.
Thanks, Shaun
¿No encuentras una película o serie? Inicia sesión para crearla:
¿Quieres puntuar o añadir este elemento a una lista?
¿No eres miembro?
Contestado por Travis Bell
el 6 de octubre de 2013 a las 11:37
Hi Shaun,
A few things. First, you're not making a valid APi request. The movie search URL is:
Second, a 401 error would be caused from not sending a valid
Accept
header. If you take a look at our documentation and depending what language you are programming in, there's working examples for most popular ones. A working cURL request for example, looks like so:Cheers.
Contestado por Brent
el 21 de noviembre de 2015 a las 22:54
I was a bit confused by the documentation regarding constructing a request URL. There's info on the endpoints, but not on how they fit into the URL itself. Just an idea for improvement going forward.