kodecocodes/adva-materials

Network connection does not work anymore

Scythal opened this issue · 4 comments

It seems the network API does not connect anymore.
It's hard to say exactly where since the application has been made unnecessarily complicated.

Hello? Anyone still working on this project?

The problem is due to an "HTTP 401 Unauthorized" response from the server.

I see that instead of "token_type": "Bearer" (documentation), we have TOKEN_TYPE = "Bearer " in ApiConstants.kt. It's even visible in the book. So I don't know if the extra space is a problem, but simply removing it doesn't solve the 401.

Trying to get the complete response in that spaghetti of a code is taking too much time. You should really re-do this with an easier and less convoluted example.

Hi there! First of all, so sorry for the ridiculously late reply. I thought I had notifications on this, but apparently I didn't 🤦

I just went through the chapters, building the project from start to finish on each one, and never ran across this issue 🤔 from the looks of it, it seems that you're not using a valid API key / API secret. Did you get yours from https://www.petfinder.com/developers/?

Hi, thanks but it doesn't matter anymore, this can be closed.