export type WranglerResult = { code: number; stdout: string; stderr: string; }; /** * A failure that happened before Wrangler could issue a Cloudflare mutation. * Callers may safely undo local work while preserving the recovery guidance. */ export declare class CloudflareNoChangeError extends Error { constructor(message: string); } /** * Cloudflare can return detailed CLI output that is useful for debugging, but * it can also include account and request details. Keep that output out of the * CLI's user-facing errors and turn known failure classes into safe next steps. */ export declare function cloudflareFailure(action: string, result: WranglerResult, opts?: { mayHaveChanged?: boolean; }): Error; /** * Runs a wrangler command. `interactive` inherits stdio (browser OAuth login); * otherwise output is captured. `stdin` feeds `wrangler secret put`. */ export declare function runWrangler(args: string[], opts?: { cwd?: string; interactive?: boolean; stdin?: string; env?: Record; }): Promise; export declare function wranglerLoggedIn(): Promise; export declare function cloudflareApiTokenConfigured(): boolean; export declare function wranglerLogin(opts?: { openBrowser?: boolean; }): Promise; /** Creates (or finds) a KV namespace and returns its id. */ export declare function ensureKvNamespace(title: string): Promise; /** * Reports whether a worker already holds a secret with this name. Cloudflare * only ever returns secret names, so an existing value can be kept in place * without OwnMail ever reading or storing it. */ export declare function workerHasSecret(workerName: string, name: string): Promise; export declare function putSecret(workerName: string, name: string, value: string): Promise; /** Deploys the materialized config and returns the workers.dev URL. */ export declare function deploy(configPath: string): Promise; //# sourceMappingURL=wrangler.d.ts.map