New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@kofile/jwt-client

Package Overview
Dependencies
Maintainers
35
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@kofile/jwt-client - npm Package Compare versions

Comparing version 1.0.1 to 2.0.0

6

index.js

@@ -46,11 +46,11 @@ const jsonwebtoken = require('jsonwebtoken')

getUserId () {
get userId () {
return this._userId
}
getTenantId () {
get tenantId () {
return this._tenantId
}
getORT () {
get ort () {
return this._ort

@@ -57,0 +57,0 @@ }

@@ -1,53 +0,1 @@

{
"name": "@kofile/jwt-client",
"version": "1.0.1",
"description": "A simple JWT reader",
"repository": "https://github.com/kofile/jwt-client",
"author": "Evan Sherwood <evan@sherwood.io>",
"license": "MIT",
"main": "index.js",
"files": [
"index.js"
],
"dependencies": {
"jsonwebtoken": "^8.0.1"
},
"devDependencies": {
"@whizark/cz-cli": "^0.4.0",
"ava": "^0.22.0",
"commitizen": "^2.9.6",
"coveralls": "^2.13.1",
"cz-conventional-changelog": "^2.0.0",
"husky": "^0.13.4",
"lint-staged": "^3.6.0",
"nyc": "^11.1.0",
"prettier-standard": "^6.0.0",
"ramda": "^0.25.0",
"semantic-release": "^8.0.3",
"snazzy": "^7.0.0",
"standard": "^10.0.3"
},
"lint-staged": {
"*.js": [
"prettier-standard",
"git add"
]
},
"scripts": {
"precommit": "lint-staged",
"commit": "git-cz",
"lint": "standard | snazzy",
"test": "nyc ava",
"semantic-release": "semantic-release pre && npm publish && semantic-release post"
},
"config": {
"commitizen": {
"path": "node_modules/cz-conventional-changelog"
}
},
"nyc": {
"include": [
"index.js"
]
}
}
{"name":"@kofile/jwt-client","version":"2.0.0","description":"A simple JWT reader","repository":"https://github.com/kofile/jwt-client","author":"Evan Sherwood <evan@sherwood.io>","license":"MIT","main":"index.js","files":["index.js"],"dependencies":{"jsonwebtoken":"^8.0.1"},"devDependencies":{"@whizark/cz-cli":"^0.4.0","ava":"^0.22.0","commitizen":"^2.9.6","coveralls":"^2.13.1","cz-conventional-changelog":"^2.0.0","husky":"^0.13.4","lint-staged":"^3.6.0","nyc":"^11.1.0","prettier-standard":"^6.0.0","ramda":"^0.25.0","semantic-release":"^8.0.3","snazzy":"^7.0.0","standard":"^10.0.3"},"lint-staged":{"*.js":["prettier-standard","git add"]},"scripts":{"precommit":"lint-staged","commit":"git-cz","lint":"standard | snazzy","test":"nyc ava","semantic-release":"semantic-release pre && npm publish && semantic-release post"},"config":{"commitizen":{"path":"node_modules/cz-conventional-changelog"}},"nyc":{"include":["index.js"]}}

@@ -18,8 +18,12 @@ # @kofile/jwt-client

## API
client.getUserId()
client.userId
client.getTenantId()
client.tenantId
client.getORT()
client.ort
client.encoded
client.dump()
client.getRoleIdForTenant(tenantId)

@@ -45,12 +49,18 @@

// get user id
client.getUserId()
client.userId //=> 123
// get tenant id
client.getTenantId()
client.tenantId //=> 48121
//get ort
client.getORT()
client.ort //=> dsgsgasdgdfhws
// get encoded jwt
client.encoded //=> jsonwebtoken.sign(payload, 'key')
// get the entire payload body
client.dump() //=> payload
// get role id for a tenant
client.getRoleIdForTenant(tenantId)
client.getRoleIdForTenant(tenantId) //=> 1

@@ -57,0 +67,0 @@ // check if an error is a custom JwtError

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