I'm trying to setup Xamarin.Auth Twitter authentication. I have Xamarin.Auth working for Facebook. I get the facebook mobile login page and, after authenticating, it returns me to my Xamarin app. With the Twitter code, I always end up at the callbackURL after authentication. The process never returns to the Xamarin app. Any ideas? Thanks.
void Login_Twitter() { var auth = new OAuth1Authenticator(Twitter.ConsumerKey, Twitter.ConsumerSecret, new Uri(Twitter.RequestTokenURL), new Uri(Twitter.AuthorizeURL), new Uri(Twitter.AccessTokenURL), new Uri("http://www.livecrowds.com/processlogin.aspx"), // I ALWAYS END UP AT THIS URL AFTER AUTHENTICATION (IDictionary<string, string> accountProperties) => { string screen_name = ""; if (accountProperties.TryGetValue("screen_name", out screen_name)) { Account a = new Account(screen_name, accountProperties); // NEVER GET HERE
// AuthenticatorCompletedEventArgs e = new AuthenticatorCompletedEventArgs(a);
//Login_Twitter_Complete(e); // CompleteAuthentication(e);
}
return null;
});
// NEVER GET HERE
auth.Completed += Login_Twitter_Complete;
PresentViewController(auth.GetUI(), true, null);
}