/**
 * UpgradeCommand — the open-core sales funnel for `openlife upgrade`.
 *
 * The Community CLI is a SHOWCASE + ORCHESTRATOR, never a runtime host for paid
 * code. This command:
 *   1. shows the paid tiers (read from TIER_FEATURES — single source of truth),
 *   2. opens openlife.online so the user can purchase,
 *   3. takes the license key + GitHub Packages token the checkout hands back,
 *   4. writes the token to ~/.npmrc (HOME, never the repo) and runs
 *      `npm i -g @openlife-business/cli`,
 *   5. delegates activation to the freshly installed `openlife-business` binary
 *      (so the paid runtime — with its own store/key — sees the license).
 *
 * No private code is imported here. Everything is process orchestration, exactly
 * like the existing `update --global` command. I/O, the browser launcher and the
 * command runner are injectable so the flow is unit-testable without touching
 * the network, the real ~/.npmrc, or a global npm install.
 */
import { WizardIO } from './install/WizardIO';
export interface UpgradeResult {
    ok: boolean;
    action: string;
    message: string;
    tier?: string;
    registry?: string;
    npmrcPath?: string;
    steps?: string[];
}
export interface UpgradeOptions {
    key?: string;
    token?: string;
    registry?: string;
    open?: boolean;
    install?: boolean;
    yes?: boolean;
}
/** Minimal external-process seam so tests can avoid real npm / binaries. */
export interface CommandRunner {
    run(file: string, args: string[]): {
        ok: boolean;
        error?: string;
    };
}
export interface UpgradeDeps {
    io?: WizardIO;
    browser?: (url: string) => boolean;
    runner?: CommandRunner;
    npmrcPath?: string;
}
export declare class UpgradeCommand {
    private deps;
    constructor(deps?: UpgradeDeps);
    private io;
    private browser;
    private runner;
    /** Human-readable tier table (used by interactive flow + `upgrade pricing`). */
    renderPricing(): string;
    /** Structured pricing for `--json`. */
    pricing(): UpgradeResult;
    /** Validate key + collect token; either via flags or interactive prompts. */
    private collectCredentials;
    /** Write ~/.npmrc, install the business package, delegate activation. */
    private provision;
    /** Full interactive funnel: pricing → browser → credentials → install → activate. */
    run(opts?: UpgradeOptions): Promise<UpgradeResult>;
    /** Non-browser path: caller already purchased; just install + activate. */
    install(opts?: UpgradeOptions): Promise<UpgradeResult>;
    /** Undo: remove the ~/.npmrc entry, uninstall the package, deactivate. */
    rollback(): UpgradeResult;
}
