import { z } from 'zod'; /** Where the generator writes the artifact, relative to the package root. */ export declare const READONLY_WHITELIST_RELATIVE_PATH = "contracts/readonly-argv-whitelist.json"; declare const PlaceholderSpecSchema: z.ZodObject<{ type: z.ZodEnum<{ enum: "enum"; path: "path"; token: "token"; slug: "slug"; integer: "integer"; }>; pattern: z.ZodOptional; values: z.ZodOptional>; min: z.ZodOptional; max: z.ZodOptional; default: z.ZodOptional; binding: z.ZodObject<{ kind: z.ZodEnum<{ option: "option"; positional: "positional"; }>; token: z.ZodString; required: z.ZodBoolean; }, z.core.$strip>; constraintSource: z.ZodEnum<{ introspected: "introspected"; handwritten: "handwritten"; }>; }, z.core.$strip>; declare const EntrySchema: z.ZodObject<{ id: z.ZodString; tool: z.ZodString; commandPath: z.ZodArray; argv: z.ZodArray; value: z.ZodString; }, z.core.$strip>, z.ZodObject<{ kind: z.ZodLiteral<"param">; name: z.ZodString; }, z.core.$strip>]>>; params: z.ZodRecord; pattern: z.ZodOptional; values: z.ZodOptional>; min: z.ZodOptional; max: z.ZodOptional; default: z.ZodOptional; binding: z.ZodObject<{ kind: z.ZodEnum<{ option: "option"; positional: "positional"; }>; token: z.ZodString; required: z.ZodBoolean; }, z.core.$strip>; constraintSource: z.ZodEnum<{ introspected: "introspected"; handwritten: "handwritten"; }>; }, z.core.$strip>>; introspection: z.ZodObject<{ optionTokens: z.ZodArray; positionalCount: z.ZodNumber; }, z.core.$strip>; }, z.core.$strip>; declare const WhitelistSchema: z.ZodObject<{ schemaVersion: z.ZodLiteral<1>; source: z.ZodString; readOnlyDefinition: z.ZodString; entries: z.ZodArray; argv: z.ZodArray; value: z.ZodString; }, z.core.$strip>, z.ZodObject<{ kind: z.ZodLiteral<"param">; name: z.ZodString; }, z.core.$strip>]>>; params: z.ZodRecord; pattern: z.ZodOptional; values: z.ZodOptional>; min: z.ZodOptional; max: z.ZodOptional; default: z.ZodOptional; binding: z.ZodObject<{ kind: z.ZodEnum<{ option: "option"; positional: "positional"; }>; token: z.ZodString; required: z.ZodBoolean; }, z.core.$strip>; constraintSource: z.ZodEnum<{ introspected: "introspected"; handwritten: "handwritten"; }>; }, z.core.$strip>>; introspection: z.ZodObject<{ optionTokens: z.ZodArray; positionalCount: z.ZodNumber; }, z.core.$strip>; }, z.core.$strip>>; }, z.core.$strip>; export type PlaceholderSpec = z.infer; export type ReadOnlyWhitelistEntry = z.infer; export type ReadOnlyWhitelist = z.infer; /** Absolute path of the generated artifact for a package root. */ export declare function resolveReadOnlyWhitelistPath(root?: string): string; /** Parse + validate the artifact text. Throws a zod error when the shape drifts. */ export declare function parseReadOnlyWhitelist(text: string): ReadOnlyWhitelist; /** Read + validate the artifact. The only supported way to obtain it. */ export declare function loadReadOnlyWhitelist(root?: string): ReadOnlyWhitelist; /** The param names an entry expects, in argv order. */ export declare function paramNamesOf(entry: ReadOnlyWhitelistEntry): string[]; /** * The tool names the surface declares, in first-appearance order. * * This is the pre-tool interceptor's view of "what may be called", and it is * computed HERE rather than in the MCP module on purpose: the interceptor must * keep working when `src/services/mcp/` is deleted (spec ยง1), so it cannot reach * into it for the answer. Grouping the entries by their `tool` field is the whole * computation, and both readers do it from the same DATA. */ export declare function toolIdsOf(whitelist: ReadOnlyWhitelist): string[]; /** * Match a CONCRETE argv against the entries. A param slot consumes exactly one * token, so `--apply` in a param slot still MATCHES here - refusing it is the * validator's job (`argv-guard.ts`), not the matcher's. Keeping the two separate * is what stops a rejected value from silently re-routing to another entry. */ export declare function matchReadOnlyEntry(whitelist: ReadOnlyWhitelist, argv: readonly string[]): ReadOnlyWhitelistEntry | undefined; export {};