authentication error requesting /api/states/own

4 years 5 months ago #960 by chris.dorsey
I have a 'regular' account (i.e. not a Data Access acct) and a receiver sending ads-b messages to OpenSkyNetwork. When I try to access the own REST endpoint at /api/states/own, passing my login credentials using Basic auth, I get a 401/Unauthorized response with the message "Bad credentials". Do I need a "Data Access" account to access the own endpoint?

Thanks!

Please Log in or Create an account to join the conversation.

4 years 5 months ago #961 by strohmeier
Your receiver looks like it is indoor and has only very occasional, patchy reception. If you're logged in to the website, does this link work? opensky-network.org/api/states/own

Please Log in or Create an account to join the conversation.

4 years 5 months ago #964 by chris.dorsey
Replied by chris.dorsey on topic authentication error requesting /api/states/own
Thanks for the reply. If I'm logged into the website, and follow that link thru the browser, the request is successful, and I do see states from my receiver. However that request isn't using Basic authentication, it looks like the initial login request sets a cookie, which is then passed on subsequent requests in the browser. If I try passing that same cookie with my API request (I'm testing with Postman and also testing using .NET HttpClient), then it does work, so that seems to indicate that my account is OK, but Basic Auth isn't working? I'm essentially doing what the Java API does, but no luck with Basic Auth.

Thanks.

PS. I'm also planning on getting a better outdoor antenna, should have better reception then.

Please Log in or Create an account to join the conversation.

Powered by Kunena Forum
This website uses cookies to offer you the best experience of our services. By using this website you agree to our privacy policy!