Hello,
I'm trying to do a Login with Twitter using Xamarin.Auth, on Android I had to use a custom schema url and works well, but on iOS after the webview is displayed a screen saying "Redirecting you back to your application, this may take a few minutes", it's never closed, so I never can get the authentication completed.
Here's my code
var topController = GetTopViewController();
var auth = new OAuth1Authenticator(
consumerKey: Constants.consumerKey,
consumerSecret: Constants.consumerSecret,
requestTokenUrl: Constants.requestTokenUrl,
authorizeUrl: Constants.authorizeUrl,
accessTokenUrl: Constants.accessTokenUrl,
callbackUrl: new Uri("http://twitter.com")
);
var _twitterController = auth.GetUI ();
auth.Completed += (sender, eventArgs) => {
_twitterController.DismissViewController (true, null);
if (eventArgs.IsAuthenticated)
{
//Stuff with authentication data
}
};
topController.PresentViewController (_twitterController, true, null);
}
I'm using a DependencyService, I've already tried callbackUrl using a scheme registered on the info.plist, but it doesn't work also.
I hope someone can help me.