UNPKG

better-auth

Version:

The most comprehensive authentication framework for TypeScript.

38 lines (37 loc) 1.1 kB
import * as _better_auth_core0 from "@better-auth/core"; import * as better_call0 from "better-call"; //#region src/plugins/bearer/index.d.ts interface BearerOptions { /** * If true, only signed tokens * will be converted to session * cookies * * @default false */ requireSignature?: boolean | undefined; } /** * Converts bearer token to session cookie */ declare const bearer: (options?: BearerOptions | undefined) => { id: "bearer"; hooks: { before: { matcher(context: _better_auth_core0.HookEndpointContext): boolean; handler: (inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<{ context: { headers: Headers; }; } | undefined>; }[]; after: { matcher(context: _better_auth_core0.HookEndpointContext): true; handler: (inputContext: better_call0.MiddlewareInputContext<better_call0.MiddlewareOptions>) => Promise<void>; }[]; }; options: BearerOptions | undefined; }; //#endregion export { BearerOptions, bearer }; //# sourceMappingURL=index.d.mts.map