Closed charlottemoche closed 11 months ago
Have you registered your custom URL scheme (personify
) in your app? See the README of SpotifyAPIExampleApp for help. See also Apple's documentation.
hmm yes i have registered my custom url and set the env vars in the run edit: ah okay now i'm no longer getting the safari error, going to check out the sample app. thank you!
The apple documentation I linked to uses UIKit to handle the incoming URL. For SwiftUI, use the onOpenURL(perform:)
modifier. See this article. Please confirm whether or not you are successfully able to redirect back to your app from the browser.
confirmed, this was the ticket! thank u so much :)
Hi!
I am very baby to swift and all of this so I could be completely missing something simple.
I am successfully able to open the Safari window within my app. I am also able to successfully login. However, when I click Agree, I am seeing "Safari cannot open the page because the address is invalid."
It seems I am receiving back a valid url when I print it, and yet it's having trouble with the redirect.
I am using SwiftUI and iOS 17.
In my developer dashboard, my redirect uri is personify://content. I am not certain this is actually correct. I had it working properly with a redirect using the SDK and personify:// but it won't work that way for this instance. So I added content.
At the top of my LoginView:
LoginView also:
and
in my ContentView:
i am just a little lost and would appreciate some assistance, thank you so much!