RealmTeam / django-rest-framework-social-oauth2

python-social-auth and oauth2 support for django-rest-framework
MIT License
1.06k stars 191 forks source link

Handling redirect in SPAs #160

Closed saleem-git closed 6 years ago

saleem-git commented 6 years ago

Hi

This is more of an question than a issue. I came across the same issue as described in [authorization flow bug] (https://github.com/RealmTeam/django-rest-framework-social-oauth2/issues/72) I am using Vuejs as front end and DRF on the backed for API's

However after that the response has to be a redirect. This is where I have issues.

  1. The prompt screen (the Google consent pop up) instead of closing redirects to the success page.
  2. Am unable to send back the token I receive from your library as the response need to be a redirect.

HttpResponseRedirect(redirect_to=url)

I think am doing something wrong, pls guide, am on this for a few days now and cannot see a way out.

saleem-git commented 6 years ago

Am closing this issue as it has to be resolved at the client library VueJS.