@doist/todoist-ai 4.13.4 → 4.14.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 +109 -42
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -0
- package/dist/mcp-server.d.ts.map +1 -1
- package/dist/mcp-server.js +8 -1
- package/dist/tool-helpers.d.ts +18 -2
- package/dist/tool-helpers.d.ts.map +1 -1
- package/dist/tool-helpers.js +19 -1
- package/dist/tools/__tests__/find-activity.test.d.ts +2 -0
- package/dist/tools/__tests__/find-activity.test.d.ts.map +1 -0
- package/dist/tools/__tests__/find-activity.test.js +229 -0
- package/dist/tools/add-comments.d.ts +3 -3
- package/dist/tools/add-projects.d.ts +3 -3
- package/dist/tools/add-sections.d.ts +3 -3
- package/dist/tools/add-tasks.d.ts +6 -6
- package/dist/tools/delete-object.d.ts +2 -2
- package/dist/tools/find-activity.d.ts +69 -0
- package/dist/tools/find-activity.d.ts.map +1 -0
- package/dist/tools/find-activity.js +221 -0
- package/dist/tools/find-comments.d.ts +2 -2
- package/dist/tools/find-completed-tasks.d.ts +4 -4
- package/dist/tools/find-completed-tasks.d.ts.map +1 -1
- package/dist/tools/find-completed-tasks.js +2 -2
- package/dist/tools/find-tasks-by-date.d.ts +2 -2
- package/dist/tools/find-tasks.d.ts +4 -4
- package/dist/tools/update-projects.d.ts +3 -3
- package/dist/tools/update-tasks.d.ts +9 -9
- package/dist/utils/constants.d.ts +4 -0
- package/dist/utils/constants.d.ts.map +1 -1
- package/dist/utils/constants.js +4 -0
- package/dist/utils/tool-names.d.ts +1 -0
- package/dist/utils/tool-names.d.ts.map +1 -1
- package/dist/utils/tool-names.js +2 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ import { addTasks } from './tools/add-tasks.js';
|
|
|
6
6
|
import { completeTasks } from './tools/complete-tasks.js';
|
|
7
7
|
import { deleteObject } from './tools/delete-object.js';
|
|
8
8
|
import { fetch } from './tools/fetch.js';
|
|
9
|
+
import { findActivity } from './tools/find-activity.js';
|
|
9
10
|
import { findComments } from './tools/find-comments.js';
|
|
10
11
|
import { findCompletedTasks } from './tools/find-completed-tasks.js';
|
|
11
12
|
import { findProjectCollaborators } from './tools/find-project-collaborators.js';
|
|
@@ -39,24 +40,24 @@ declare const tools: {
|
|
|
39
40
|
responsibleUser: import("zod").ZodOptional<import("zod").ZodString>;
|
|
40
41
|
}, "strip", import("zod").ZodTypeAny, {
|
|
41
42
|
content: string;
|
|
42
|
-
description?: string | undefined;
|
|
43
|
-
parentId?: string | undefined;
|
|
44
43
|
projectId?: string | undefined;
|
|
45
44
|
sectionId?: string | undefined;
|
|
45
|
+
parentId?: string | undefined;
|
|
46
46
|
labels?: string[] | undefined;
|
|
47
47
|
duration?: string | undefined;
|
|
48
48
|
priority?: "p1" | "p2" | "p3" | "p4" | undefined;
|
|
49
|
+
description?: string | undefined;
|
|
49
50
|
dueString?: string | undefined;
|
|
50
51
|
responsibleUser?: string | undefined;
|
|
51
52
|
}, {
|
|
52
53
|
content: string;
|
|
53
|
-
description?: string | undefined;
|
|
54
|
-
parentId?: string | undefined;
|
|
55
54
|
projectId?: string | undefined;
|
|
56
55
|
sectionId?: string | undefined;
|
|
56
|
+
parentId?: string | undefined;
|
|
57
57
|
labels?: string[] | undefined;
|
|
58
58
|
duration?: string | undefined;
|
|
59
59
|
priority?: "p1" | "p2" | "p3" | "p4" | undefined;
|
|
60
|
+
description?: string | undefined;
|
|
60
61
|
dueString?: string | undefined;
|
|
61
62
|
responsibleUser?: string | undefined;
|
|
62
63
|
}>, "many">;
|
|
@@ -64,13 +65,13 @@ declare const tools: {
|
|
|
64
65
|
execute({ tasks }: {
|
|
65
66
|
tasks: {
|
|
66
67
|
content: string;
|
|
67
|
-
description?: string | undefined;
|
|
68
|
-
parentId?: string | undefined;
|
|
69
68
|
projectId?: string | undefined;
|
|
70
69
|
sectionId?: string | undefined;
|
|
70
|
+
parentId?: string | undefined;
|
|
71
71
|
labels?: string[] | undefined;
|
|
72
72
|
duration?: string | undefined;
|
|
73
73
|
priority?: "p1" | "p2" | "p3" | "p4" | undefined;
|
|
74
|
+
description?: string | undefined;
|
|
74
75
|
dueString?: string | undefined;
|
|
75
76
|
responsibleUser?: string | undefined;
|
|
76
77
|
}[];
|
|
@@ -168,27 +169,27 @@ declare const tools: {
|
|
|
168
169
|
labels: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString, "many">>;
|
|
169
170
|
}, "strip", import("zod").ZodTypeAny, {
|
|
170
171
|
id: string;
|
|
171
|
-
description?: string | undefined;
|
|
172
|
-
parentId?: string | undefined;
|
|
173
|
-
content?: string | undefined;
|
|
174
172
|
projectId?: string | undefined;
|
|
175
173
|
sectionId?: string | undefined;
|
|
174
|
+
parentId?: string | undefined;
|
|
176
175
|
labels?: string[] | undefined;
|
|
177
176
|
duration?: string | undefined;
|
|
178
177
|
priority?: "p1" | "p2" | "p3" | "p4" | undefined;
|
|
178
|
+
content?: string | undefined;
|
|
179
|
+
description?: string | undefined;
|
|
179
180
|
dueString?: string | undefined;
|
|
180
181
|
responsibleUser?: string | null | undefined;
|
|
181
182
|
order?: number | undefined;
|
|
182
183
|
}, {
|
|
183
184
|
id: string;
|
|
184
|
-
description?: string | undefined;
|
|
185
|
-
parentId?: string | undefined;
|
|
186
|
-
content?: string | undefined;
|
|
187
185
|
projectId?: string | undefined;
|
|
188
186
|
sectionId?: string | undefined;
|
|
187
|
+
parentId?: string | undefined;
|
|
189
188
|
labels?: string[] | undefined;
|
|
190
189
|
duration?: string | undefined;
|
|
191
190
|
priority?: "p1" | "p2" | "p3" | "p4" | undefined;
|
|
191
|
+
content?: string | undefined;
|
|
192
|
+
description?: string | undefined;
|
|
192
193
|
dueString?: string | undefined;
|
|
193
194
|
responsibleUser?: string | null | undefined;
|
|
194
195
|
order?: number | undefined;
|
|
@@ -197,14 +198,14 @@ declare const tools: {
|
|
|
197
198
|
execute(args: {
|
|
198
199
|
tasks: {
|
|
199
200
|
id: string;
|
|
200
|
-
description?: string | undefined;
|
|
201
|
-
parentId?: string | undefined;
|
|
202
|
-
content?: string | undefined;
|
|
203
201
|
projectId?: string | undefined;
|
|
204
202
|
sectionId?: string | undefined;
|
|
203
|
+
parentId?: string | undefined;
|
|
205
204
|
labels?: string[] | undefined;
|
|
206
205
|
duration?: string | undefined;
|
|
207
206
|
priority?: "p1" | "p2" | "p3" | "p4" | undefined;
|
|
207
|
+
content?: string | undefined;
|
|
208
|
+
description?: string | undefined;
|
|
208
209
|
dueString?: string | undefined;
|
|
209
210
|
responsibleUser?: string | null | undefined;
|
|
210
211
|
order?: number | undefined;
|
|
@@ -269,15 +270,15 @@ declare const tools: {
|
|
|
269
270
|
};
|
|
270
271
|
execute(args: {
|
|
271
272
|
limit: number;
|
|
272
|
-
parentId?: string | undefined;
|
|
273
|
-
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
274
273
|
projectId?: string | undefined;
|
|
275
274
|
sectionId?: string | undefined;
|
|
275
|
+
parentId?: string | undefined;
|
|
276
276
|
labels?: string[] | undefined;
|
|
277
277
|
cursor?: string | undefined;
|
|
278
278
|
responsibleUser?: string | undefined;
|
|
279
279
|
labelsOperator?: "and" | "or" | undefined;
|
|
280
280
|
searchText?: string | undefined;
|
|
281
|
+
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
281
282
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
282
283
|
content: {
|
|
283
284
|
type: "text";
|
|
@@ -306,15 +307,15 @@ declare const tools: {
|
|
|
306
307
|
hasMore: boolean;
|
|
307
308
|
appliedFilters: {
|
|
308
309
|
limit: number;
|
|
309
|
-
parentId?: string | undefined;
|
|
310
|
-
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
311
310
|
projectId?: string | undefined;
|
|
312
311
|
sectionId?: string | undefined;
|
|
312
|
+
parentId?: string | undefined;
|
|
313
313
|
labels?: string[] | undefined;
|
|
314
314
|
cursor?: string | undefined;
|
|
315
315
|
responsibleUser?: string | undefined;
|
|
316
316
|
labelsOperator?: "and" | "or" | undefined;
|
|
317
317
|
searchText?: string | undefined;
|
|
318
|
+
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
318
319
|
};
|
|
319
320
|
};
|
|
320
321
|
} | {
|
|
@@ -347,11 +348,11 @@ declare const tools: {
|
|
|
347
348
|
execute(args: {
|
|
348
349
|
limit: number;
|
|
349
350
|
daysCount: number;
|
|
350
|
-
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
351
351
|
labels?: string[] | undefined;
|
|
352
352
|
cursor?: string | undefined;
|
|
353
353
|
responsibleUser?: string | undefined;
|
|
354
354
|
labelsOperator?: "and" | "or" | undefined;
|
|
355
|
+
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
355
356
|
startDate?: string | undefined;
|
|
356
357
|
overdueOption?: "overdue-only" | "include-overdue" | "exclude-overdue" | undefined;
|
|
357
358
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
@@ -383,11 +384,11 @@ declare const tools: {
|
|
|
383
384
|
appliedFilters: {
|
|
384
385
|
limit: number;
|
|
385
386
|
daysCount: number;
|
|
386
|
-
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
387
387
|
labels?: string[] | undefined;
|
|
388
388
|
cursor?: string | undefined;
|
|
389
389
|
responsibleUser?: string | undefined;
|
|
390
390
|
labelsOperator?: "and" | "or" | undefined;
|
|
391
|
+
responsibleUserFiltering?: "assigned" | "unassignedOrMe" | "all" | undefined;
|
|
391
392
|
startDate?: string | undefined;
|
|
392
393
|
overdueOption?: "overdue-only" | "include-overdue" | "exclude-overdue" | undefined;
|
|
393
394
|
};
|
|
@@ -427,11 +428,11 @@ declare const tools: {
|
|
|
427
428
|
getBy: "due" | "completion";
|
|
428
429
|
since: string;
|
|
429
430
|
until: string;
|
|
430
|
-
parentId?: string | undefined;
|
|
431
|
-
workspaceId?: string | undefined;
|
|
432
431
|
projectId?: string | undefined;
|
|
433
432
|
sectionId?: string | undefined;
|
|
433
|
+
parentId?: string | undefined;
|
|
434
434
|
labels?: string[] | undefined;
|
|
435
|
+
workspaceId?: string | undefined;
|
|
435
436
|
cursor?: string | undefined;
|
|
436
437
|
responsibleUser?: string | undefined;
|
|
437
438
|
labelsOperator?: "and" | "or" | undefined;
|
|
@@ -466,11 +467,11 @@ declare const tools: {
|
|
|
466
467
|
getBy: "due" | "completion";
|
|
467
468
|
since: string;
|
|
468
469
|
until: string;
|
|
469
|
-
parentId?: string | undefined;
|
|
470
|
-
workspaceId?: string | undefined;
|
|
471
470
|
projectId?: string | undefined;
|
|
472
471
|
sectionId?: string | undefined;
|
|
472
|
+
parentId?: string | undefined;
|
|
473
473
|
labels?: string[] | undefined;
|
|
474
|
+
workspaceId?: string | undefined;
|
|
474
475
|
cursor?: string | undefined;
|
|
475
476
|
responsibleUser?: string | undefined;
|
|
476
477
|
labelsOperator?: "and" | "or" | undefined;
|
|
@@ -500,22 +501,22 @@ declare const tools: {
|
|
|
500
501
|
viewStyle: import("zod").ZodOptional<import("zod").ZodEnum<["list", "board", "calendar"]>>;
|
|
501
502
|
}, "strip", import("zod").ZodTypeAny, {
|
|
502
503
|
name: string;
|
|
504
|
+
parentId?: string | undefined;
|
|
503
505
|
isFavorite?: boolean | undefined;
|
|
504
506
|
viewStyle?: "list" | "board" | "calendar" | undefined;
|
|
505
|
-
parentId?: string | undefined;
|
|
506
507
|
}, {
|
|
507
508
|
name: string;
|
|
509
|
+
parentId?: string | undefined;
|
|
508
510
|
isFavorite?: boolean | undefined;
|
|
509
511
|
viewStyle?: "list" | "board" | "calendar" | undefined;
|
|
510
|
-
parentId?: string | undefined;
|
|
511
512
|
}>, "many">;
|
|
512
513
|
};
|
|
513
514
|
execute({ projects }: {
|
|
514
515
|
projects: {
|
|
515
516
|
name: string;
|
|
517
|
+
parentId?: string | undefined;
|
|
516
518
|
isFavorite?: boolean | undefined;
|
|
517
519
|
viewStyle?: "list" | "board" | "calendar" | undefined;
|
|
518
|
-
parentId?: string | undefined;
|
|
519
520
|
}[];
|
|
520
521
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
521
522
|
content: {
|
|
@@ -595,21 +596,21 @@ declare const tools: {
|
|
|
595
596
|
viewStyle: import("zod").ZodOptional<import("zod").ZodEnum<["list", "board", "calendar"]>>;
|
|
596
597
|
}, "strip", import("zod").ZodTypeAny, {
|
|
597
598
|
id: string;
|
|
598
|
-
name?: string | undefined;
|
|
599
599
|
isFavorite?: boolean | undefined;
|
|
600
|
+
name?: string | undefined;
|
|
600
601
|
viewStyle?: "list" | "board" | "calendar" | undefined;
|
|
601
602
|
}, {
|
|
602
603
|
id: string;
|
|
603
|
-
name?: string | undefined;
|
|
604
604
|
isFavorite?: boolean | undefined;
|
|
605
|
+
name?: string | undefined;
|
|
605
606
|
viewStyle?: "list" | "board" | "calendar" | undefined;
|
|
606
607
|
}>, "many">;
|
|
607
608
|
};
|
|
608
609
|
execute(args: {
|
|
609
610
|
projects: {
|
|
610
611
|
id: string;
|
|
611
|
-
name?: string | undefined;
|
|
612
612
|
isFavorite?: boolean | undefined;
|
|
613
|
+
name?: string | undefined;
|
|
613
614
|
viewStyle?: "list" | "board" | "calendar" | undefined;
|
|
614
615
|
}[];
|
|
615
616
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
@@ -742,17 +743,17 @@ declare const tools: {
|
|
|
742
743
|
name: import("zod").ZodString;
|
|
743
744
|
projectId: import("zod").ZodString;
|
|
744
745
|
}, "strip", import("zod").ZodTypeAny, {
|
|
745
|
-
name: string;
|
|
746
746
|
projectId: string;
|
|
747
|
-
}, {
|
|
748
747
|
name: string;
|
|
748
|
+
}, {
|
|
749
749
|
projectId: string;
|
|
750
|
+
name: string;
|
|
750
751
|
}>, "many">;
|
|
751
752
|
};
|
|
752
753
|
execute({ sections }: {
|
|
753
754
|
sections: {
|
|
754
|
-
name: string;
|
|
755
755
|
projectId: string;
|
|
756
|
+
name: string;
|
|
756
757
|
}[];
|
|
757
758
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
758
759
|
content: {
|
|
@@ -894,19 +895,19 @@ declare const tools: {
|
|
|
894
895
|
content: import("zod").ZodString;
|
|
895
896
|
}, "strip", import("zod").ZodTypeAny, {
|
|
896
897
|
content: string;
|
|
897
|
-
taskId?: string | undefined;
|
|
898
898
|
projectId?: string | undefined;
|
|
899
|
+
taskId?: string | undefined;
|
|
899
900
|
}, {
|
|
900
901
|
content: string;
|
|
901
|
-
taskId?: string | undefined;
|
|
902
902
|
projectId?: string | undefined;
|
|
903
|
+
taskId?: string | undefined;
|
|
903
904
|
}>, "many">;
|
|
904
905
|
};
|
|
905
906
|
execute(args: {
|
|
906
907
|
comments: {
|
|
907
908
|
content: string;
|
|
908
|
-
taskId?: string | undefined;
|
|
909
909
|
projectId?: string | undefined;
|
|
910
|
+
taskId?: string | undefined;
|
|
910
911
|
}[];
|
|
911
912
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
912
913
|
content: {
|
|
@@ -1036,10 +1037,10 @@ declare const tools: {
|
|
|
1036
1037
|
limit: import("zod").ZodOptional<import("zod").ZodNumber>;
|
|
1037
1038
|
};
|
|
1038
1039
|
execute(args: {
|
|
1039
|
-
limit?: number | undefined;
|
|
1040
|
-
taskId?: string | undefined;
|
|
1041
1040
|
projectId?: string | undefined;
|
|
1041
|
+
limit?: number | undefined;
|
|
1042
1042
|
cursor?: string | undefined;
|
|
1043
|
+
taskId?: string | undefined;
|
|
1043
1044
|
commentId?: string | undefined;
|
|
1044
1045
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
1045
1046
|
content: {
|
|
@@ -1091,6 +1092,72 @@ declare const tools: {
|
|
|
1091
1092
|
structuredContent?: undefined;
|
|
1092
1093
|
}>;
|
|
1093
1094
|
};
|
|
1095
|
+
findActivity: {
|
|
1096
|
+
name: "find-activity";
|
|
1097
|
+
description: string;
|
|
1098
|
+
parameters: {
|
|
1099
|
+
objectType: import("zod").ZodOptional<import("zod").ZodEnum<["task", "project", "comment"]>>;
|
|
1100
|
+
objectId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
1101
|
+
eventType: import("zod").ZodOptional<import("zod").ZodEnum<["added", "updated", "deleted", "completed", "uncompleted", "archived", "unarchived", "shared", "left"]>>;
|
|
1102
|
+
projectId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
1103
|
+
taskId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
1104
|
+
initiatorId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
1105
|
+
limit: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
1106
|
+
cursor: import("zod").ZodOptional<import("zod").ZodString>;
|
|
1107
|
+
};
|
|
1108
|
+
execute(args: {
|
|
1109
|
+
limit: number;
|
|
1110
|
+
projectId?: string | undefined;
|
|
1111
|
+
objectType?: "task" | "project" | "comment" | undefined;
|
|
1112
|
+
objectId?: string | undefined;
|
|
1113
|
+
eventType?: "added" | "updated" | "deleted" | "completed" | "uncompleted" | "archived" | "unarchived" | "shared" | "left" | undefined;
|
|
1114
|
+
initiatorId?: string | undefined;
|
|
1115
|
+
cursor?: string | undefined;
|
|
1116
|
+
taskId?: string | undefined;
|
|
1117
|
+
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
1118
|
+
content: {
|
|
1119
|
+
type: "text";
|
|
1120
|
+
text: string;
|
|
1121
|
+
}[];
|
|
1122
|
+
structuredContent: {
|
|
1123
|
+
events: {
|
|
1124
|
+
id: string | null;
|
|
1125
|
+
objectType: string;
|
|
1126
|
+
objectId: string;
|
|
1127
|
+
eventType: string;
|
|
1128
|
+
eventDate: string;
|
|
1129
|
+
parentProjectId: string | null;
|
|
1130
|
+
parentItemId: string | null;
|
|
1131
|
+
initiatorId: string | null;
|
|
1132
|
+
extraData: Record<string, any> | null;
|
|
1133
|
+
}[];
|
|
1134
|
+
nextCursor: string | null;
|
|
1135
|
+
totalCount: number;
|
|
1136
|
+
hasMore: boolean;
|
|
1137
|
+
appliedFilters: {
|
|
1138
|
+
limit: number;
|
|
1139
|
+
projectId?: string | undefined;
|
|
1140
|
+
objectType?: "task" | "project" | "comment" | undefined;
|
|
1141
|
+
objectId?: string | undefined;
|
|
1142
|
+
eventType?: "added" | "updated" | "deleted" | "completed" | "uncompleted" | "archived" | "unarchived" | "shared" | "left" | undefined;
|
|
1143
|
+
initiatorId?: string | undefined;
|
|
1144
|
+
cursor?: string | undefined;
|
|
1145
|
+
taskId?: string | undefined;
|
|
1146
|
+
};
|
|
1147
|
+
};
|
|
1148
|
+
} | {
|
|
1149
|
+
content: ({
|
|
1150
|
+
type: "text";
|
|
1151
|
+
text: string;
|
|
1152
|
+
mimeType?: undefined;
|
|
1153
|
+
} | {
|
|
1154
|
+
type: "text";
|
|
1155
|
+
mimeType: string;
|
|
1156
|
+
text: string;
|
|
1157
|
+
})[];
|
|
1158
|
+
structuredContent?: undefined;
|
|
1159
|
+
}>;
|
|
1160
|
+
};
|
|
1094
1161
|
getOverview: {
|
|
1095
1162
|
name: "get-overview";
|
|
1096
1163
|
description: string;
|
|
@@ -1127,7 +1194,7 @@ declare const tools: {
|
|
|
1127
1194
|
};
|
|
1128
1195
|
execute(args: {
|
|
1129
1196
|
id: string;
|
|
1130
|
-
type: "task" | "
|
|
1197
|
+
type: "task" | "project" | "comment" | "section";
|
|
1131
1198
|
}, client: import("@doist/todoist-api-typescript").TodoistApi): Promise<{
|
|
1132
1199
|
content: {
|
|
1133
1200
|
type: "text";
|
|
@@ -1135,7 +1202,7 @@ declare const tools: {
|
|
|
1135
1202
|
}[];
|
|
1136
1203
|
structuredContent: {
|
|
1137
1204
|
deletedEntity: {
|
|
1138
|
-
type: "task" | "
|
|
1205
|
+
type: "task" | "project" | "comment" | "section";
|
|
1139
1206
|
id: string;
|
|
1140
1207
|
};
|
|
1141
1208
|
success: boolean;
|
|
@@ -1312,5 +1379,5 @@ declare const tools: {
|
|
|
1312
1379
|
};
|
|
1313
1380
|
};
|
|
1314
1381
|
export { tools, getMcpServer };
|
|
1315
|
-
export { addTasks, completeTasks, updateTasks, findTasks, findTasksByDate, findCompletedTasks, addProjects, updateProjects, findProjects, addSections, updateSections, findSections, addComments, updateComments, findComments, getOverview, deleteObject, userInfo, findProjectCollaborators, manageAssignments, search, fetch, };
|
|
1382
|
+
export { addTasks, completeTasks, updateTasks, findTasks, findTasksByDate, findCompletedTasks, addProjects, updateProjects, findProjects, addSections, updateSections, findSections, addComments, updateComments, findComments, findActivity, getOverview, deleteObject, userInfo, findProjectCollaborators, manageAssignments, search, fetch, };
|
|
1316
1383
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAE9C,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAErD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAErD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AAErD,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAA;AAEzD,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AACvD,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAE9C,OAAO,EAAE,WAAW,EAAE,M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
|
|
12
12
|
import { deleteObject } from './tools/delete-object.js';
|
|
13
13
|
import { fetch } from './tools/fetch.js';
|
|
14
|
+
// Activity and audit tools
|
|
15
|
+
import { findActivity } from './tools/find-activity.js';
|
|
14
16
|
import { findComments } from './tools/find-comments.js';
|
|
15
17
|
import { findCompletedTasks } from './tools/find-completed-tasks.js';
|
|
16
18
|
// Assignment and collaboration tools
|
|
@@ -47,6 +49,8 @@ const tools = {
|
|
|
47
49
|
addComments,
|
|
48
50
|
updateComments,
|
|
49
51
|
findComments,
|
|
52
|
+
// Activity and audit tools
|
|
53
|
+
findActivity,
|
|
50
54
|
// General tools
|
|
51
55
|
getOverview,
|
|
52
56
|
deleteObject,
|
|
@@ -68,6 +72,8 @@ addProjects, updateProjects, findProjects,
|
|
|
68
72
|
addSections, updateSections, findSections,
|
|
69
73
|
// Comment management tools
|
|
70
74
|
addComments, updateComments, findComments,
|
|
75
|
+
// Activity and audit tools
|
|
76
|
+
findActivity,
|
|
71
77
|
// General tools
|
|
72
78
|
getOverview, deleteObject, userInfo,
|
|
73
79
|
// Assignment and collaboration tools
|
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":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAA;
|
|
1
|
+
{"version":3,"file":"mcp-server.d.ts","sourceRoot":"","sources":["../src/mcp-server.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAA;AA+FnE;;;;;GAKG;AACH,iBAAS,YAAY,CAAC,EAAE,aAAa,EAAE,OAAO,EAAE,EAAE;IAAE,aAAa,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,aAqD5F;AAED,OAAO,EAAE,YAAY,EAAE,CAAA"}
|
package/dist/mcp-server.js
CHANGED
|
@@ -8,6 +8,7 @@ import { addTasks } from './tools/add-tasks.js';
|
|
|
8
8
|
import { completeTasks } from './tools/complete-tasks.js';
|
|
9
9
|
import { deleteObject } from './tools/delete-object.js';
|
|
10
10
|
import { fetch } from './tools/fetch.js';
|
|
11
|
+
import { findActivity } from './tools/find-activity.js';
|
|
11
12
|
import { findComments } from './tools/find-comments.js';
|
|
12
13
|
import { findCompletedTasks } from './tools/find-completed-tasks.js';
|
|
13
14
|
import { findProjectCollaborators } from './tools/find-project-collaborators.js';
|
|
@@ -43,7 +44,7 @@ You have access to comprehensive Todoist management tools for personal productiv
|
|
|
43
44
|
- **complete-tasks**: Mark tasks as done using task IDs
|
|
44
45
|
- **find-tasks**: Search by text, project/section/parent container, responsible user, or labels. Requires at least one search parameter
|
|
45
46
|
- **find-tasks-by-date**: Get tasks by date range (startDate: YYYY-MM-DD or 'today' which includes overdue tasks) or specific day counts
|
|
46
|
-
- **find-completed-tasks**: View completed tasks by completion date or original due date
|
|
47
|
+
- **find-completed-tasks**: View completed tasks by completion date or original due date (returns all collaborators unless filtered)
|
|
47
48
|
|
|
48
49
|
**Project & Organization:**
|
|
49
50
|
- **add-projects/update-projects/find-projects**: Manage project lifecycle with names, favorites, and view styles (list/board/calendar)
|
|
@@ -55,6 +56,9 @@ You have access to comprehensive Todoist management tools for personal productiv
|
|
|
55
56
|
- **find-project-collaborators**: Find team members by name or email for assignments
|
|
56
57
|
- **manage-assignments**: Bulk assign/unassign/reassign up to 50 tasks with atomic operations and dry-run validation
|
|
57
58
|
|
|
59
|
+
**Activity & Audit:**
|
|
60
|
+
- **find-activity**: Retrieve recent activity logs to monitor and audit changes. Shows events from all users by default; use initiatorId to filter by specific user. Filter by object type (task/project/comment), event type (added/updated/deleted/completed/uncompleted/archived/unarchived/shared/left), and specific objects (objectId, projectId, taskId). Useful for tracking who did what and when. Note: Date-based filtering is not supported.
|
|
61
|
+
|
|
58
62
|
**General Operations:**
|
|
59
63
|
- **delete-object**: Remove projects, sections, tasks, or comments by type and ID
|
|
60
64
|
- **user-info**: Get user details including timezone, goals, and plan information
|
|
@@ -84,6 +88,7 @@ You have access to comprehensive Todoist management tools for personal productiv
|
|
|
84
88
|
- **Task Search**: find-tasks with multiple filters → update-tasks or complete-tasks based on results
|
|
85
89
|
- **Project Organization**: add-projects → add-sections → add-tasks with projectId and sectionId
|
|
86
90
|
- **Progress Reviews**: find-completed-tasks with date ranges → get-overview for project summaries
|
|
91
|
+
- **Activity Auditing**: find-activity with event/object filters to track changes, monitor team activity, or investigate specific actions
|
|
87
92
|
|
|
88
93
|
Always provide clear, actionable task titles and descriptions. Use the overview tools to give users context about their workload and project status.
|
|
89
94
|
`;
|
|
@@ -120,6 +125,8 @@ function getMcpServer({ todoistApiKey, baseUrl }) {
|
|
|
120
125
|
registerTool(addComments, server, todoist);
|
|
121
126
|
registerTool(findComments, server, todoist);
|
|
122
127
|
registerTool(updateComments, server, todoist);
|
|
128
|
+
// Activity and audit tools
|
|
129
|
+
registerTool(findActivity, server, todoist);
|
|
123
130
|
// General tools
|
|
124
131
|
registerTool(getOverview, server, todoist);
|
|
125
132
|
registerTool(deleteObject, server, todoist);
|
package/dist/tool-helpers.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { MoveTaskArgs, PersonalProject, Task, TodoistApi, WorkspaceProject } from '@doist/todoist-api-typescript';
|
|
1
|
+
import type { ActivityEvent, MoveTaskArgs, PersonalProject, Task, TodoistApi, WorkspaceProject } from '@doist/todoist-api-typescript';
|
|
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 declare function isPersonalProject(project: Project): project is PersonalProject;
|
|
@@ -50,6 +50,22 @@ declare function mapProject(project: Project): {
|
|
|
50
50
|
inboxProject: boolean;
|
|
51
51
|
viewStyle: string;
|
|
52
52
|
};
|
|
53
|
+
/**
|
|
54
|
+
* Map a single Todoist activity event to a more structured format, for LLM consumption.
|
|
55
|
+
* @param event - The activity event to map.
|
|
56
|
+
* @returns The mapped activity event.
|
|
57
|
+
*/
|
|
58
|
+
declare function mapActivityEvent(event: ActivityEvent): {
|
|
59
|
+
id: string | null;
|
|
60
|
+
objectType: string;
|
|
61
|
+
objectId: string;
|
|
62
|
+
eventType: string;
|
|
63
|
+
eventDate: string;
|
|
64
|
+
parentProjectId: string | null;
|
|
65
|
+
parentItemId: string | null;
|
|
66
|
+
initiatorId: string | null;
|
|
67
|
+
extraData: Record<string, any> | null;
|
|
68
|
+
};
|
|
53
69
|
declare function getTasksByFilter({ client, query, limit, cursor, }: {
|
|
54
70
|
client: TodoistApi;
|
|
55
71
|
query: string;
|
|
@@ -82,5 +98,5 @@ declare function getTasksByFilter({ client, query, limit, cursor, }: {
|
|
|
82
98
|
* @returns The URL string
|
|
83
99
|
*/
|
|
84
100
|
declare function buildTodoistUrl(type: 'task' | 'project', id: string): string;
|
|
85
|
-
export { buildTodoistUrl, getTasksByFilter, mapProject, mapTask };
|
|
101
|
+
export { buildTodoistUrl, getTasksByFilter, mapActivityEvent, mapProject, mapTask };
|
|
86
102
|
//# sourceMappingURL=tool-helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tool-helpers.d.ts","sourceRoot":"","sources":["../src/tool-helpers.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,YAAY,EACZ,eAAe,EACf,IAAI,EACJ,UAAU,EACV,gBAAgB,EACnB,MAAM,+BAA+B,CAAA;AAKtC,OAAO,EACH,aAAa,EACb,+BAA+B,EAC/B,4BAA4B,EAC5B,0BAA0B,EAC1B,KAAK,wBAAwB,EAC7B,sBAAsB,GACzB,MAAM,qBAAqB,CAAA;AAE5B,MAAM,MAAM,OAAO,GAAG,eAAe,GAAG,gBAAgB,CAAA;AAExD,wBAAgB,iBAAiB,CAAC,OAAO,EA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81
|
+
* Map a single Todoist activity event to a more structured format, for LLM consumption.
|
|
82
|
+
* @param event - The activity event to map.
|
|
83
|
+
* @returns The mapped activity event.
|
|
84
|
+
*/
|
|
85
|
+
function mapActivityEvent(event) {
|
|
86
|
+
return {
|
|
87
|
+
id: event.id,
|
|
88
|
+
objectType: event.objectType,
|
|
89
|
+
objectId: event.objectId,
|
|
90
|
+
eventType: event.eventType,
|
|
91
|
+
eventDate: event.eventDate,
|
|
92
|
+
parentProjectId: event.parentProjectId,
|
|
93
|
+
parentItemId: event.parentItemId,
|
|
94
|
+
initiatorId: event.initiatorId,
|
|
95
|
+
extraData: event.extraData,
|
|
96
|
+
};
|
|
97
|
+
}
|
|
80
98
|
const ErrorSchema = z.object({
|
|
81
99
|
httpStatusCode: z.number(),
|
|
82
100
|
responseData: z.object({
|
|
@@ -112,4 +130,4 @@ async function getTasksByFilter({ client, query, limit, cursor, }) {
|
|
|
112
130
|
function buildTodoistUrl(type, id) {
|
|
113
131
|
return `https://app.todoist.com/app/${type}/${id}`;
|
|
114
132
|
}
|
|
115
|
-
export { buildTodoistUrl, getTasksByFilter, mapProject, mapTask };
|
|
133
|
+
export { buildTodoistUrl, getTasksByFilter, mapActivityEvent, mapProject, mapTask };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"find-activity.test.d.ts","sourceRoot":"","sources":["../../../src/tools/__tests__/find-activity.test.ts"],"names":[],"mappings":""}
|