/** * auth-flow — Two-phase OAuth flow for agent-compatible auth. * * Phase 1 (start): Spawn background auth server, return URL. * Phase 2 (poll): Check pending file for completion status. * * The agent calls `npx go-easy auth add ` which: * - On first call: starts the server, returns { status: "started", authUrl } * - On subsequent calls: polls and returns current status * - When user completes auth: returns { status: "complete" } */ export type AuthFlowStatus = { status: 'started'; authUrl: string; expiresIn: number; } | { status: 'waiting'; authUrl: string; expiresIn: number; } | { status: 'complete'; email: string; scopes: string[]; } | { status: 'partial'; email: string; grantedScopes: string[]; missingScopes: string[]; message: string; } | { status: 'denied'; message: string; } | { status: 'expired'; message: string; } | { status: 'error'; message: string; }; /** * Start or poll the auth flow for an email. * * This is the single entry point — handles all states: * - No session → start new auth server * - Pending session with live server → return waiting/started * - Completed session → return result, clean up * - Stale session (dead pid) → clean up, restart */ export declare function authAdd(email: string): Promise; //# sourceMappingURL=auth-flow.d.ts.map