0.2.1 • Published 3 years ago

temp-token v0.2.1

Weekly downloads
1
License
ISC
Repository
github
Last release
3 years ago

temp-token

npm npm NPM GitHub package.json dynamic

NPM

Installation

Install it using npm :

$ npm install temp-token

Or install using yarn :

$ yarn add temp-token

Getting started

Import module with this code :

var tempToken = require('temp-token');

And create new TempToken class :

var token = new tempToken.TempToken("your_secret_key");

Usage

Make a temporary token with this function :

token.make("your_token", 1800000); //time in seconds

Check the token is valid :

token.checkToken("your_temp_token");
//if the token is valid, then it returns true
//otherwise it returns false
0.2.1

3 years ago

0.2.0

3 years ago

0.2.0-dev

3 years ago

0.1.0

3 years ago

0.1.0-dev

3 years ago

1.0.0

3 years ago