Hi guys,
I am a little stressed and confuzzled right now. I have this Android app I had been building all this time. The app now needs to access data through an API. The API has OAuth 2.0 Authorization (this was set on Azure).
From what I understand, to access data from this API, I need to send a Client ID together with a secret. Once these are sent to the server, a token will be sent back to me.
I did a little googling around this and found this link, which goes around doing this using RetroFit and OkHttp: https://futurestud.io/blog/oauth-2-on-android-with-retrofit
When following the steps in this article, the android app does ask the user to open their browser, authorize the app (this is through an intent). After the user has authorized this, the browser is supposed to close and focus should go back to the android app... that is the part that isn't working for me.
Has anyone else had to use an API with OAuth 2.0 authentication? What would you have done?
I am trying to find similar implementations of this on the net so I can see what else I can try.
I am a little stressed and confuzzled right now. I have this Android app I had been building all this time. The app now needs to access data through an API. The API has OAuth 2.0 Authorization (this was set on Azure).
From what I understand, to access data from this API, I need to send a Client ID together with a secret. Once these are sent to the server, a token will be sent back to me.
I did a little googling around this and found this link, which goes around doing this using RetroFit and OkHttp: https://futurestud.io/blog/oauth-2-on-android-with-retrofit
When following the steps in this article, the android app does ask the user to open their browser, authorize the app (this is through an intent). After the user has authorized this, the browser is supposed to close and focus should go back to the android app... that is the part that isn't working for me.
Has anyone else had to use an API with OAuth 2.0 authentication? What would you have done?
I am trying to find similar implementations of this on the net so I can see what else I can try.