1.1.13 • Published 6 years ago

tokenhelper v1.1.13

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

Token helper

manage subiz access token and refresh token for clients

Install

npm i --save tokenhelper

Usage

example

Standalone

const th = require('tokenhelper')
let token = th.createHelper({tokenep: "https://subiz.com/oauth/"})

// user login => got tokens
token.reset({account_id, agent_id, access_token, refreshtoken, expires_in})

// use the token

var tk = await token.get()
if (tk.error) {
	throw tk.error
}

// ...
apireq.setQuery({access_token: tk.access_token}).send()
// ...
1.1.13

6 years ago

1.1.12

6 years ago

1.1.11

6 years ago

1.1.10

6 years ago

1.1.9

7 years ago

1.1.8

7 years ago

1.1.6

7 years ago

1.1.5

7 years ago

1.1.4

7 years ago

1.1.3

7 years ago

1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.0

7 years ago