/** * `tools data-purge ` — per-tool project-data removal (ADR-0042 / ADR-0146). * * Rows, never tables: one tool's sessions (payload rows cascade via the * schema FK), baseline entries + meta, and tool_state rows (ordinary + reserved * host-plane identities), all through repository APIs — no SQL in command code * (`restrict-raw-db-access`). Project-scoped by nature (the datastore is * per-project). Works for ANY tool id including bundled ones (purging fit * history is legitimate). * * Surface note: the spec drafted `tools data purge` (a nested group); the * host group machinery is deliberately one level deep (a nested action-less * `data` shell would need its own parity-allowlist entry, completion * inventory, and mounter recursion for one leaf), so this ships flattened as * `data-purge`. Recorded as a plan deviation. */ import { type Logger, type ToolRegistry } from '@opensip-cli/core'; import { type DataStore } from '@opensip-cli/datastore'; import type { ToolsDataPurgeResult } from '@opensip-cli/contracts'; /** * Reject empty/whitespace or reserved-prefix purge input before opening any * repository. Bind every SQLite value; never interpret an id as a path, glob, * or SQL fragment. * * @throws {ConfigurationError} with a stable code when input is invalid */ export declare function assertToolDataPurgeId(toolId: string): string; /** * Every id form one user-supplied tool id may appear under across the stores, * derived from the live tool registry when available. For a registered Tool the * validated `toolOwnedKeys` set is used so canonical/layout/stable/replay/config * identities are cleaned consistently. Unknown non-empty ids remain a one-key * ordinary cleanup pair (plus matching reserved host-plane identity). */ export declare function deriveToolDataPurgeIdForms(toolId: string, registry: ToolRegistry | undefined): readonly string[]; /** Purge one tool's rows from the project datastore; reports counts. */ export declare function toolsDataPurge(toolId: string, datastore: DataStore, idForms?: readonly string[], logger?: Logger): ToolsDataPurgeResult; //# sourceMappingURL=data-purge.d.ts.map