Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
app.use('/api', passport.authenticate('basic', { session: false }));
app.post('/api/ping', (req, res) => {
res.send(`pong ${req.user.emails[0].address}`);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment