2
votes

I have properly registered my iOS app with Twitter and set permissions properly to allow email sharing. The Twitter development page clearly lists the permission and I triple checked and have the correct keys(in place of the xxxx below)

[[Twitter sharedInstance] startWithConsumerKey:@"xxxxx" consumerSecret:@"xxxxx"];

Twitter login works without the email request but when I try to ask for email using their provided code I get the following error. Note that I triple checked and have my emails listed in this account. I also checked that my iPhone lists the app under Twitter allow these apps to use your account.

Email (null), Error: Error Domain=TwitterAPIErrorDomain Code=37 "Your application may not have access to email addresses or the user may not have an email address. To request access, please visit https://support.twitter.com/forms/platform." UserInfo=0x16079de0 {NSLocalizedDescription=Your application may not have access to email addresses or the user may not have an email address. To request access, please visit https://support.twitter.com/forms/platform.}

Any thoughts.

1
Yes. I did not follow the sample code correctly. There sample work fine. - David Berger

1 Answers

0
votes

The Fabric team helped us resolve the issue. Our app's info.plist had the incorrect consumer key. When you set up Fabric for the first time, it will put a consumer key in your info.plist. When you set up TwitterKit, you need to replace that key with your Twitter app's consumer key. That solved the problem for us. Thanks