@types/hapi-auth-bearer-token
Advanced tools
Comparing version 6.1.2 to 6.1.3
@@ -25,9 +25,9 @@ // Type definitions for hapi-auth-bearer-token 6.1 | ||
validate: Validate; | ||
accessTokenName?: string; | ||
allowQueryToken?: boolean; | ||
allowCookieToken?: boolean; | ||
allowMultipleHeaders?: boolean; | ||
allowChaining?: boolean; | ||
tokenType?: string; | ||
unauthorized?: (message: string | null, scheme: string) => any; | ||
accessTokenName?: string | undefined; | ||
allowQueryToken?: boolean | undefined; | ||
allowCookieToken?: boolean | undefined; | ||
allowMultipleHeaders?: boolean | undefined; | ||
allowChaining?: boolean | undefined; | ||
tokenType?: string | undefined; | ||
unauthorized?: ((message: string | null, scheme: string) => any) | undefined; | ||
} | ||
@@ -34,0 +34,0 @@ |
{ | ||
"name": "@types/hapi-auth-bearer-token", | ||
"version": "6.1.2", | ||
"version": "6.1.3", | ||
"description": "TypeScript definitions for hapi-auth-bearer-token", | ||
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/hapi-auth-bearer-token", | ||
"license": "MIT", | ||
@@ -24,4 +25,4 @@ "contributors": [ | ||
}, | ||
"typesPublisherContentHash": "186f2957ab9a1719967b43a8f4b41da87bc4aab082d00deb917f121a9b5693af", | ||
"typeScriptVersion": "3.2" | ||
"typesPublisherContentHash": "bd0b2af80c10e6e29459826307833912dc5059afb1e08dd6f8e67e31a47727e8", | ||
"typeScriptVersion": "3.6" | ||
} |
@@ -9,5 +9,48 @@ # Installation | ||
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/hapi-auth-bearer-token. | ||
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/hapi-auth-bearer-token/index.d.ts) | ||
````ts | ||
// Type definitions for hapi-auth-bearer-token 6.1 | ||
// Project: https://github.com/johnbrett/hapi-auth-bearer-token | ||
// Definitions by: Rodrigo Saboya <https://github.com/saboya> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
// TypeScript Version: 2.8 | ||
import { | ||
Request, | ||
Plugin, | ||
ResponseToolkit, | ||
AuthenticationData, | ||
} from '@hapi/hapi'; | ||
type ValidateReturn = AuthenticationData & { isValid: boolean }; | ||
declare module '@hapi/hapi' { | ||
interface ServerAuth { | ||
strategy(name: string, scheme: 'bearer-access-token', options: BearerToken.SchemaOptions): void; | ||
} | ||
} | ||
declare namespace BearerToken { | ||
interface SchemaOptions { | ||
validate: Validate; | ||
accessTokenName?: string | undefined; | ||
allowQueryToken?: boolean | undefined; | ||
allowCookieToken?: boolean | undefined; | ||
allowMultipleHeaders?: boolean | undefined; | ||
allowChaining?: boolean | undefined; | ||
tokenType?: string | undefined; | ||
unauthorized?: ((message: string | null, scheme: string) => any) | undefined; | ||
} | ||
type Validate = (request: Request, token: string, h: ResponseToolkit) => Promise<ValidateReturn> | ValidateReturn; | ||
} | ||
declare var BearerToken: Plugin<{}>; | ||
export = BearerToken; | ||
```` | ||
### Additional Details | ||
* Last updated: Fri, 25 Sep 2020 23:55:53 GMT | ||
* Last updated: Thu, 08 Jul 2021 14:22:41 GMT | ||
* Dependencies: [@types/hapi__hapi](https://npmjs.com/package/@types/hapi__hapi) | ||
@@ -14,0 +57,0 @@ * Global values: none |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
5273
0
60