Read More

Twitter Login in iOS App using swift 4.

Twitter Login in iOS App using swift 4.

Most of the time we provide the social login in app that will help user to login in app fast & smooth .

Here i have taken example of Twitter .

1: First try to follow this steps and add their SDK in App.

https://github.com/twitter/twitter-kit-ios/wiki/Installation

2: After that Go to Appdelgate.swift file and add this:

Now add this method also in Appdelegate.swift file.

3: Now write the code that will fetch user email & Name .

for this:

 

4: Now you have done all the required things for fetching the user credential in App

5: Now last important things that open the twitter developer site and select your app (where you have registered your iOS app)

1.1: Now you haveĀ  to call back URL for App.

2.1: To get the call back URL

a: open info.plist file and copy URL schemes.

it look like this.

copy this ” twitterkit-js5zHyDKTz2RTthfgV5xl9icA”

Note: ” twitterkit- Your Consumer Key”

 

and Now open your twitter developer account & select your app.

3.1: edit the App account .

4.1: go to callback URLs section and paste it.

like that.

 

5.1:Now save this.

6: Now you are able to fetch the user data without any issue.

 

 

 

if you have any issue regarding twitter login than freely to ask , we will wait for your valuable feedback

 

 

 

 

 

 

 

 

 

. . .

Comments (4)

Add Your Comment

  • Priya gupta
    Great!!
    Very Helpful
  • Tony Fotherby
    Thanks! The tip on the callback URLs was particularly helpful for me
  • css.php
    Hire Us!
    Brief us about your requirements and we'll get back to you.
    Woo! Hooy!
    We have just recieved your project brief and our expert will contact you shortly.
    Send Again
    Close