import { AuthRequestContext, AuthSession, StartAuthJSConfig } from './types.js'; export type GetSessionResult = Promise; /** * Get the current session from a request * * Usage in server functions or loaders: * ```ts * import { getSession } from 'start-authjs' * * const session = await getSession(request, authConfig) * if (!session) { * throw redirect('/login') * } * ``` */ export declare function getSession(request: Request, config: StartAuthJSConfig): GetSessionResult; /** * Get the session and update response cookies * Use this when you need to refresh session cookies * * Usage in loaders or server functions: * ```ts * import { auth } from 'start-authjs' * * const session = await auth(context, authConfig) * ``` */ export declare function auth(context: AuthRequestContext, config: StartAuthJSConfig): Promise;