/** * 登录与认证工具 */ import type { Page } from 'playwright'; import type { LoginResult } from '../types'; export declare const COOKIE_PATH: string; export declare const CONFIG_PATH: string; /** * 检查登录状态 * * @param page Playwright Page 实例 * @returns 登录状态信息 */ export declare function checkLoginStatus(page: Page): Promise<{ isLoggedIn: boolean; message: string; }>; /** * 登录小红书 * * @param page Playwright Page 实例 * @param timeout 等待用户完成登录的超时时间(毫秒),默认60秒 * @returns 登录结果 */ export declare function loginToXiaohongshu(page: Page, timeout?: number): Promise; /** * 加载已保存的 cookies */ export declare function loadSavedCookies(): any[]; /** * 检查是否有已保存的 cookies */ export declare function hasSavedCookies(): boolean; /** * 保存用户 ID */ export declare function saveUserId(userId: string): void; /** * 加载用户 ID */ export declare function loadUserId(): string | null; /** * 获取用户 ID(带默认值) */ export declare function getUserId(): string; //# sourceMappingURL=auth.d.ts.map