mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-19 02:04:45 +00:00
14 lines
446 B
TypeScript
14 lines
446 B
TypeScript
export type ToolPlanContractErrorCode = "duplicate-tool-name" | "missing-executor";
|
|
|
|
export class ToolPlanContractError extends Error {
|
|
readonly code: ToolPlanContractErrorCode;
|
|
readonly toolName: string;
|
|
|
|
constructor(params: { code: ToolPlanContractErrorCode; toolName: string; message: string }) {
|
|
super(params.message);
|
|
this.name = "ToolPlanContractError";
|
|
this.code = params.code;
|
|
this.toolName = params.toolName;
|
|
}
|
|
}
|