import type { Application } from '@atlex/core'; import { ServiceProvider } from '@atlex/core'; import type { QueryBuilder } from '@atlex/orm'; import type { Redis } from 'ioredis'; import { type UserProviderFactory } from './AuthManager.js'; import type { Policy } from './authorization/Policy.js'; import type { AuthConfig } from './config/AuthConfig.js'; import type { AuthEventDispatcher } from './events/AuthEventDispatcher.js'; export interface AuthProviderBindings { /** * Fully merged auth configuration (defaults applied by caller if needed). */ readonly config: AuthConfig; /** * Builds user providers for configured `auth.providers` keys. */ readonly userProviderFactory: UserProviderFactory; /** * Optional Knex-backed query factory (sessions, password resets, refresh tokens). */ readonly query?: () => QueryBuilder; /** * Optional Redis client for JWT blacklist / session / refresh stores. */ readonly redis?: Redis; /** * Optional auth event sink (defaults to no-op). */ readonly dispatch?: AuthEventDispatcher; /** * Optional policy resolver (defaults to `new PolicyClass()`). */ readonly resolvePolicy?: (PolicyClass: new (...args: never[]) => T) => T; } /** * Registers `auth`, `gate`, `hash`, `session`, and related middleware aliases. */ export declare class AuthServiceProvider extends ServiceProvider { private readonly bindings; /** * @param bindings - Runtime factories and merged configuration. */ constructor(bindings: AuthProviderBindings); /** * @inheritdoc */ register(app: Application): void; /** * @inheritdoc */ boot(app: Application): void; } //# sourceMappingURL=AuthServiceProvider.d.ts.map