Reputation: 43
I am making a simple restful API with Node.js and MongoDB. I want to use Twitter Strategy of Passport.js. There are tons of example for web apps. Routes are redirected to an HTML page. I don't want this. How can I solve my situation?
Upvotes: 0
Views: 483
Reputation: 5718
You can check my tutorial here. I have explained the whole workflow.
You should use passport-twitter-token library. Passport-twitter is not the most suitable one for REST API. This was the biggest issue when I have been working on authentication with Twitter for REST API.
Upvotes: 1