@deepbounty/sdk 1.0.8 → 1.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +3 -2
- package/dist/types/tasks.d.ts +1 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ModuleSetting, TaskContent, Tool } from "./types";
|
|
1
|
+
import { ModuleSetting, TaskContent, TaskResult, Tool } from "./types";
|
|
2
2
|
export interface Logger {
|
|
3
3
|
info: (...args: any[]) => void;
|
|
4
4
|
warn: (...args: any[]) => void;
|
|
@@ -47,9 +47,10 @@ export interface ServerAPI {
|
|
|
47
47
|
* Register a scheduled task that runs at a specific interval
|
|
48
48
|
* @param taskContent The task content including commands and required tools
|
|
49
49
|
* @param interval Interval in seconds between task executions
|
|
50
|
+
* @param onComplete Optional callback executed when the task completes
|
|
50
51
|
* @returns The ID of the registered scheduled task
|
|
51
52
|
*/
|
|
52
|
-
registerScheduledTask(taskContent: TaskContent, interval: number): number;
|
|
53
|
+
registerScheduledTask(taskContent: TaskContent, interval: number, onComplete?: (result: TaskResult) => void): number;
|
|
53
54
|
/**
|
|
54
55
|
* Unregister a scheduled task
|
|
55
56
|
* @param taskId The ID of the scheduled task to unregister
|
package/dist/types/tasks.d.ts
CHANGED