togello-mcp-server 1.0.43 → 1.0.44

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/README.md CHANGED
@@ -83,6 +83,7 @@ Write tools return JSON. Failed tool responses also return JSON and are marked w
83
83
 
84
84
  - `create-task`: Creates a TODO task.
85
85
  - `update-task`: Updates a TODO task, including category assignment or removal.
86
+ - `delete-task`: Permanently deletes one TODO task by `todoUUID` from `get-tasks-list`. Use `update-task` with `status: "DONE"` to complete a task. To find completed tasks for deletion, use `completionStatus: "COMPLETED"`. This destructive, idempotent tool returns `{ "todoUUID": "...", "deleted": true }` after a successful API response, including when no task owned by the caller matches. Success does not prove that a task previously existed. Ambiguous targets must be clarified before deletion.
86
87
  - `update-calendar-date-memo`: Updates or clears a calendar date memo.
87
88
  - `start-activity-log`: Starts an activity log.
88
89
  - `complete-activity-log`: Completes an activity log.
@@ -94,7 +95,7 @@ npm ci
94
95
  npm test
95
96
  ```
96
97
 
97
- The protocol tests exercise SDK v2 modern clients and SDK v1.29.0 legacy clients over stdio, Streamable HTTP, and legacy SSE against a local mock API. They verify the 12 existing tool contracts, read/write results, request credential isolation, protocol header errors, body limits, metadata, and legacy session lifecycle. `test/fixtures/v1-tools.json` records `tools/list` from server 1.0.42 at commit `558c2c2fda81f7c8b20f443afa1bf5e554a72dad`; comparisons allow the SDK's JSON Schema dialect and wire-format changes.
98
+ The protocol tests exercise SDK v2 modern clients and SDK v1.29.0 legacy clients over stdio, Streamable HTTP, and legacy SSE against a local mock API. They verify the 12 existing tool contracts and the added deletion tool, read/write/delete results, request credential isolation, protocol header errors, body limits, metadata, and legacy session lifecycle. `test/fixtures/v1-tools.json` records `tools/list` from server 1.0.42 at commit `558c2c2fda81f7c8b20f443afa1bf5e554a72dad`; comparisons allow the SDK's JSON Schema dialect and wire-format changes.
98
99
 
99
100
  SDK-facing schemas use Zod 4. UUID fields retain the prior permissive UUID syntax, and date-time fields retain their previous Zod 3 validation through the compatibility export included in the Zod package.
100
101
 
package/build/client.js CHANGED
@@ -8,6 +8,19 @@ function getApiTokenOrThrow() {
8
8
  return token;
9
9
  }
10
10
  export const httpClient = {
11
+ delete: async ({ path }) => {
12
+ const token = getApiTokenOrThrow();
13
+ const response = await fetch(`${API_BASE_URL}${path}`, {
14
+ method: 'DELETE',
15
+ headers: {
16
+ Authorization: `Bearer ${token}`,
17
+ },
18
+ });
19
+ if (!response.ok) {
20
+ throw new Error(`response status: ${response.status}`);
21
+ }
22
+ await response.arrayBuffer();
23
+ },
11
24
  fetchURL: async ({ path }) => {
12
25
  const token = getApiTokenOrThrow();
13
26
  const url = `${API_BASE_URL}${path}`;
@@ -0,0 +1,13 @@
1
+ import { httpClient } from '../../client.js';
2
+ import { errorToolResponse, jsonToolResponse } from './toolResponse.js';
3
+ export const deleteTaskHandler = async ({ todoUUID }) => {
4
+ try {
5
+ await httpClient.delete({
6
+ path: `/v2/integration/todo/${encodeURIComponent(todoUUID)}`,
7
+ });
8
+ return jsonToolResponse({ todoUUID, deleted: true });
9
+ }
10
+ catch {
11
+ return errorToolResponse('Error deleting task');
12
+ }
13
+ };
@@ -3,6 +3,7 @@ import { z } from 'zod';
3
3
  import { z as legacyZod } from 'zod/v3';
4
4
  import { completeActivityLogHandler } from './handlers/tool/completeActivityLogHandler.js';
5
5
  import { createTaskHandler } from './handlers/tool/createTaskHandler.js';
6
+ import { deleteTaskHandler } from './handlers/tool/deleteTaskHandler.js';
6
7
  import { getActivityItemListHandler } from './handlers/tool/getActivityItemListHandler.js';
7
8
  import { getActivityLogListHandler } from './handlers/tool/getActivityLogListHandler.js';
8
9
  import { getCalendarDateMemoHandler } from './handlers/tool/getCalendarDateMemoHandler.js';
@@ -161,6 +162,16 @@ export function createMcpServer(options = {}) {
161
162
  }),
162
163
  annotations: privateOverwriteToolAnnotations,
163
164
  }, withUpstreamToken(updateTaskHandler, options.resolveUpstreamToken, options.requireUpstreamToken));
165
+ server.registerTool('delete-task', {
166
+ description: 'Permanently deletes a single task from the TODO feature. Use only when the user requests deletion or removal. Specify the todoUUID obtained from get-tasks-list; clarify the target if ambiguous. To complete a task, use update-task with status DONE. To find completed tasks, call get-tasks-list with completionStatus COMPLETED. Repeated deletion succeeds when no task owned by the caller matches; success does not confirm that a task previously existed.',
167
+ inputSchema: z.strictObject({
168
+ todoUUID: z.guid().describe('Task UUID obtained from get-tasks-list.'),
169
+ }),
170
+ annotations: {
171
+ ...privateOverwriteToolAnnotations,
172
+ idempotentHint: true,
173
+ },
174
+ }, withUpstreamToken(deleteTaskHandler, options.resolveUpstreamToken, options.requireUpstreamToken));
164
175
  server.registerTool('get-calendar-date-memo', {
165
176
  description: 'Retrieves a calendar date memo for the specified date. Recognizes target date and memo content.',
166
177
  inputSchema: z.object({
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "togello-mcp-server",
4
- "version": "1.0.43",
4
+ "version": "1.0.44",
5
5
  "description": "MCP server for Togello tasks, calendar memos, calendar events, and activity logs.",
6
6
  "main": "build/index.js",
7
7
  "scripts": {
@@ -48,5 +48,7 @@
48
48
  "togello": "build/index.js",
49
49
  "togello-mcp-server": "build/index.js"
50
50
  },
51
- "files": ["build"]
51
+ "files": [
52
+ "build"
53
+ ]
52
54
  }