feat: improve schedule cleanup and handover

This commit is contained in:
Winnie
2026-08-20 19:12:44 +08:00
parent ae3b6d63e2
commit bc62034241
7 changed files with 306 additions and 63 deletions
+6 -1
View File
@@ -1314,10 +1314,14 @@ export async function deleteScheduleNode(
scheduleId: string,
nodeId: string,
workflowVersion: number,
options: { delete_execution_history?: boolean } = {},
): Promise<Schedule> {
return apiRequest<Schedule>(
`/api/v1/schedules/${scheduleId}/nodes/${nodeId}`,
{ method: "DELETE", body: JSON.stringify({ workflow_version: workflowVersion }) },
{
method: "DELETE",
body: JSON.stringify({ workflow_version: workflowVersion, ...options }),
},
workspaceId,
);
}
@@ -1586,6 +1590,7 @@ export type WorkspaceBoundApi = {
scheduleId: string,
nodeId: string,
workflowVersion: number,
options?: { delete_execution_history?: boolean },
) => Promise<Schedule>;
createScheduleEdge: (
scheduleId: string,