Hi, I’m building a web app that’s wrapped as a nat...
# ask-a-descoper
o
Hi, I’m building a web app that’s wrapped as a native app. When users choose to authenticate via Apple, the flow opens inside an in-app browser rather than the external system browser. The problem is that after the authentication completes, the in-app browser doesn’t close - it just leaves the user logged in inside that browser, instead of returning control to the app. How can I configure Descope so that the Apple auth flow properly closes the in-app browser (or redirects back to the app) after authentication? Thanks!
n
Hey Omer, For Apple login inside a native app, the flow should be launched with the system browser session (iOS
ASWebAuthenticationSession
, Android Chrome Custom Tabs) rather than an embedded WebView. That way, once the callback URL is hit, the sheet automatically closes and control returns to your app. You’ll need to configure your redirect URI in both Descope and your app settings. We have a guide here with the full flow: https://docs.descope.com/auth-methods/oauth/with-sdks/mobile#finish-oauth
o
OK thanks. I will check if that is possible by my Native wrapper service
For further context - at the moment my Native wraper enables me to authenticate the user in a native way via apple and then after a successful auth it exposes these user states: email, name, subject, initial sign in & error Before using descope I would just grab that email, send it to my backend, find the related user and send back a token to the frond end Regarding descope - If I get this correctly these are not enogh to get tokens from descope (right?) so I guess the alternative is to need to find a way to connect the Natively native apple auth to descope in some way, right? For context this is Natively's documentaion page about apple authentication: https://docs.buildnatively.com/guides/integration/apple-sign-in#natively-apple-sign-in Thanks!
r
Hey Omer, Nativley does not have an integration that allows this kind of connectivity with Descope. I looked for an OIDC integration that will allow us to embed a Descope flow, but it seems like it does not have it. I would like you to move to Descope completely and not relay on Nativley, can we jump on a call to discuss your limitations and what can be done?
o
Hey Reuven, thanks for the fast reply. Sure Im avaiable for a call
✅ 1