/** * go-easy error hierarchy. * * All errors extend GoEasyError so callers can catch broadly * or narrowly as needed. */ export declare class GoEasyError extends Error { readonly code: string; readonly cause?: unknown | undefined; constructor(message: string, code: string, cause?: unknown | undefined); /** Structured JSON for gateway output */ toJSON(): { cause?: string | undefined; error: string; message: string; }; } /** * Auth error codes: * AUTH_NO_ACCOUNT — Account not configured at all * AUTH_MISSING_SCOPE — Account exists but token lacks required scope * AUTH_TOKEN_REVOKED — Refresh token was revoked (Google returned invalid_grant) * AUTH_REFRESH_FAILED — Transient network error refreshing token * AUTH_STORE_CORRUPT — accounts.json unreadable * AUTH_NO_CREDENTIALS — credentials.json missing * AUTH_ERROR — Generic (legacy fallback) */ export type AuthErrorCode = 'AUTH_NO_ACCOUNT' | 'AUTH_MISSING_SCOPE' | 'AUTH_TOKEN_REVOKED' | 'AUTH_REFRESH_FAILED' | 'AUTH_STORE_CORRUPT' | 'AUTH_NO_CREDENTIALS' | 'AUTH_ERROR'; /** OAuth2 token expired, missing, or invalid */ export declare class AuthError extends GoEasyError { /** Exact CLI command that fixes this error */ readonly fix?: string; constructor(message: string, cause?: unknown); constructor(code: AuthErrorCode, opts: { message: string; fix?: string; cause?: unknown; }); toJSON(): { fix?: string | undefined; cause?: string | undefined; error: string; message: string; }; } /** Google API returned 404 */ export declare class NotFoundError extends GoEasyError { constructor(resource: string, id: string, cause?: unknown); } /** Google API quota exceeded (429) */ export declare class QuotaError extends GoEasyError { constructor(service: string, cause?: unknown); } /** Operation blocked by safety checks */ export declare class SafetyError extends GoEasyError { constructor(operation: string); } //# sourceMappingURL=errors.d.ts.map