togello-mcp-server 1.0.17 → 1.0.19

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
@@ -16,7 +16,7 @@ This server implements the Model Context Protocol (MCP) for managing context in
16
16
  }
17
17
  }
18
18
  }
19
-
19
+ ```
20
20
 
21
21
  # Features
22
22
 
@@ -27,17 +27,15 @@ This server implements the Model Context Protocol (MCP) for managing context in
27
27
 
28
28
  ## Tools
29
29
 
30
- - get-tasks-list: TODO機能で未完了のタスクを取得します。タスクUUID / タスク名 / 予定開始日時 / 予定終了日時 / 優先度 / カテゴリ を認識できます。
31
- - create-task: TODO機能で新しいタスクを作成します。タスク名(taskName)を指定する必要があります。カテゴリーUUID(categoryUUID)、予定開始日時(scheduledStartDate)、URL(url)もオプションで指定できます。
32
- - update-task: TODO機能でタスクを更新します。タスクの完了状態を更新できます。get-tasks-listで取得したタスクUUIDを指定する必要があります。
33
- - get-todo-category-list: TODO機能からカテゴリーリストを取得します。カテゴリー名 / カテゴリーUUID を認識できます。
34
- - get-today-calendar: 連携しているGoogleカレンダーの昨日/今日/明日の予定を取得します。予定名 / 開始日時 / 終了日時 を認識できます。
35
- - get-activity-item-list: 統合機能からアクティビティ項目のリストを取得します。アクティビティ項目UUID / 項目名 を認識できます。
36
- - get-activity-log-list: 統合機能からアクティビティログのリストを取得します。すべてのログの終了日時が入力されている場合、現在何も実行していないことを意味します。終了日時がnullのものがある場合(最大で1つ)、現在その活動を実行中であることを意味します。アクティビティログUUID / 開始日時 / 終了日時 / 項目名 を認識できます。
37
- - start-activity-log: アクティビティログを開始します。get-activity-log-listのすべてのendDateTimeに値がある場合、何も実行されていないため、start-activity-logを呼び出すことができます。
38
- - complete-activity-log: アクティビティログを完了します。get-activity-log-listのendDateTimeにnullがある場合(つまり開始されているアクティビティがある場合)に使用できます。
39
-
40
- ```
30
+ - get-tasks-list: TODO 機能で未完了のタスクを取得します。タスク UUID / タスク名 / 予定開始日時 / 予定終了日時 / 優先度 / カテゴリ を認識できます。
31
+ - create-task: TODO 機能で新しいタスクを作成します。タスク名(taskName)を指定する必要があります。カテゴリー UUID(categoryUUID)、予定開始日時(scheduledStartDate)、URL(url)もオプションで指定できます。
32
+ - update-task: TODO 機能でタスクを更新します。タスクの完了状態を更新できます。get-tasks-list で取得したタスク UUID を指定する必要があります。
33
+ - get-todo-category-list: TODO 機能からカテゴリーリストを取得します。カテゴリー名 / カテゴリー UUID を認識できます。
34
+ - get-today-calendar: 連携している Google カレンダーの昨日/今日/明日の予定を取得します。予定名 / 開始日時 / 終了日時 を認識できます。
35
+ - get-activity-item-list: 統合機能からアクティビティ項目のリストを取得します。アクティビティ項目 UUID / 項目名 を認識できます。
36
+ - get-activity-log-list: 統合機能からアクティビティログのリストを取得します。すべてのログの終了日時が入力されている場合、現在何も実行していないことを意味します。終了日時が null のものがある場合(最大で 1 つ)、現在その活動を実行中であることを意味します。アクティビティログ UUID / 開始日時 / 終了日時 / 項目名 を認識できます。
37
+ - start-activity-log: アクティビティログを開始します。`get-activity-item-list` で取得した項目名(`activityItemName`)を指定する必要があります。`get-activity-log-list` で取得したログリストの全ての `endDateTime` に値がある場合(現在実行中のアクティビティがない場合)に呼び出すことができます。
38
+ - complete-activity-log: アクティビティログを完了します。`get-activity-log-list` で取得した、現在実行中のアクティビティログの UUID(`activityLogUUID`)を指定する必要があります。
41
39
 
42
40
  ## publish
43
41
 
package/build/client.js CHANGED
@@ -43,7 +43,7 @@ export const httpClient = {
43
43
  throw new Error('environment variable TOGELLO_API_TOKEN is not set');
44
44
  }
45
45
  const url = `${API_BASE_URL}${path}`;
