@types/passport-jwt

  • Version 3.0.9
  • Published
  • 6.35 kB
  • 3 dependencies
  • MIT license

Install

npm i @types/passport-jwt
yarn add @types/passport-jwt
pnpm add @types/passport-jwt

Overview

TypeScript definitions for passport-jwt

Index

Classes

class Strategy

class Strategy extends PassportStrategy {}

    constructor

    constructor(opt: StrategyOptions, verify: VerifyCallback);

      constructor

      constructor(opt: StrategyOptions, verify: VerifyCallbackWithRequest);

        property name

        name: string;

          Interfaces

          interface JwtFromRequestFunction

          interface JwtFromRequestFunction {}

            call signature

            (req: express.Request): string | null;

              interface SecretOrKeyProvider

              interface SecretOrKeyProvider {}

                call signature

                (
                request: express.Request,
                rawJwtToken: any,
                done: (err: any, secretOrKey?: string | Buffer) => void
                ): void;

                  interface StrategyOptions

                  interface StrategyOptions {}

                    property algorithms

                    algorithms?: string[] | undefined;

                      property audience

                      audience?: string | string[] | undefined;

                        property ignoreExpiration

                        ignoreExpiration?: boolean | undefined;

                          property issuer

                          issuer?: string | string[] | undefined;

                            property jsonWebTokenOptions

                            jsonWebTokenOptions?: VerifyOptions | undefined;

                              property jwtFromRequest

                              jwtFromRequest: JwtFromRequestFunction;

                                property passReqToCallback

                                passReqToCallback?: boolean | undefined;

                                  property secretOrKey

                                  secretOrKey?: string | Buffer | undefined;

                                    property secretOrKeyProvider

                                    secretOrKeyProvider?: SecretOrKeyProvider | undefined;

                                      interface VerifiedCallback

                                      interface VerifiedCallback {}

                                        call signature

                                        (error: any, user?: Express.User | false, info?: any): void;

                                          interface VerifyCallback

                                          interface VerifyCallback {}

                                            call signature

                                            (payload: any, done: VerifiedCallback): void;

                                              interface VerifyCallbackWithRequest

                                              interface VerifyCallbackWithRequest {}

                                                call signature

                                                (req: express.Request, payload: any, done: VerifiedCallback): void;

                                                  Namespaces

                                                  namespace ExtractJwt

                                                  namespace ExtractJwt {}

                                                    function fromAuthHeader

                                                    fromAuthHeader: () => JwtFromRequestFunction;

                                                      function fromAuthHeaderAsBearerToken

                                                      fromAuthHeaderAsBearerToken: () => JwtFromRequestFunction;

                                                        function fromAuthHeaderWithScheme

                                                        fromAuthHeaderWithScheme: (auth_scheme: string) => JwtFromRequestFunction;

                                                          function fromBodyField

                                                          fromBodyField: (field_name: string) => JwtFromRequestFunction;

                                                            function fromExtractors

                                                            fromExtractors: (extractors: JwtFromRequestFunction[]) => JwtFromRequestFunction;

                                                              function fromHeader

                                                              fromHeader: (header_name: string) => JwtFromRequestFunction;

                                                                function fromUrlQueryParameter

                                                                fromUrlQueryParameter: (param_name: string) => JwtFromRequestFunction;

                                                                  Package Files (1)

                                                                  Dependencies (3)

                                                                  Dev Dependencies (0)

                                                                  No dev dependencies.

                                                                  Peer Dependencies (0)

                                                                  No peer dependencies.

                                                                  Badge

                                                                  To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                  You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/passport-jwt.

                                                                  • Markdown
                                                                    [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@types/passport-jwt)
                                                                  • HTML
                                                                    <a href="https://www.jsdocs.io/package/@types/passport-jwt"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>