Skip to content

Instantly share code, notes, and snippets.

@evgeniy-logvinov
Created January 7, 2020 14:33
Show Gist options
  • Save evgeniy-logvinov/bf472c9560ec2c28fa1292f5c6d2331b to your computer and use it in GitHub Desktop.
Save evgeniy-logvinov/bf472c9560ec2c28fa1292f5c6d2331b to your computer and use it in GitHub Desktop.
Refresh token
router.post('/refresh', async (req, res, next) => {
try {
const refreshToken = getRefreshToken(req);
const newRefreshToken = await securityService.refresh({ refreshToken }, getClientInfo(req));
res.send(newRefreshToken);
} catch (e) {
next(e);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment