I am trying to do some API calls. In my browser, I go to the following URLs:
http://192.168.1.2:8989/api/episode?seriesId=118&apikey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
http://192.168.1.2:8989/api/episode/id=12815?apikey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Both work as expected. The following curl command also works as expected:
curl http://192.168.1.2:8989/api/episode/id=12815?apikey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
However, this:
curl http://192.168.1.2:8989/api/episode?seriesId=118&apikey=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Gives me an “error”: “Unauthorized” message. I can get it to work by sending the API key in the header like so:
curl http://192.168.1.2:8989/api/episode?seriesId=118 --header “X-Api-Key:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx”
but shouldn’t it work either way? I turned the log up to trace to see what’s going on but I didn’t see any errors at all. I even cleared the logs and restarted to make sure.