import { AuthCacheCoherenceManager } from '../auth/cache/index.js'; import { AthenaAuthUpstreamEnv } from './base-url.js'; export { adaptAthenaAuthBindings, type BetterAuthCompatibilityAdapter, createBetterAuthCompatibilityAdapter } from '../../compat/better-auth/client-adapter.js'; export { AthenaAuthRequestError } from '../../compat/better-auth/result-adapter.js'; /** Options for a browser-facing Athena auth client that may proxy through the host app. */ export interface AthenaAuthClientOptions { appendAuthPath?: boolean; baseUrl?: string; credentials?: RequestCredentials; /** * Gateway/API key. Optional at construction so SSG/prerender can succeed * without build-time secrets; API calls still need a real key at runtime. */ key?: string; upstreamUrl?: string | AthenaAuthUpstreamEnv; } /** Options for a server-side Athena auth client that talks directly to the upstream service. */ export interface AthenaServerAuthClientOptions { credentials?: RequestCredentials; /** * Gateway/API key. Optional at construction so SSG/prerender can succeed * without build-time secrets; API calls still need a real key at runtime. */ key?: string; upstreamUrl?: string | AthenaAuthUpstreamEnv; } export interface ResolveAuthUiClientOptions { coherence?: AuthCacheCoherenceManager; } /** * Publish standalone bindings as `{ auth: bindings }` so `useAthena().auth` works. */ export declare function toAthenaRootClientForContext(input: T): T | { auth: T; }; /** * Resolve Auth UI's auth client input from either: * - a full Athena root client (`createClient` → uses `.auth` + UI shims) * - standalone auth bindings / Better Auth-compatible clients (passed through) * * When `coherence` is provided, every registered mutation is wrapped once * so resource caches stay consistent after writes. */ export declare function resolveAuthUiClient(input: T, options?: ResolveAuthUiClientOptions): T; /** * Creates a browser-facing Athena auth client with package compatibility aliases and throw-mode support. * * @deprecated Prefer `createClient({ url, key, auth })` from `@xylex-group/athena` * and pass the root client to ``. * Do not construct a second auth client beside the Athena root. * Remains for standalone Auth UI-only apps and legacy scaffolds. */ export declare function createAthenaAuthClient({ baseUrl, upstreamUrl, credentials, appendAuthPath, key }: AthenaAuthClientOptions): import('@xylex-group/athena/catalog-C-oCm_e0').K; /** * Creates a server-side Athena auth client that talks directly to the configured upstream origin. * * @deprecated Prefer `createClient({ auth: { url: upstream } })` (or * `createAthenaServerClient` / request-scoped views) instead of a second * Auth UI-owned constructor. */ export declare function createAthenaServerAuthClient({ upstreamUrl, credentials, key }: AthenaServerAuthClientOptions): import('@xylex-group/athena/catalog-C-oCm_e0').K;