TwitterKit 3.1.1 logInWithCompletion crash when using different consumerKey from Info.plist


I followed the instruction and setup the twitterkit- in Info.Plist. According to the documentation in TwitterKit framework, I should be able to use a different consumerKey and consumerSecret other than the one from Info.Plist by calling the startWithConsumerKey method.


  • Start Twitter with your consumer key and secret. These will override any credentials
  • present in your applications Info.plist.
  • You do not need to call this method unless you wish to provide credentials other than those
  • in your Info.plist.
  • @param consumerKey Your Twitter application’s consumer key.
  • @param consumerSecret Your Twitter application’s consumer secret.
  • (void)startWithConsumerKey:(NSString *)consumerKey consumerSecret:(NSString *)consumerSecret;

But when I do that, it crashes my app at logInWithCompletion, and the error,
*** Terminating app due to uncaught exception ‘TWTRInvalidInitializationException’, reason: ‘Attempt made to Log in or Like a Tweet without a valid Twitter Kit URL Scheme set up in the app settings. Please see for more info.’

It works fine without any crash if I use the same consumerKey in Info.Plist.