1.0.3 • Published 4 years ago

decodebearertoken v1.0.3

Weekly downloads
5
License
MIT
Repository
github
Last release
4 years ago

Decode Bearer Token

This Package remove the Keyword "Bearer "eyJhbGciOiJI....for an Bearer Token.

Example Token: 'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjZGNkx5dmdNbHQwdGVYcnc1MX'

Return: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjZGNkx5dmdNbHQwdGVYcnc1MX'

Installation

Use the package manager npm to install decode-bearer-token.

npm install decode-bearer-token

Usage

const decode = require('decode-bearer-token);
const bearerToken ='Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjZGNkx5dmdNbHQwdGVYcnc1MX';
const token = decode(bearerToken);

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

1.0.2

4 years ago

1.0.3

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago