Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

jwt-simple

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jwt-simple

JWT(JSON Web Token) encode and decode module

  • 0.1.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
90K
decreased by-51.4%
Maintainers
1
Weekly downloads
 
Created

What is jwt-simple?

The jwt-simple npm package is a lightweight library for encoding and decoding JSON Web Tokens (JWT). It provides a simple API for creating and verifying JWTs, which are commonly used for authentication and secure data exchange.

What are jwt-simple's main functionalities?

Encoding a JWT

This feature allows you to encode a payload into a JWT using a secret key. The resulting token can be used for secure data transmission.

const jwt = require('jwt-simple');
const payload = { foo: 'bar' };
const secret = 'mysecretkey';
const token = jwt.encode(payload, secret);
console.log(token);

Decoding a JWT

This feature allows you to decode a JWT using the same secret key that was used to encode it. The decoded payload can then be accessed and used as needed.

const jwt = require('jwt-simple');
const token = 'your.jwt.token';
const secret = 'mysecretkey';
const decoded = jwt.decode(token, secret);
console.log(decoded);

Other packages similar to jwt-simple

Keywords

FAQs

Package last updated on 20 Aug 2013

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc