@doist/todoist-mcp 10.0.0 → 10.1.0
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 +327 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +70 -59
- package/dist/main-http.js +2 -2
- package/dist/main.js +1 -1
- package/dist/mcp-apps/index.html +1 -1
- package/dist/{mcp-server-B08TNWfi.js → mcp-server-EQIi2OR6.js} +2088 -1753
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/{require-valid-todoist-token-CoZu2QoC.js → require-valid-todoist-token-C6anvAtX.js} +7 -7
- package/dist/tool-helpers.d.ts +23 -2
- package/dist/tool-helpers.d.ts.map +1 -1
- package/dist/tools/add-goals.d.ts +70 -0
- package/dist/tools/add-goals.d.ts.map +1 -0
- package/dist/tools/complete-goals.d.ts +48 -0
- package/dist/tools/complete-goals.d.ts.map +1 -0
- package/dist/tools/delete-object.d.ts +4 -2
- package/dist/tools/delete-object.d.ts.map +1 -1
- package/dist/tools/fetch-object.d.ts +39 -1
- package/dist/tools/fetch-object.d.ts.map +1 -1
- package/dist/tools/find-goals.d.ts +77 -0
- package/dist/tools/find-goals.d.ts.map +1 -0
- package/dist/tools/link-goal-tasks.d.ts +50 -0
- package/dist/tools/link-goal-tasks.d.ts.map +1 -0
- package/dist/tools/update-goals.d.ts +91 -0
- package/dist/tools/update-goals.d.ts.map +1 -0
- package/dist/utils/constants.d.ts +4 -0
- package/dist/utils/constants.d.ts.map +1 -1
- package/dist/utils/output-schemas.d.ts +19 -1
- package/dist/utils/output-schemas.d.ts.map +1 -1
- package/dist/utils/test-helpers.d.ts +6 -1
- package/dist/utils/test-helpers.d.ts.map +1 -1
- package/dist/utils/tool-names.d.ts +5 -0
- package/dist/utils/tool-names.d.ts.map +1 -1
- package/package.json +2 -2
- package/scripts/run-tool.ts +10 -0
package/dist/mcp-server.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mcp-server.d.ts","sourceRoot":"","sources":["../src/mcp-server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAA;AAGnE,OAAO,EACH,aAAa,EACb,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,QAAQ,EAEhB,MAAM,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"mcp-server.d.ts","sourceRoot":"","sources":["../src/mcp-server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAA;AAGnE,OAAO,EACH,aAAa,EACb,KAAK,OAAO,EACZ,KAAK,WAAW,EAChB,KAAK,QAAQ,EAEhB,MAAM,kBAAkB,CAAA;AA4JzB;;;;;;GAMG;AACH,iBAAS,YAAY,CAAC,EAClB,aAAa,EACb,OAAO,EACP,QAAa,GAChB,EAAE;IACC,aAAa,EAAE,MAAM,CAAA;IACrB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,QAAQ,CAAC,EAAE,QAAQ,CAAA;CACtB,aA+HA;AAED,OAAO,EAAE,aAAa,EAAE,KAAK,OAAO,EAAE,KAAK,WAAW,EAAE,KAAK,QAAQ,EAAE,YAAY,EAAE,CAAA"}
|
package/dist/{require-valid-todoist-token-CoZu2QoC.js → require-valid-todoist-token-C6anvAtX.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { U as A, V as v, W as T } from "./mcp-server-EQIi2OR6.js";
|
|
2
2
|
const y = /* @__PURE__ */ new Set([401, 403]);
|
|
3
3
|
function C(e) {
|
|
4
4
|
const t = T(e);
|
|
@@ -33,19 +33,19 @@ function S(e) {
|
|
|
33
33
|
return t.valid;
|
|
34
34
|
t && n.delete(e);
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function U(e, t, r) {
|
|
37
37
|
n.size >= h && E(), n.size >= h && n.clear(), n.set(e, { valid: t, expiresAt: Date.now() + r });
|
|
38
38
|
}
|
|
39
|
-
function
|
|
39
|
+
function g(e) {
|
|
40
40
|
return e ? `Bearer resource_metadata="${e}"` : "Bearer";
|
|
41
41
|
}
|
|
42
42
|
function d(e, t) {
|
|
43
|
-
e.status(401).set("WWW-Authenticate",
|
|
43
|
+
e.status(401).set("WWW-Authenticate", g(t)).json({
|
|
44
44
|
error: "invalid_token",
|
|
45
45
|
error_description: "Todoist API token is invalid or expired"
|
|
46
46
|
});
|
|
47
47
|
}
|
|
48
|
-
function
|
|
48
|
+
function D(e) {
|
|
49
49
|
const t = e.type === "static" ? p : w, r = e.cacheTtlMs ?? t, { resourceMetadataUrl: i } = e;
|
|
50
50
|
return async (a, s, c) => {
|
|
51
51
|
const u = e.type === "static" ? e.apiKey : e.getApiKey(a);
|
|
@@ -60,13 +60,13 @@ function M(e) {
|
|
|
60
60
|
}
|
|
61
61
|
try {
|
|
62
62
|
const o = await _(u, e.baseUrl);
|
|
63
|
-
|
|
63
|
+
U(f, o, r), o ? c() : d(s, i);
|
|
64
64
|
} catch (o) {
|
|
65
65
|
console.warn("[Token validation] Transient error, proceeding:", o), c();
|
|
66
66
|
}
|
|
67
67
|
};
|
|
68
68
|
}
|
|
69
69
|
export {
|
|
70
|
-
|
|
70
|
+
D as r,
|
|
71
71
|
_ as v
|
|
72
72
|
};
|
package/dist/tool-helpers.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isPersonalProject, isWorkspaceProject, ActivityEvent, ColorKey, Comment, CurrentUser, Label, MoveTaskArgs, PersonalProject, Reminder, Section, Task, TodoistApi, WorkspaceProject } from '@doist/todoist-sdk';
|
|
1
|
+
import { isPersonalProject, isWorkspaceProject, ActivityEvent, ColorKey, Comment, CurrentUser, Goal, Label, MoveTaskArgs, PersonalProject, Reminder, Section, Task, TodoistApi, WorkspaceProject } from '@doist/todoist-sdk';
|
|
2
2
|
export { appendToQuery, buildResponsibleUserQueryFilter, filterTasksByResponsibleUser, RESPONSIBLE_USER_FILTERING, type ResponsibleUserFiltering, resolveResponsibleUser, } from './filter-helpers.js';
|
|
3
3
|
export type Project = PersonalProject | WorkspaceProject;
|
|
4
4
|
export { isPersonalProject, isWorkspaceProject };
|
|
@@ -168,6 +168,27 @@ declare function mapComment(comment: Comment): {
|
|
|
168
168
|
imageHeight: number | undefined;
|
|
169
169
|
} | undefined;
|
|
170
170
|
};
|
|
171
|
+
/**
|
|
172
|
+
* Map a single Todoist goal to a more structured format, for LLM consumption.
|
|
173
|
+
* Drops `null` values so the output matches `GoalSchema` (which makes nullable
|
|
174
|
+
* fields optional — `registerTool` strips nulls from `structuredContent`).
|
|
175
|
+
*/
|
|
176
|
+
declare function mapGoal(goal: Goal): {
|
|
177
|
+
id: string;
|
|
178
|
+
name: string;
|
|
179
|
+
ownerType: "USER" | "WORKSPACE";
|
|
180
|
+
ownerId: string;
|
|
181
|
+
description: string | undefined;
|
|
182
|
+
deadline: string | undefined;
|
|
183
|
+
responsibleUid: string | undefined;
|
|
184
|
+
isCompleted: boolean;
|
|
185
|
+
progress: {
|
|
186
|
+
[x: string]: unknown;
|
|
187
|
+
totalTaskCount: number;
|
|
188
|
+
completedTaskCount: number;
|
|
189
|
+
percentage: number;
|
|
190
|
+
} | undefined;
|
|
191
|
+
};
|
|
171
192
|
/**
|
|
172
193
|
* Map a single Todoist activity event to a more structured format, for LLM consumption.
|
|
173
194
|
* @param event - The activity event to map.
|
|
@@ -261,5 +282,5 @@ declare function countRemindersByType(reminders: {
|
|
|
261
282
|
locationCount: number;
|
|
262
283
|
};
|
|
263
284
|
export type { MappedTask };
|
|
264
|
-
export { countRemindersByType, getTasksByFilter, mapActivityEvent, mapComment, mapProject, mapReminder, mapTask, };
|
|
285
|
+
export { countRemindersByType, getTasksByFilter, mapActivityEvent, mapComment, mapGoal, mapProject, mapReminder, mapTask, };
|
|
265
286
|
//# sourceMappingURL=tool-helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tool-helpers.d.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E,MAAM,GAAG,SAAS,CAAA;CAC7B;;;;;;;;;;;;;;;;;;;;GAkBA;AAqBD;;;;;GAKG;AACH,iBAAS,WAAW,CAAC,QAAQ,EAAE,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+BtC;AAED;;GAEG;AACH,iBAAS,oBAAoB,CAAC,SAAS,EAAE;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,EAAE;;;EAM1D;AAED,YAAY,EAAE,UAAU,EAAE,CAAA;AAC1B,OAAO,EACH,oBAAoB,EACpB,gBAAgB,EAChB,gBAAgB,EAChB,UAAU,EACV,OAAO,EACP,UAAU,EACV,WAAW,EACX,OAAO,GACV,CAAA"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
declare const MAX_GOALS_PER_OPERATION = 25;
|
|
3
|
+
declare const addGoals: {
|
|
4
|
+
name: "add-goals";
|
|
5
|
+
description: string;
|
|
6
|
+
parameters: {
|
|
7
|
+
goals: z.ZodArray<z.ZodObject<{
|
|
8
|
+
name: z.ZodString;
|
|
9
|
+
workspaceId: z.ZodOptional<z.ZodString>;
|
|
10
|
+
description: z.ZodOptional<z.ZodString>;
|
|
11
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
12
|
+
responsibleUid: z.ZodOptional<z.ZodString>;
|
|
13
|
+
}, z.core.$strip>>;
|
|
14
|
+
};
|
|
15
|
+
outputSchema: {
|
|
16
|
+
goals: z.ZodArray<z.ZodObject<{
|
|
17
|
+
id: z.ZodString;
|
|
18
|
+
name: z.ZodString;
|
|
19
|
+
ownerType: z.ZodString;
|
|
20
|
+
ownerId: z.ZodString;
|
|
21
|
+
description: z.ZodOptional<z.ZodString>;
|
|
22
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
23
|
+
responsibleUid: z.ZodOptional<z.ZodString>;
|
|
24
|
+
isCompleted: z.ZodBoolean;
|
|
25
|
+
progress: z.ZodOptional<z.ZodObject<{
|
|
26
|
+
totalTaskCount: z.ZodNumber;
|
|
27
|
+
completedTaskCount: z.ZodNumber;
|
|
28
|
+
percentage: z.ZodNumber;
|
|
29
|
+
}, z.core.$strip>>;
|
|
30
|
+
}, z.core.$strip>>;
|
|
31
|
+
totalCount: z.ZodNumber;
|
|
32
|
+
};
|
|
33
|
+
annotations: {
|
|
34
|
+
readOnlyHint: false;
|
|
35
|
+
destructiveHint: false;
|
|
36
|
+
idempotentHint: false;
|
|
37
|
+
};
|
|
38
|
+
execute({ goals }: {
|
|
39
|
+
goals: {
|
|
40
|
+
name: string;
|
|
41
|
+
workspaceId?: string | undefined;
|
|
42
|
+
description?: string | undefined;
|
|
43
|
+
deadline?: string | undefined;
|
|
44
|
+
responsibleUid?: string | undefined;
|
|
45
|
+
}[];
|
|
46
|
+
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
47
|
+
textContent: string;
|
|
48
|
+
structuredContent: {
|
|
49
|
+
goals: {
|
|
50
|
+
id: string;
|
|
51
|
+
name: string;
|
|
52
|
+
ownerType: "USER" | "WORKSPACE";
|
|
53
|
+
ownerId: string;
|
|
54
|
+
description: string | undefined;
|
|
55
|
+
deadline: string | undefined;
|
|
56
|
+
responsibleUid: string | undefined;
|
|
57
|
+
isCompleted: boolean;
|
|
58
|
+
progress: {
|
|
59
|
+
[x: string]: unknown;
|
|
60
|
+
totalTaskCount: number;
|
|
61
|
+
completedTaskCount: number;
|
|
62
|
+
percentage: number;
|
|
63
|
+
} | undefined;
|
|
64
|
+
}[];
|
|
65
|
+
totalCount: number;
|
|
66
|
+
};
|
|
67
|
+
}>;
|
|
68
|
+
};
|
|
69
|
+
export { addGoals, MAX_GOALS_PER_OPERATION };
|
|
70
|
+
//# sourceMappingURL=add-goals.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-goals.d.ts","sourceRoot":"","sources":["../../src/tools/add-goals.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAMvB,QAAA,MAAM,uBAAuB,KAAK,CAAA;AA4BlC,QAAA,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwBiD,CAAA;AAE/D,OAAO,EAAE,QAAQ,EAAE,uBAAuB,EAAE,CAAA"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
declare const MAX_GOALS_PER_OPERATION = 25;
|
|
3
|
+
declare const completeGoals: {
|
|
4
|
+
name: "complete-goals";
|
|
5
|
+
description: string;
|
|
6
|
+
parameters: {
|
|
7
|
+
ids: z.ZodArray<z.ZodString>;
|
|
8
|
+
action: z.ZodEnum<{
|
|
9
|
+
complete: "complete";
|
|
10
|
+
uncomplete: "uncomplete";
|
|
11
|
+
}>;
|
|
12
|
+
};
|
|
13
|
+
outputSchema: {
|
|
14
|
+
processed: z.ZodArray<z.ZodString>;
|
|
15
|
+
failures: z.ZodArray<z.ZodObject<{
|
|
16
|
+
item: z.ZodString;
|
|
17
|
+
error: z.ZodString;
|
|
18
|
+
code: z.ZodOptional<z.ZodString>;
|
|
19
|
+
}, z.core.$strip>>;
|
|
20
|
+
totalRequested: z.ZodNumber;
|
|
21
|
+
successCount: z.ZodNumber;
|
|
22
|
+
failureCount: z.ZodNumber;
|
|
23
|
+
};
|
|
24
|
+
annotations: {
|
|
25
|
+
readOnlyHint: false;
|
|
26
|
+
destructiveHint: true;
|
|
27
|
+
idempotentHint: false;
|
|
28
|
+
};
|
|
29
|
+
execute(args: {
|
|
30
|
+
ids: string[];
|
|
31
|
+
action: "complete" | "uncomplete";
|
|
32
|
+
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
33
|
+
textContent: string;
|
|
34
|
+
structuredContent: {
|
|
35
|
+
processed: string[];
|
|
36
|
+
failures: {
|
|
37
|
+
item: string;
|
|
38
|
+
error: string;
|
|
39
|
+
code?: string;
|
|
40
|
+
}[];
|
|
41
|
+
totalRequested: number;
|
|
42
|
+
successCount: number;
|
|
43
|
+
failureCount: number;
|
|
44
|
+
};
|
|
45
|
+
}>;
|
|
46
|
+
};
|
|
47
|
+
export { completeGoals, MAX_GOALS_PER_OPERATION };
|
|
48
|
+
//# sourceMappingURL=complete-goals.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"complete-goals.d.ts","sourceRoot":"","sources":["../../src/tools/complete-goals.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAMvB,QAAA,MAAM,uBAAuB,KAAK,CAAA;AAuBlC,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sBAmBmB,MAAM;uBAAS,MAAM;uBAAS,MAAM;;;;;;;CAgCX,CAAA;AAE/D,OAAO,EAAE,aAAa,EAAE,uBAAuB,EAAE,CAAA"}
|
|
@@ -11,6 +11,7 @@ declare const deleteObject: {
|
|
|
11
11
|
task: "task";
|
|
12
12
|
project: "project";
|
|
13
13
|
section: "section";
|
|
14
|
+
goal: "goal";
|
|
14
15
|
location_reminder: "location_reminder";
|
|
15
16
|
}>;
|
|
16
17
|
id: z.ZodString;
|
|
@@ -25,6 +26,7 @@ declare const deleteObject: {
|
|
|
25
26
|
task: "task";
|
|
26
27
|
project: "project";
|
|
27
28
|
section: "section";
|
|
29
|
+
goal: "goal";
|
|
28
30
|
location_reminder: "location_reminder";
|
|
29
31
|
}>;
|
|
30
32
|
id: z.ZodString;
|
|
@@ -37,13 +39,13 @@ declare const deleteObject: {
|
|
|
37
39
|
idempotentHint: true;
|
|
38
40
|
};
|
|
39
41
|
execute(args: {
|
|
40
|
-
type: "label" | "filter" | "comment" | "reminder" | "task" | "project" | "section" | "location_reminder";
|
|
42
|
+
type: "label" | "filter" | "comment" | "reminder" | "task" | "project" | "section" | "goal" | "location_reminder";
|
|
41
43
|
id: string;
|
|
42
44
|
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
43
45
|
textContent: string;
|
|
44
46
|
structuredContent: {
|
|
45
47
|
deletedEntity: {
|
|
46
|
-
type: "label" | "filter" | "comment" | "reminder" | "task" | "project" | "section" | "location_reminder";
|
|
48
|
+
type: "label" | "filter" | "comment" | "reminder" | "task" | "project" | "section" | "goal" | "location_reminder";
|
|
47
49
|
id: string;
|
|
48
50
|
};
|
|
49
51
|
success: true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"delete-object.d.ts","sourceRoot":"","sources":["../../src/tools/delete-object.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;
|
|
1
|
+
{"version":3,"file":"delete-object.d.ts","sourceRoot":"","sources":["../../src/tools/delete-object.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AA+BvB,QAAA,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuD6C,CAAA;AAE/D,OAAO,EAAE,YAAY,EAAE,CAAA"}
|
|
@@ -8,6 +8,7 @@ declare const fetchObject: {
|
|
|
8
8
|
task: "task";
|
|
9
9
|
project: "project";
|
|
10
10
|
section: "section";
|
|
11
|
+
goal: "goal";
|
|
11
12
|
}>;
|
|
12
13
|
id: z.ZodString;
|
|
13
14
|
};
|
|
@@ -17,6 +18,7 @@ declare const fetchObject: {
|
|
|
17
18
|
task: "task";
|
|
18
19
|
project: "project";
|
|
19
20
|
section: "section";
|
|
21
|
+
goal: "goal";
|
|
20
22
|
}>;
|
|
21
23
|
id: z.ZodString;
|
|
22
24
|
object: z.ZodUnion<readonly [z.ZodObject<{
|
|
@@ -102,6 +104,20 @@ declare const fetchObject: {
|
|
|
102
104
|
}, z.core.$strip>, z.ZodObject<{
|
|
103
105
|
id: z.ZodString;
|
|
104
106
|
name: z.ZodString;
|
|
107
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
108
|
+
id: z.ZodString;
|
|
109
|
+
name: z.ZodString;
|
|
110
|
+
ownerType: z.ZodString;
|
|
111
|
+
ownerId: z.ZodString;
|
|
112
|
+
description: z.ZodOptional<z.ZodString>;
|
|
113
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
114
|
+
responsibleUid: z.ZodOptional<z.ZodString>;
|
|
115
|
+
isCompleted: z.ZodBoolean;
|
|
116
|
+
progress: z.ZodOptional<z.ZodObject<{
|
|
117
|
+
totalTaskCount: z.ZodNumber;
|
|
118
|
+
completedTaskCount: z.ZodNumber;
|
|
119
|
+
percentage: z.ZodNumber;
|
|
120
|
+
}, z.core.$strip>>;
|
|
105
121
|
}, z.core.$strip>]>;
|
|
106
122
|
};
|
|
107
123
|
annotations: {
|
|
@@ -110,7 +126,7 @@ declare const fetchObject: {
|
|
|
110
126
|
idempotentHint: true;
|
|
111
127
|
};
|
|
112
128
|
execute(args: {
|
|
113
|
-
type: "comment" | "task" | "project" | "section";
|
|
129
|
+
type: "comment" | "task" | "project" | "section" | "goal";
|
|
114
130
|
id: string;
|
|
115
131
|
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
116
132
|
textContent: string;
|
|
@@ -193,6 +209,28 @@ declare const fetchObject: {
|
|
|
193
209
|
name: string;
|
|
194
210
|
};
|
|
195
211
|
};
|
|
212
|
+
} | {
|
|
213
|
+
textContent: string;
|
|
214
|
+
structuredContent: {
|
|
215
|
+
type: "goal";
|
|
216
|
+
id: string;
|
|
217
|
+
object: {
|
|
218
|
+
id: string;
|
|
219
|
+
name: string;
|
|
220
|
+
ownerType: "USER" | "WORKSPACE";
|
|
221
|
+
ownerId: string;
|
|
222
|
+
description: string | undefined;
|
|
223
|
+
deadline: string | undefined;
|
|
224
|
+
responsibleUid: string | undefined;
|
|
225
|
+
isCompleted: boolean;
|
|
226
|
+
progress: {
|
|
227
|
+
[x: string]: unknown;
|
|
228
|
+
totalTaskCount: number;
|
|
229
|
+
completedTaskCount: number;
|
|
230
|
+
percentage: number;
|
|
231
|
+
} | undefined;
|
|
232
|
+
};
|
|
233
|
+
};
|
|
196
234
|
}>;
|
|
197
235
|
};
|
|
198
236
|
export { fetchObject };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fetch-object.d.ts","sourceRoot":"","sources":["../../src/tools/fetch-object.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;
|
|
1
|
+
{"version":3,"file":"fetch-object.d.ts","sourceRoot":"","sources":["../../src/tools/fetch-object.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AA2BvB,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2F8C,CAAA;AAE/D,OAAO,EAAE,WAAW,EAAE,CAAA"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
declare const findGoals: {
|
|
3
|
+
name: "find-goals";
|
|
4
|
+
description: string;
|
|
5
|
+
parameters: {
|
|
6
|
+
searchText: z.ZodOptional<z.ZodString>;
|
|
7
|
+
ownerType: z.ZodOptional<z.ZodEnum<{
|
|
8
|
+
USER: "USER";
|
|
9
|
+
WORKSPACE: "WORKSPACE";
|
|
10
|
+
}>>;
|
|
11
|
+
limit: z.ZodDefault<z.ZodNumber>;
|
|
12
|
+
cursor: z.ZodOptional<z.ZodString>;
|
|
13
|
+
};
|
|
14
|
+
outputSchema: {
|
|
15
|
+
goals: z.ZodArray<z.ZodObject<{
|
|
16
|
+
id: z.ZodString;
|
|
17
|
+
name: z.ZodString;
|
|
18
|
+
ownerType: z.ZodString;
|
|
19
|
+
ownerId: z.ZodString;
|
|
20
|
+
description: z.ZodOptional<z.ZodString>;
|
|
21
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
22
|
+
responsibleUid: z.ZodOptional<z.ZodString>;
|
|
23
|
+
isCompleted: z.ZodBoolean;
|
|
24
|
+
progress: z.ZodOptional<z.ZodObject<{
|
|
25
|
+
totalTaskCount: z.ZodNumber;
|
|
26
|
+
completedTaskCount: z.ZodNumber;
|
|
27
|
+
percentage: z.ZodNumber;
|
|
28
|
+
}, z.core.$strip>>;
|
|
29
|
+
}, z.core.$strip>>;
|
|
30
|
+
nextCursor: z.ZodOptional<z.ZodString>;
|
|
31
|
+
hasMore: z.ZodBoolean;
|
|
32
|
+
totalCount: z.ZodNumber;
|
|
33
|
+
appliedFilters: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
34
|
+
};
|
|
35
|
+
annotations: {
|
|
36
|
+
readOnlyHint: true;
|
|
37
|
+
destructiveHint: false;
|
|
38
|
+
idempotentHint: true;
|
|
39
|
+
};
|
|
40
|
+
execute(args: {
|
|
41
|
+
limit: number;
|
|
42
|
+
searchText?: string | undefined;
|
|
43
|
+
ownerType?: "USER" | "WORKSPACE" | undefined;
|
|
44
|
+
cursor?: string | undefined;
|
|
45
|
+
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
46
|
+
textContent: string;
|
|
47
|
+
structuredContent: {
|
|
48
|
+
goals: {
|
|
49
|
+
id: string;
|
|
50
|
+
name: string;
|
|
51
|
+
ownerType: "USER" | "WORKSPACE";
|
|
52
|
+
ownerId: string;
|
|
53
|
+
description: string | undefined;
|
|
54
|
+
deadline: string | undefined;
|
|
55
|
+
responsibleUid: string | undefined;
|
|
56
|
+
isCompleted: boolean;
|
|
57
|
+
progress: {
|
|
58
|
+
[x: string]: unknown;
|
|
59
|
+
totalTaskCount: number;
|
|
60
|
+
completedTaskCount: number;
|
|
61
|
+
percentage: number;
|
|
62
|
+
} | undefined;
|
|
63
|
+
}[];
|
|
64
|
+
nextCursor: string | undefined;
|
|
65
|
+
hasMore: boolean;
|
|
66
|
+
totalCount: number;
|
|
67
|
+
appliedFilters: {
|
|
68
|
+
limit: number;
|
|
69
|
+
searchText?: string | undefined;
|
|
70
|
+
ownerType?: "USER" | "WORKSPACE" | undefined;
|
|
71
|
+
cursor?: string | undefined;
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
}>;
|
|
75
|
+
};
|
|
76
|
+
export { findGoals };
|
|
77
|
+
//# sourceMappingURL=find-goals.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"find-goals.d.ts","sourceRoot":"","sources":["../../src/tools/find-goals.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AA4CvB,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgEgD,CAAA;AAE/D,OAAO,EAAE,SAAS,EAAE,CAAA"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
declare const MAX_TASKS_PER_OPERATION = 50;
|
|
3
|
+
declare const linkGoalTasks: {
|
|
4
|
+
name: "link-goal-tasks";
|
|
5
|
+
description: string;
|
|
6
|
+
parameters: {
|
|
7
|
+
goalId: z.ZodString;
|
|
8
|
+
taskIds: z.ZodArray<z.ZodString>;
|
|
9
|
+
action: z.ZodEnum<{
|
|
10
|
+
link: "link";
|
|
11
|
+
unlink: "unlink";
|
|
12
|
+
}>;
|
|
13
|
+
};
|
|
14
|
+
outputSchema: {
|
|
15
|
+
processed: z.ZodArray<z.ZodString>;
|
|
16
|
+
failures: z.ZodArray<z.ZodObject<{
|
|
17
|
+
item: z.ZodString;
|
|
18
|
+
error: z.ZodString;
|
|
19
|
+
code: z.ZodOptional<z.ZodString>;
|
|
20
|
+
}, z.core.$strip>>;
|
|
21
|
+
totalRequested: z.ZodNumber;
|
|
22
|
+
successCount: z.ZodNumber;
|
|
23
|
+
failureCount: z.ZodNumber;
|
|
24
|
+
};
|
|
25
|
+
annotations: {
|
|
26
|
+
readOnlyHint: false;
|
|
27
|
+
destructiveHint: false;
|
|
28
|
+
idempotentHint: true;
|
|
29
|
+
};
|
|
30
|
+
execute(args: {
|
|
31
|
+
goalId: string;
|
|
32
|
+
taskIds: string[];
|
|
33
|
+
action: "link" | "unlink";
|
|
34
|
+
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
35
|
+
textContent: string;
|
|
36
|
+
structuredContent: {
|
|
37
|
+
processed: string[];
|
|
38
|
+
failures: {
|
|
39
|
+
item: string;
|
|
40
|
+
error: string;
|
|
41
|
+
code?: string;
|
|
42
|
+
}[];
|
|
43
|
+
totalRequested: number;
|
|
44
|
+
successCount: number;
|
|
45
|
+
failureCount: number;
|
|
46
|
+
};
|
|
47
|
+
}>;
|
|
48
|
+
};
|
|
49
|
+
export { linkGoalTasks, MAX_TASKS_PER_OPERATION };
|
|
50
|
+
//# sourceMappingURL=link-goal-tasks.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"link-goal-tasks.d.ts","sourceRoot":"","sources":["../../src/tools/link-goal-tasks.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAMvB,QAAA,MAAM,uBAAuB,KAAK,CAAA;AAoBlC,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;sBAmBmB,MAAM;uBAAS,MAAM;uBAAS,MAAM;;;;;;;CAiCX,CAAA;AAE/D,OAAO,EAAE,aAAa,EAAE,uBAAuB,EAAE,CAAA"}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
declare const MAX_GOALS_PER_OPERATION = 25;
|
|
3
|
+
declare const updateGoals: {
|
|
4
|
+
name: "update-goals";
|
|
5
|
+
description: string;
|
|
6
|
+
parameters: {
|
|
7
|
+
goals: z.ZodArray<z.ZodObject<{
|
|
8
|
+
id: z.ZodString;
|
|
9
|
+
name: z.ZodOptional<z.ZodString>;
|
|
10
|
+
description: z.ZodOptional<z.ZodPipe<z.ZodTransform<{} | undefined, unknown>, z.ZodString>>;
|
|
11
|
+
deadline: z.ZodOptional<z.ZodPipe<z.ZodTransform<{} | undefined, unknown>, z.ZodString>>;
|
|
12
|
+
responsibleUid: z.ZodOptional<z.ZodPipe<z.ZodTransform<{} | undefined, unknown>, z.ZodString>>;
|
|
13
|
+
}, z.core.$strip>>;
|
|
14
|
+
};
|
|
15
|
+
outputSchema: {
|
|
16
|
+
goals: z.ZodArray<z.ZodObject<{
|
|
17
|
+
id: z.ZodString;
|
|
18
|
+
name: z.ZodString;
|
|
19
|
+
ownerType: z.ZodString;
|
|
20
|
+
ownerId: z.ZodString;
|
|
21
|
+
description: z.ZodOptional<z.ZodString>;
|
|
22
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
23
|
+
responsibleUid: z.ZodOptional<z.ZodString>;
|
|
24
|
+
isCompleted: z.ZodBoolean;
|
|
25
|
+
progress: z.ZodOptional<z.ZodObject<{
|
|
26
|
+
totalTaskCount: z.ZodNumber;
|
|
27
|
+
completedTaskCount: z.ZodNumber;
|
|
28
|
+
percentage: z.ZodNumber;
|
|
29
|
+
}, z.core.$strip>>;
|
|
30
|
+
}, z.core.$strip>>;
|
|
31
|
+
totalCount: z.ZodNumber;
|
|
32
|
+
updatedGoalIds: z.ZodArray<z.ZodString>;
|
|
33
|
+
appliedOperations: z.ZodObject<{
|
|
34
|
+
updateCount: z.ZodNumber;
|
|
35
|
+
skippedCount: z.ZodNumber;
|
|
36
|
+
skipped: z.ZodArray<z.ZodObject<{
|
|
37
|
+
id: z.ZodString;
|
|
38
|
+
reason: z.ZodEnum<{
|
|
39
|
+
"no-fields": "no-fields";
|
|
40
|
+
"no-valid-values": "no-valid-values";
|
|
41
|
+
}>;
|
|
42
|
+
}, z.core.$strip>>;
|
|
43
|
+
}, z.core.$strip>;
|
|
44
|
+
};
|
|
45
|
+
annotations: {
|
|
46
|
+
readOnlyHint: false;
|
|
47
|
+
destructiveHint: false;
|
|
48
|
+
idempotentHint: true;
|
|
49
|
+
};
|
|
50
|
+
execute({ goals }: {
|
|
51
|
+
goals: {
|
|
52
|
+
id: string;
|
|
53
|
+
name?: string | undefined;
|
|
54
|
+
description?: string | undefined;
|
|
55
|
+
deadline?: string | undefined;
|
|
56
|
+
responsibleUid?: string | undefined;
|
|
57
|
+
}[];
|
|
58
|
+
}, client: import('@doist/todoist-sdk').TodoistApi): Promise<{
|
|
59
|
+
textContent: string;
|
|
60
|
+
structuredContent: {
|
|
61
|
+
goals: {
|
|
62
|
+
id: string;
|
|
63
|
+
name: string;
|
|
64
|
+
ownerType: "USER" | "WORKSPACE";
|
|
65
|
+
ownerId: string;
|
|
66
|
+
description: string | undefined;
|
|
67
|
+
deadline: string | undefined;
|
|
68
|
+
responsibleUid: string | undefined;
|
|
69
|
+
isCompleted: boolean;
|
|
70
|
+
progress: {
|
|
71
|
+
[x: string]: unknown;
|
|
72
|
+
totalTaskCount: number;
|
|
73
|
+
completedTaskCount: number;
|
|
74
|
+
percentage: number;
|
|
75
|
+
} | undefined;
|
|
76
|
+
}[];
|
|
77
|
+
totalCount: number;
|
|
78
|
+
updatedGoalIds: string[];
|
|
79
|
+
appliedOperations: {
|
|
80
|
+
updateCount: number;
|
|
81
|
+
skippedCount: number;
|
|
82
|
+
skipped: {
|
|
83
|
+
id: string;
|
|
84
|
+
reason: "no-fields" | "no-valid-values";
|
|
85
|
+
}[];
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
}>;
|
|
89
|
+
};
|
|
90
|
+
export { MAX_GOALS_PER_OPERATION, updateGoals };
|
|
91
|
+
//# sourceMappingURL=update-goals.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update-goals.d.ts","sourceRoot":"","sources":["../../src/tools/update-goals.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAQvB,QAAA,MAAM,uBAAuB,KAAK,CAAA;AAwElC,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgE8C,CAAA;AAgB/D,OAAO,EAAE,uBAAuB,EAAE,WAAW,EAAE,CAAA"}
|
|
@@ -37,6 +37,10 @@ export declare const ApiLimits: {
|
|
|
37
37
|
readonly REMINDERS_DEFAULT: 50;
|
|
38
38
|
/** Maximum limit for reminder search operations */
|
|
39
39
|
readonly REMINDERS_MAX: 200;
|
|
40
|
+
/** Default limit for goal listings */
|
|
41
|
+
readonly GOALS_DEFAULT: 50;
|
|
42
|
+
/** Maximum limit for goal search and list operations */
|
|
43
|
+
readonly GOALS_MAX: 200;
|
|
40
44
|
};
|
|
41
45
|
export declare const DisplayLimits: {
|
|
42
46
|
/** Maximum number of failures to show in detailed error messages */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/utils/constants.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,eAAO,MAAM,SAAS;IAClB,sCAAsC;;IAEtC,wDAAwD;;IAExD,wCAAwC;;IAExC,wCAAwC;;IAExC,yCAAyC;;IAEzC,yCAAyC;;IAEzC,yCAAyC;;IAEzC,qDAAqD;;IAErD,yCAAyC;;IAEzC,2DAA2D;;IAE3D,8CAA8C;;IAE9C,gEAAgE;;IAEhE,uCAAuC;;IAEvC,uCAAuC;;IAEvC,0CAA0C;;IAE1C,mDAAmD;;
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/utils/constants.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,eAAO,MAAM,SAAS;IAClB,sCAAsC;;IAEtC,wDAAwD;;IAExD,wCAAwC;;IAExC,wCAAwC;;IAExC,yCAAyC;;IAEzC,yCAAyC;;IAEzC,yCAAyC;;IAEzC,qDAAqD;;IAErD,yCAAyC;;IAEzC,2DAA2D;;IAE3D,8CAA8C;;IAE9C,gEAAgE;;IAEhE,uCAAuC;;IAEvC,uCAAuC;;IAEvC,0CAA0C;;IAE1C,mDAAmD;;IAEnD,sCAAsC;;IAEtC,wDAAwD;;CAElD,CAAA;AAGV,eAAO,MAAM,aAAa;IACtB,oEAAoE;;IAEpE,gDAAgD;;CAE1C,CAAA;AAGV,eAAO,MAAM,cAAc;IACvB,oDAAoD;;IAEpD,mCAAmC;;CAE7B,CAAA"}
|
|
@@ -187,6 +187,24 @@ declare const ReminderSchema: z.ZodObject<{
|
|
|
187
187
|
radius: z.ZodOptional<z.ZodNumber>;
|
|
188
188
|
isUrgent: z.ZodOptional<z.ZodBoolean>;
|
|
189
189
|
}, z.core.$strip>;
|
|
190
|
+
/**
|
|
191
|
+
* Schema for a goal object returned by tools
|
|
192
|
+
*/
|
|
193
|
+
declare const GoalSchema: z.ZodObject<{
|
|
194
|
+
id: z.ZodString;
|
|
195
|
+
name: z.ZodString;
|
|
196
|
+
ownerType: z.ZodString;
|
|
197
|
+
ownerId: z.ZodString;
|
|
198
|
+
description: z.ZodOptional<z.ZodString>;
|
|
199
|
+
deadline: z.ZodOptional<z.ZodString>;
|
|
200
|
+
responsibleUid: z.ZodOptional<z.ZodString>;
|
|
201
|
+
isCompleted: z.ZodBoolean;
|
|
202
|
+
progress: z.ZodOptional<z.ZodObject<{
|
|
203
|
+
totalTaskCount: z.ZodNumber;
|
|
204
|
+
completedTaskCount: z.ZodNumber;
|
|
205
|
+
percentage: z.ZodNumber;
|
|
206
|
+
}, z.core.$strip>>;
|
|
207
|
+
}, z.core.$strip>;
|
|
190
208
|
/**
|
|
191
209
|
* Schema for batch operation failure
|
|
192
210
|
*/
|
|
@@ -195,5 +213,5 @@ declare const FailureSchema: z.ZodObject<{
|
|
|
195
213
|
error: z.ZodString;
|
|
196
214
|
code: z.ZodOptional<z.ZodString>;
|
|
197
215
|
}, z.core.$strip>;
|
|
198
|
-
export { ActivityEventSchema, CollaboratorSchema, CommentSchema, FailureSchema, LabelSchema, ProjectSchema, ReminderSchema, SectionSchema, type SectionSummary, TaskSchema, toSectionSummary, };
|
|
216
|
+
export { ActivityEventSchema, CollaboratorSchema, CommentSchema, FailureSchema, GoalSchema, LabelSchema, ProjectSchema, ReminderSchema, SectionSchema, type SectionSummary, TaskSchema, toSectionSummary, };
|
|
199
217
|
//# sourceMappingURL=output-schemas.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"output-schemas.d.ts","sourceRoot":"","sources":["../../src/utils/output-schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqC,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAA;AACpF,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB;;GAEG;AACH,QAAA,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;iBA+Bd,CAAA;AAEF;;GAEG;AACH,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAoBjB,CAAA;AAEF;;GAEG;AACH,QAAA,MAAM,aAAa;;;iBAGjB,CAAA;AAEF,KAAK,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAA;AAEnD;;;GAGG;AACH,iBAAS,gBAAgB,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,OAAO,GAAG,cAAc,CAE/D;AA0BD;;GAEG;AACH,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;iBAQjB,CAAA;AAEF;;GAEG;AACH,QAAA,MAAM,mBAAmB;;;;;;;;;;iBAYvB,CAAA;AAEF;;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,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAMf,CAAA;AAaF;;GAEG;AACH,QAAA,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;iBAuBlB,CAAA;AAEF;;GAEG;AACH,QAAA,MAAM,UAAU;;;;;;;;;;;;;;iBAiBd,CAAA;AAEF;;GAEG;AACH,QAAA,MAAM,aAAa;;;;iBAIjB,CAAA;AAEF,OAAO,EACH,mBAAmB,EACnB,kBAAkB,EAClB,aAAa,EACb,aAAa,EACb,UAAU,EACV,WAAW,EACX,aAAa,EACb,cAAc,EACd,aAAa,EACb,KAAK,cAAc,EACnB,UAAU,EACV,gBAAgB,GACnB,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CurrentUser, Label, PersonalProject, Section, Task, WorkspaceProject } from '@doist/todoist-sdk';
|
|
1
|
+
import { CurrentUser, Goal, Label, PersonalProject, Section, Task, WorkspaceProject } from '@doist/todoist-sdk';
|
|
2
2
|
import { MappedTask } from '../tool-helpers';
|
|
3
3
|
import { Priority } from './priorities';
|
|
4
4
|
type TaskWithUserFacingPriority = Omit<Task, 'priority'> & {
|
|
@@ -29,6 +29,11 @@ export declare function createMockWorkspaceProject(overrides?: Partial<Workspace
|
|
|
29
29
|
* Pass only the properties you want to override for your specific test.
|
|
30
30
|
*/
|
|
31
31
|
export declare function createMockLabel(overrides?: Partial<Label>): Label;
|
|
32
|
+
/**
|
|
33
|
+
* Creates a mock Goal with all required properties and sensible defaults.
|
|
34
|
+
* Pass only the properties you want to override for your specific test.
|
|
35
|
+
*/
|
|
36
|
+
export declare function createMockGoal(overrides?: Partial<Goal>): Goal;
|
|
32
37
|
/**
|
|
33
38
|
* Creates a mock API response object with results and nextCursor.
|
|
34
39
|
*/
|