1 | import type { HttpContext } from '@adonisjs/core/http';
|
2 | import type { GuardFactory } from './types.js';
|
3 | import { Authenticator } from './authenticator.js';
|
4 | import { AuthenticatorClient } from './authenticator_client.js';
|
5 |
|
6 |
|
7 |
|
8 |
|
9 | export declare class AuthManager<KnownGuards extends Record<string, GuardFactory>> {
|
10 | config: {
|
11 | default: keyof KnownGuards;
|
12 | guards: KnownGuards;
|
13 | };
|
14 | |
15 |
|
16 |
|
17 | get defaultGuard(): keyof KnownGuards;
|
18 | constructor(config: {
|
19 | default: keyof KnownGuards;
|
20 | guards: KnownGuards;
|
21 | });
|
22 | /**
|
23 | * Create an authenticator for a given HTTP request. The authenticator
|
24 | * is used to authenticated in incoming HTTP request
|
25 | */
|
26 | createAuthenticator(ctx: HttpContext): Authenticator<KnownGuards>;
|
27 | /**
|
28 | * Creates an instance of the authenticator client. The client is
|
29 | * used to setup authentication state during testing.
|
30 | */
|
31 | createAuthenticatorClient(): AuthenticatorClient<KnownGuards>;
|
32 | }
|