Installation
npm install --save @types/jwt-client
Summary
This package contains type definitions for jwt-client (https://github.com/pauldijou/jwt-client).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jwt-client.
index.d.ts
declare module "jwt-client" {
interface JWTHeader {
typ: string;
alg: string;
}
interface JWTObject {
header: JWTHeader;
claim: any;
signature: string;
}
/**
* Read a string value (normally an HTTP header)
* from JSON Web Token to an Object
*/
function read(header: string): JWTObject;
/**
* Given a JWT object, stringify it back to
* its JWT representation.
*/
function write(value: JWTObject): string;
function keep(value: JWTObject, key?: any, storate?: any): void;
function remember(): void;
function forget(): void;
function get(): string;
function validate(value: JWTObject, issuer?: any, audience?: any): boolean;
}
Additional Details
- Last updated: Tue, 07 Nov 2023 0337 GMT
- Dependencies: none
Credits
These definitions were written by Timoteo Ponce.