When I call a api in the url of browser, browser like chrome would redirect you to a non-SSL http,
thus your calling would not get into the API.
So, when this kind of problem shows up, make sure the url of your browser is using https,
if the url you type in is http, then that may be failed, changed that into a https request would be a nice way to get the solution.