/** * `gsk mesh upgrade` + the throttled autorun currency check. * * Talks to the backend endpoint added in gen-spark#32059: * GET {base}/api/gsk-mesh/checkupdate/{target}?channel=stable|beta * ¤t_version= * → 200 {version, sha256, url, notes} (update available) * → 204 (already latest / none promoted) * * Contract notes: * - The CLI `--prerelease` flag maps to channel `beta` (the backend only * knows stable/beta; `prerelease` would collapse to stable). * - Auth is optional: the autorun check frequently fires unauthenticated, so * we send the bearer token when present but never require it. */ export interface UpgradeOptions { force?: boolean; prerelease?: boolean; /** * Explicit `--base-url` from the command line (already resolved by the * caller). Highest priority — see resolveBaseUrl in checkupdate.ts. */ baseUrlOverride?: string; } export type UpgradeResult = 'updated' | 'up-to-date' | 'error'; /** * Body of the explicit `gsk mesh upgrade` command. * `--force` ignores the installed version (always pulls the channel's latest). */ export declare function runUpgrade(opts: UpgradeOptions): Promise; /** * Best-effort autorun currency check, invoked (non-awaited) from the `gsk mesh` * passthrough path. Only fires when: * - autorun isn't disabled (GSK_NO_AUTO_UPDATE / config auto_update:false), * - a binary is already installed (never triggers a first download here), * - the shared 4h throttle has elapsed. * A newer release is downloaded in the background so it applies next run; the * current invocation is never blocked or failed by this. */ export declare function maybeAutoUpgradeMesh(baseUrlOverride?: string): Promise; //# sourceMappingURL=upgrade.d.ts.map