This is a simple NodeJS backend demonstrating the authentication of Meetup and LinkedIn via oAuth 2.0.
passport
passport-linkedin-oauth2
passport-oauth2-meetup
dotenv
express
express-session
- Download or clone this repo.
- Create a Meetup oAuth consumer here.
- Create a LinkedIn application here for leveraging its APIs.
- Rename
.env.sample
to.env
and paste your ClientID and ClientSecret keys created in the above steps. - Run
$ npm install
under the project root directory. - Start server:
$ npm start
- LinkedIn authentication:
http://localhost:3000/auth/linkedin
- Meetup authentication:
http://localhost:3000/auth/meetup
After it's authencticated successfully, it will be redirected to http://localhost:3000/api
with the following JSON response:
{
message: "The authentication has been done successfully!"
}