/** * Typed error helpers for consistent CLI command error responses. */ export declare class DagError extends Error { readonly code: string; constructor(code: string, message: string); } export declare function projectNotFound(slug: string): DagError; export declare function projectAlreadyExists(slug: string): DagError; export declare function invalidDocType(doc: string): DagError; export declare function cycleDetected(fromSlug: string, toSlug: string): DagError; export declare function taskDependencyCycleDetected(cyclePath: string[]): DagError; export declare function taskDependencyNotFound(depId: string): DagError; export declare function dependencyNotFound(ids: string[]): DagError; export declare function invalidPlanStatus(status: string): DagError; export declare function invalidTaskStatus(status: string): DagError; export declare function invalidTaskPriority(priority: string): DagError; export declare function invalidSessionStatus(status: string): DagError; export declare function invalidSessionRuntimeType(runtimeType: string): DagError; export declare function invalidSessionId(runtimeSessionId: string): DagError; export declare function invalidSessionLink(detail: string): DagError; export declare function invalidKnowledgeKind(kind: string): DagError; export declare function invalidKeyword(keyword: string): DagError; export declare function invalidFileRef(detail: string): DagError; export declare function normalizedIdCollision(kind: "plan" | "knowledge entry" | "task" | "session", requestedId: string, normalizedId: string): DagError; export declare function itemNotFound(kind: "plan" | "knowledge entry" | "task" | "session", id: string): DagError; export declare function planNotFound(slug: string, planId: string): DagError; export declare function invalidFileFormat(filePath: string, details: string): DagError; export declare function indexRebuildFailed(kind: "plans" | "knowledge", reason: string): DagError; export declare function noProjectMatch(workspacePath: string): DagError; export declare function ambiguousProjectMatch(workspacePath: string, slugs: string[]): DagError; export declare function invalidWorkspacePath(path: string): DagError; export declare function noWorkspacePaths(slug: string): DagError; /** * Format a DagError into a CLI command error response. * Delegates to the canonical `toolError` helper so all error responses * share the same `[CODE] message` shape. */ export declare function formatError(err: DagError): { content: [{ type: "text"; text: string; }]; isError: true; }; //# sourceMappingURL=errors.d.ts.map