46
- const bodyString = body !== null ? JSON.stringify(body) : null;
46
+ const bodyString = body !== null ? JSON.stringify(body) : '{}';
47
47
  const response = await fetch(url, {
48
48
  method: 'PUT',
49
49
  headers: {
@@ -55,6 +55,9 @@ export const httpClient = {
55
55
  if (!response.ok) {
56
56
  throw new Error(`response status: ${response.status}`);
57
57
  }
58
+ if (response.headers.get('content-length') === '0') {
59
+ return undefined;
60
+ }
58
61
  return (await response.json());
59
62
  },
60
63
  };
@@ -3,7 +3,7 @@ export const completeActivityLogHandler = async ({ activityLogUUID }) => {
3
3
  try {
4
4
  await httpClient.putJson({
5
5
  path: `/v2/integration/activity-logs/${activityLogUUID}/work-complete`,
6
- body: null,
6
+ body: {},
7
7
  });
8
8
  return {
9
9
  content: [
@@ -1,5 +1,5 @@
1
1
  import { httpClient } from '../../client.js';
2
- export const createTaskHandler = async ({ taskName, categoryUUID, scheduledStartDate, url, }) => {
2
+ export const createTaskHandler = async ({ taskName, categoryUUID, scheduledStartDate, scheduledEndDate, url, }) => {
3
3
  try {
4
4
  await httpClient.postJson({
5
5
  path: '/v2/integration/todo',
@@ -7,6 +7,7 @@ export const createTaskHandler = async ({ taskName, categoryUUID, scheduledStart
7
7
  label: taskName,
8
8
  categoryUUID: categoryUUID,
9
9
  scheduledStartDate: scheduledStartDate,
10
+ scheduledEndDate: scheduledEndDate,
10
11
  url: url,
11
12
  },
12
13
  });
@@ -4,6 +4,10 @@ export const getTodayCalendarHandler = async () => {
4
4
  const googleEvents = await httpClient.fetchURL({
5
5
  path: '/v2/integration/google-calendar/event',
6
6
  });
7
+ const tasks = await httpClient.fetchURL({
8
+ path: '/v2/integration/todo',
9
+ });
10
+ const filteredTasks = tasks.filter((task) => task.scheduledStartDate != null);
7
11
  return {
8
12
  content: [
9
13
  {
@@ -21,6 +25,20 @@ export const getTodayCalendarHandler = async () => {
21
25
  ])
22
26
  .join(','),
23
27
  },
28
+ {
29
+ type: 'text',
30
+ text: 'en: The following is a task. The following is the order:[task name, scheduled start date, scheduled end date]',
31
+ },
32
+ {
33
+ type: 'text',
34
+ text: filteredTasks
35
+ .map((task) => [
36
+ task.label,
37
+ task.scheduledStartDate,
38
+ task.scheduledEndDate,
39
+ ])
40
+ .join(','),
41
+ },
24
42
  ],
25
43
  };
26
44
  }
package/build/index.js CHANGED
@@ -43,6 +43,10 @@ async function main() {
43
43
  .string()
44
44
  .optional()
45
45
  .describe('Scheduled start date in ISO format.'),
46
+ scheduledEndDate: z
47
+ .string()
48
+ .optional()
49
+ .describe('Scheduled end date in ISO format.'),
46
50
  url: z
47
51
  .string()
48
52
  .optional()
@@ -54,19 +58,19 @@ async function main() {
54
58
  .describe('Task UUID. Please specify the task uuid (todo uuid) obtained from get-tasks-list. You cannot use this tool without specifying it.'),
55
59
  isCompleted: z
56
60
  .boolean()
57
- .describe('You can update the completion status of the task. If true, it is completed. If false, it can be reverted to incomplete.'),
61
+ .describe('You can update the completion status of the task. If true, it is completed.'),
58
62
  scheduledStartDate: z
59
63
  .string()
60
64
  .optional()
61
- .describe('Scheduled start date in ISO format.'),
65
+ .describe('Scheduled start date in ISO format.If the user does not specify, the information obtained from get-tasks-list is passed.'),
62
66
  scheduledEndDate: z
63
67
  .string()
64
68
  .optional()
65
- .describe('Scheduled end date in ISO format.'),
69
+ .describe('Scheduled end date in ISO format.If the user does not specify, the information obtained from get-tasks-list is passed.'),
66
70
  url: z
67
71
  .string()
68
72
  .optional()
69
- .describe('Optional URL associated with the task.'),
73
+ .describe('Optional URL associated with the task.If the user does not specify, the information obtained from get-tasks-list is passed.'),
70
74
  }, updateTaskHandler);
71
75
  server.tool('get-todo-category-list', 'Retrieves the list of categories from the TODO feature. Recognizes category name / category UUID', {}, getTodoCategoryListHandler);
72
76
  server.tool('get-today-calendar', 'Retrieves scheduled events for yesterday/today/tomorrow from the linked Google Calendar. Recognizes event name / start date and time / end date and time. ', {}, getTodayCalendarHandler);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "togello-mcp-server",
4
- "version": "1.0.17",
4
+ "version": "1.0.19",
5
5
  "main": "index.js",
6
6
  "scripts": {
7
7
  "build": "tsc && chmod 755 build/index.js",