/** Minimal shape of the forgecli `package.json`. */ interface ForgePkg { version?: string; forge?: { bundledVersion?: string; }; } /** * Reads the forgecli `package.json` from the given package root. * Returns `{ version: "unknown" }` on any error. */ export declare function readForgeCliPkg(pkgRoot: string): ForgePkg; /** * Returns the forgecli package version string. * Returns `"unknown"` when `package.json` cannot be read or is missing a * `version` field. */ export declare function readForgeCliVersion(pkgRoot: string): string; /** * Returns the bundled Forge plugin version. * * Primary source: `/dist/forge-payload/.claude-plugin/plugin.json`, * regenerated by `scripts/build-payload.cjs` on every build — single source * of truth that never drifts. * * Fallback: `package.json`'s `forge.bundledVersion` mirror (hand-maintained, * used in dev / pre-build environments). * * Returns `"unknown"` when neither source is available. */ export declare function readBundledPluginVersion(pkgRoot: string): string; /** * Asynchronously resolves the pi-coding-agent version by finding its * `package.json` via `import.meta.resolve`. * * Returns `"unknown"` when the resolution fails (e.g. the package is not * installed or bundled). */ export declare function readPiVersionAsync(): Promise; /** * Synchronously reads both the CLI and bundled plugin versions. * * Intended for use at module load time where async is not available (e.g. * `const PKG_VERSIONS = readPkgVersionsSync(pkgRoot)` at the top level of * an ES module). * * Returns empty strings `""` on any read failure so that callers can use * falsy checks (`if (cliVersion && bundledForgeVersion)`) to gate * version-dependent features. Distinct from `readForgeCliVersion` which * returns `"unknown"` — the two have different sentinel conventions. */ export declare function readPkgVersionsSync(pkgRoot: string): { cliVersion: string; bundledForgeVersion: string; }; export {};