import type { OAuthSession } from '@atproto/oauth-client-browser'; import type { NuxtApp } from 'nuxt/app'; import type { AtprotoContext } from '../../../types/index.js'; export interface AtprotoSessionLifecycleHooks { hook: (name: string, callback: () => void) => void; callHook: (name: string, did: string) => void | Promise; } export type AtprotoSessionTransition = 'oauth-return' | 'cold-restore' | 'account-switch' | 'sign-out'; export interface ApplyAtprotoSessionOptions { /** When true, lifecycle hooks run after `app:mounted` (plugin init). */ deferHooks?: boolean; /** Pass during plugin setup before `provide` returns. */ atproto?: AtprotoContext; } /** * Updates `$atproto` session state, agent cache, status, and lifecycle hooks. */ export declare function applyAtprotoSession(nuxtApp: NuxtApp, session: OAuthSession | undefined, transition: AtprotoSessionTransition, options?: ApplyAtprotoSessionOptions): void; /** * @deprecated Use `applyAtprotoSession` with `deferHooks: true` instead. */ export declare function scheduleAtprotoSessionHooks(hooks: AtprotoSessionLifecycleHooks, sessionSub: string, state: string | null | undefined): void;