import type { CanonicalEntry } from '../../../engine/index.js';
export type CodexExtensionAction = 'create' | 'update' | 'remove' | 'skip';
export type CodexExtensionTarget = 'role' | 'config';
export interface CodexExtensionOperation {
    action: CodexExtensionAction;
    target: CodexExtensionTarget;
    path: string;
    reason: string;
    roleName?: string;
}
export interface CodexExtensionWriteOperation extends CodexExtensionOperation {
    content?: string;
}
export interface CodexExtensionPlan {
    operations: CodexExtensionWriteOperation[];
    managedRoles: string[];
    aggregateConfigHash: string;
}
export interface CodexExtensionApplyResult {
    applied: number;
    failed: number;
    skipped: number;
}
interface CodexMaterializationTargetOptions {
    userConfigDir?: string;
    projectPath?: string | null;
    env?: NodeJS.ProcessEnv;
}
export declare function computeCodexProjectExtensionPlan(scopeRoot: string, canonicalEntries: CanonicalEntry[], allowedCanonicalPaths?: string[], options?: CodexMaterializationTargetOptions): Promise<CodexExtensionPlan>;
export declare function applyCodexProjectExtensionPlan(scopeRoot: string, plan: CodexExtensionPlan): Promise<CodexExtensionApplyResult>;
export declare function hasCodexExtensionChanges(plan: CodexExtensionPlan): boolean;
export declare function summarizeCodexExtension(plan: CodexExtensionPlan): {
    plannedOperations: number;
    skipped: number;
};
export declare function toCodexExtensionOperations(plan: CodexExtensionPlan): CodexExtensionOperation[];
export {};
//# sourceMappingURL=sync-extension.d.ts.map