capacitor-community / generic-oauth2

Generic Capacitor OAuth 2 client plugin. Stop the war in Ukraine!
MIT License
223 stars 106 forks source link

Angular Interceptor Token Refresh #195

Closed Wahsner closed 2 years ago

Wahsner commented 2 years ago

Hello,

Looking for some advise and or a possible feature enhancement.

However, how can I pause/intercept the other http request from being sent until the refresh token has been handled? I've googled around and every example/docs I can find suggest a http subscription but the refreshToken method returns a promise.

Looking over the documentation, there isn't anyway of exposing the refresh token url (or the authentication url) or is there any it just isn't documented?

Library version:

Angular 13 Latest Ionic v5 Latest Capacitorjs Latest Capacitor-oauth2

OAuth Provider:

wiebo-troost commented 2 years ago

I noticed this issue was closed and completed. I am trying to implement this also, what was your solution? Thanks!