st4lk / django-rest-social-auth

OAuth signin with django rest framework
MIT License
519 stars 122 forks source link

Redirect_uri issue with Apple. #150

Open HAmer-Banna opened 2 years ago

HAmer-Banna commented 2 years ago

When I tried to implemented it for Apple I've faced a problem with redirect_uri, the problem is as following: when Android client try to signup it raises 'invalid redirect_uri', I found this article (https://johncodeos.com/how-to-add-sign-in-with-apple-button-to-your-android-app-using-kotlin/) that says I should implement a callback endpoint on the server side (Note: he use Node.js) to handle the redirect_uri but in his code he redirect the response to the same endpoint:

returnURL = '?success=true' + code + clientSecret + firstName + middleName + lastName + email res.redirect(returnURL)

My question is where should I redirect the request after I modify it on the server knowing that I still need some additional info from the client to send it to me in the body but they can't during the redirect_uri error?