Unable to use custom domain on native SwiftUI

Hi!

I implemented basic login for default Auth0 domain which works, but I’m struggling to get an accessToken that I can use for my custom api; whenever I set my custom domain on the callback urls or in Auth0.plist, I stop getting redirected to my app after logged. I double checked all the configuration is fine, so I’m guessing maybe I’m missing something obvious here.

Any tip pointing in the right direction would be much appreciated :slight_smile:

Hi @ssantos

Welcome to the Auth0 Community!

Could you let me know if you pass in an audience when you initialize the webAuth() function and what audience are you passing in?

If the audience you pass in contains your custom domain, please try to remove the .audience line or use your generic Auth0 domain and let me know if that works.

Kind Regards,
Nik

Thank you Nik for your quick reply.

I tried my custom api id as the audience field, but finally seems to be a simulator issue (iPhone 16 18.x for the record); didn’t try in older simulators, but it works on real hardware.

Best.

S