0.0.4 • Published 6 years ago

@allbin/express-jwt-required-claims v0.0.4

Weekly downloads
-
License
ISC
Repository
gitlab
Last release
6 years ago

@allbin/express-jwt-required-claims

import express from 'express';
import jwt from 'express-jwt';
import claims_required from '@allbin/express-jwt-required-claims';

app = express();

app.get(
    '/protected',
    jwt({ secret: 'shhhhh' }),
    claims_required({
        uid: 123,
        access: { op: 'bits', value: 1 },
    }),
    (req, res, next) => {
        res.status(200);
    },
);

app.listen(8080);
0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago