Implementing social login
For our first example, we'll use Twitter as our third-party authentication provider. If you want to follow along with the example you will need a Twitter account, which is very quick to set up.
Setting up a Twitter application
In order for Twitter to recognize our application, we need to create a new app in Twitter's developer portal:
- Visit https://apps.twitter.com/ and click on Create New App.
- Fill in the Name, Description, Website, and Callback URL fields:
- If you've deployed your application to Heroku, you can use its Heroku URL here
- Otherwise, just fill in placeholder values for both fields (for example,
http://test.example.com/callback
)
- Click on Create your Twitter application.
- Click on the Settings tab and ensure that
Get Learning Node.js for .NET Developers now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.