togello-mcp-server 1.0.35 → 1.0.36
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/build/handlers/resource/tasksHandler.js +2 -0
- package/build/handlers/tool/createTaskHandler.js +5 -1
- package/build/handlers/tool/getTodayCalendarHandler.js +1 -0
- package/build/handlers/tool/getTodoListHandler.js +1 -0
- package/build/handlers/tool/updateTaskHandler.js +4 -1
- package/build/mcpServer.js +15 -3
- package/build/types/todo.js +1 -0
- package/package.json +1 -1
|
@@ -12,8 +12,10 @@ export const tasksHandler = async (uri, _options) => {
|
|
|
12
12
|
text: tasks
|
|
13
13
|
.map((todo) => JSON.stringify({
|
|
14
14
|
label: todo.label,
|
|
15
|
+
status: todo.status,
|
|
15
16
|
scheduledStartDate: todo.scheduledStartDate,
|
|
16
17
|
scheduledEndDate: todo.scheduledEndDate,
|
|
18
|
+
deadlineDateTime: todo.deadlineDateTime,
|
|
17
19
|
priorityNumber: todo.priorityNumber,
|
|
18
20
|
}))
|
|
19
21
|
.join(','),
|
|
@@ -1,20 +1,24 @@
|
|
|
1
1
|
import { httpClient } from '../../client.js';
|
|
2
2
|
import { errorToolResponse, jsonToolResponse } from './toolResponse.js';
|
|
3
|
-
export const createTaskHandler = async ({ taskName, categoryUUID, scheduledStartDate, scheduledEndDate, url, detail, }) => {
|
|
3
|
+
export const createTaskHandler = async ({ taskName, status, categoryUUID, scheduledStartDate, scheduledEndDate, deadlineDateTime, url, detail, }) => {
|
|
4
4
|
try {
|
|
5
5
|
await httpClient.postJson({
|
|
6
6
|
path: '/v2/integration/todo',
|
|
7
7
|
body: {
|
|
8
8
|
label: taskName,
|
|
9
|
+
status: status,
|
|
9
10
|
categoryUUID: categoryUUID,
|
|
10
11
|
scheduledStartDate: scheduledStartDate,
|
|
11
12
|
scheduledEndDate: scheduledEndDate,
|
|
13
|
+
deadlineDateTime: deadlineDateTime,
|
|
12
14
|
url: url,
|
|
13
15
|
detail: detail,
|
|
14
16
|
},
|
|
15
17
|
});
|
|
16
18
|
return jsonToolResponse({
|
|
17
19
|
taskName,
|
|
20
|
+
status,
|
|
21
|
+
deadlineDateTime,
|
|
18
22
|
created: true,
|
|
19
23
|
});
|
|
20
24
|
}
|
|
@@ -17,6 +17,7 @@ export const getTodoListHandler = async ({ categoryUUIDs, }) => {
|
|
|
17
17
|
detail: todo.detail,
|
|
18
18
|
scheduledStartDate: todo.scheduledStartDate,
|
|
19
19
|
scheduledEndDate: todo.scheduledEndDate,
|
|
20
|
+
deadlineDateTime: todo.deadlineDateTime,
|
|
20
21
|
priorityNumber: todo.priorityNumber,
|
|
21
22
|
categoryUUID: todo.categoryUUID,
|
|
22
23
|
categoryLabel: todo.categoryLabel,
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { httpClient } from '../../client.js';
|
|
2
2
|
import { errorToolResponse, jsonToolResponse } from './toolResponse.js';
|
|
3
|
-
export const updateTaskHandler = async ({ todoUUID, taskName, isCompleted, status, scheduledStartDate, scheduledEndDate, url, detail, }) => {
|
|
3
|
+
export const updateTaskHandler = async ({ todoUUID, taskName, isCompleted, status, scheduledStartDate, scheduledEndDate, deadlineDateTime, url, detail, }) => {
|
|
4
4
|
try {
|
|
5
5
|
if (taskName === undefined &&
|
|
6
6
|
isCompleted === undefined &&
|
|
7
7
|
status === undefined &&
|
|
8
8
|
scheduledStartDate === undefined &&
|
|
9
9
|
scheduledEndDate === undefined &&
|
|
10
|
+
deadlineDateTime === undefined &&
|
|
10
11
|
url === undefined &&
|
|
11
12
|
detail === undefined) {
|
|
12
13
|
return errorToolResponse('At least one update field is required');
|
|
@@ -22,6 +23,7 @@ export const updateTaskHandler = async ({ todoUUID, taskName, isCompleted, statu
|
|
|
22
23
|
status,
|
|
23
24
|
scheduledStartDate,
|
|
24
25
|
scheduledEndDate,
|
|
26
|
+
deadlineDateTime,
|
|
25
27
|
url,
|
|
26
28
|
detail,
|
|
27
29
|
},
|
|
@@ -31,6 +33,7 @@ export const updateTaskHandler = async ({ todoUUID, taskName, isCompleted, statu
|
|
|
31
33
|
taskName,
|
|
32
34
|
isCompleted,
|
|
33
35
|
status,
|
|
36
|
+
deadlineDateTime,
|
|
34
37
|
updated: true,
|
|
35
38
|
});
|
|
36
39
|
}
|
package/build/mcpServer.js
CHANGED
|
@@ -50,7 +50,7 @@ export function createMcpServer(options = {}) {
|
|
|
50
50
|
},
|
|
51
51
|
});
|
|
52
52
|
server.registerTool('get-tasks-list', {
|
|
53
|
-
description: 'Retrieves incomplete tasks from the TODO feature. Recognizes task uuid / task name / status / detail / scheduled start date and time / scheduled end date and time / priority / category',
|
|
53
|
+
description: 'Retrieves incomplete tasks from the TODO feature. Recognizes task uuid / task name / status / detail / scheduled start date and time / scheduled end date and time / deadline date and time / priority / category',
|
|
54
54
|
inputSchema: {
|
|
55
55
|
categoryUUIDs: z
|
|
56
56
|
.array(z.string())
|
|
@@ -63,6 +63,10 @@ export function createMcpServer(options = {}) {
|
|
|
63
63
|
description: 'Creates a new task in the TODO feature.',
|
|
64
64
|
inputSchema: {
|
|
65
65
|
taskName: z.string().describe('create task name'),
|
|
66
|
+
status: z
|
|
67
|
+
.enum(['TODO', 'PENDING', 'DOING', 'DONE'])
|
|
68
|
+
.optional()
|
|
69
|
+
.describe('Optional. Creates the task with the specified todo status.'),
|
|
66
70
|
categoryUUID: z
|
|
67
71
|
.string()
|
|
68
72
|
.optional()
|
|
@@ -75,6 +79,10 @@ export function createMcpServer(options = {}) {
|
|
|
75
79
|
.string()
|
|
76
80
|
.optional()
|
|
77
81
|
.describe('Scheduled end date in ISO format.'),
|
|
82
|
+
deadlineDateTime: z
|
|
83
|
+
.string()
|
|
84
|
+
.optional()
|
|
85
|
+
.describe('Deadline date and time in ISO format.'),
|
|
78
86
|
url: z
|
|
79
87
|
.string()
|
|
80
88
|
.optional()
|
|
@@ -102,9 +110,9 @@ export function createMcpServer(options = {}) {
|
|
|
102
110
|
.optional()
|
|
103
111
|
.describe('Optional. Backward-compatible completion update. true marks the task done. false preserves existing TODO or DOING tasks and reopens DONE tasks to TODO.'),
|
|
104
112
|
status: z
|
|
105
|
-
.enum(['TODO', 'DOING', 'DONE'])
|
|
113
|
+
.enum(['TODO', 'PENDING', 'DOING', 'DONE'])
|
|
106
114
|
.optional()
|
|
107
|
-
.describe('Optional. Updates the todo status directly. Use this to switch tasks between TODO, DOING, and DONE.'),
|
|
115
|
+
.describe('Optional. Updates the todo status directly. Use this to switch tasks between TODO, PENDING, DOING, and DONE.'),
|
|
108
116
|
scheduledStartDate: z
|
|
109
117
|
.string()
|
|
110
118
|
.optional()
|
|
@@ -113,6 +121,10 @@ export function createMcpServer(options = {}) {
|
|
|
113
121
|
.string()
|
|
114
122
|
.optional()
|
|
115
123
|
.describe('Scheduled end date in ISO format. If omitted, the current value is kept.'),
|
|
124
|
+
deadlineDateTime: z
|
|
125
|
+
.string()
|
|
126
|
+
.optional()
|
|
127
|
+
.describe('Deadline date and time in ISO format. If omitted, the current value is kept.'),
|
|
116
128
|
url: z
|
|
117
129
|
.string()
|
|
118
130
|
.optional()
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/package.json
CHANGED