Skip to main content
Glama
jhirono

Microsoft Todo MCP Service

get-checklist-items

Retrieve subtasks and smaller components for a specific Microsoft Todo task to track progress and manage detailed steps.

Instructions

Get checklist items (subtasks) for a specific task. Checklist items are smaller steps or components that belong to a parent task.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
listIdYesID of the task list
taskIdYesID of the task

Implementation Reference

  • Registration of the 'get-checklist-items' MCP tool, including name, description, input schema, and inline handler function that fetches checklist items via Microsoft Graph API.
    server.tool(
      "get-checklist-items",
      "Get checklist items (subtasks) for a specific task. Checklist items are smaller steps or components that belong to a parent task.",
      {
        listId: z.string().describe("ID of the task list"),
        taskId: z.string().describe("ID of the task"),
      },
      async ({ listId, taskId }) => {
        try {
          const token = await getAccessToken();
          if (!token) {
            return {
              content: [
                {
                  type: "text",
                  text: "Failed to authenticate with Microsoft API",
                },
              ],
            };
          }
    
          // Fetch the task first to get its title
          const taskResponse = await makeGraphRequest<Task>(
            `${MS_GRAPH_BASE}/me/todo/lists/${listId}/tasks/${taskId}`,
            token
          );
          
          const taskTitle = taskResponse ? taskResponse.title : "Unknown Task";
    
          // Fetch the checklist items
          const response = await makeGraphRequest<{ value: ChecklistItem[] }>(
            `${MS_GRAPH_BASE}/me/todo/lists/${listId}/tasks/${taskId}/checklistItems`,
            token
          );
          
          if (!response) {
            return {
              content: [
                {
                  type: "text",
                  text: `Failed to retrieve checklist items for task: ${taskId}`,
                },
              ],
            };
          }
    
          const items = response.value || [];
          if (items.length === 0) {
            return {
              content: [
                {
                  type: "text",
                  text: `No checklist items found for task "${taskTitle}" (ID: ${taskId})`,
                },
              ],
            };
          }
    
          const formattedItems = items.map((item) => {
            const status = item.isChecked ? "✓" : "○";
            let itemInfo = `${status} ${item.displayName} (ID: ${item.id})`;
            
            // Add creation date if available
            if (item.createdDateTime) {
              const createdDate = new Date(item.createdDateTime).toLocaleString();
              itemInfo += `\nCreated: ${createdDate}`;
            }
            
            return itemInfo;
          });
    
          return {
            content: [
              {
                type: "text",
                text: `Checklist items for task "${taskTitle}" (ID: ${taskId}):\n\n${formattedItems.join("\n\n")}`,
              },
            ],
          };
        } catch (error) {
          return {
            content: [
              {
                type: "text",
                text: `Error fetching checklist items: ${error}`,
              },
            ],
          };
        }
      }
    );
  • Handler function that authenticates, fetches the parent task title, retrieves checklist items from Microsoft Graph API endpoint `/me/todo/lists/{listId}/tasks/{taskId}/checklistItems`, formats them with check status and creation date, and returns formatted text response.
    async ({ listId, taskId }) => {
      try {
        const token = await getAccessToken();
        if (!token) {
          return {
            content: [
              {
                type: "text",
                text: "Failed to authenticate with Microsoft API",
              },
            ],
          };
        }
    
        // Fetch the task first to get its title
        const taskResponse = await makeGraphRequest<Task>(
          `${MS_GRAPH_BASE}/me/todo/lists/${listId}/tasks/${taskId}`,
          token
        );
        
        const taskTitle = taskResponse ? taskResponse.title : "Unknown Task";
    
        // Fetch the checklist items
        const response = await makeGraphRequest<{ value: ChecklistItem[] }>(
          `${MS_GRAPH_BASE}/me/todo/lists/${listId}/tasks/${taskId}/checklistItems`,
          token
        );
        
        if (!response) {
          return {
            content: [
              {
                type: "text",
                text: `Failed to retrieve checklist items for task: ${taskId}`,
              },
            ],
          };
        }
    
        const items = response.value || [];
        if (items.length === 0) {
          return {
            content: [
              {
                type: "text",
                text: `No checklist items found for task "${taskTitle}" (ID: ${taskId})`,
              },
            ],
          };
        }
    
        const formattedItems = items.map((item) => {
          const status = item.isChecked ? "✓" : "○";
          let itemInfo = `${status} ${item.displayName} (ID: ${item.id})`;
          
          // Add creation date if available
          if (item.createdDateTime) {
            const createdDate = new Date(item.createdDateTime).toLocaleString();
            itemInfo += `\nCreated: ${createdDate}`;
          }
          
          return itemInfo;
        });
    
        return {
          content: [
            {
              type: "text",
              text: `Checklist items for task "${taskTitle}" (ID: ${taskId}):\n\n${formattedItems.join("\n\n")}`,
            },
          ],
        };
      } catch (error) {
        return {
          content: [
            {
              type: "text",
              text: `Error fetching checklist items: ${error}`,
            },
          ],
        };
      }
    }
  • Zod input schema defining required parameters: listId (task list ID) and taskId (task ID).
    {
      listId: z.string().describe("ID of the task list"),
      taskId: z.string().describe("ID of the task"),
    },
  • TypeScript interface defining the structure of a ChecklistItem used in the tool's response typing.
    interface ChecklistItem {
      id: string;
      displayName: string;
      isChecked: boolean;
      createdDateTime?: string;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden. It describes what the tool does (retrieves checklist items) but lacks behavioral details: it doesn't specify if this is a read-only operation, what permissions are needed, how results are returned (e.g., pagination, format), or error handling. For a retrieval tool with zero annotation coverage, this is a significant gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two concise sentences that efficiently state the purpose and clarify what checklist items are. It's front-loaded with the main action and avoids unnecessary details. However, it could be slightly more structured by explicitly mentioning parameters or usage context.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity (2 required parameters, no output schema), the description is minimally adequate. It covers the basic purpose but lacks completeness in behavioral aspects (e.g., return format, error cases) and usage guidelines. With no annotations and no output schema, it should do more to compensate, but the simplicity keeps it at a baseline level.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, with clear descriptions for listId and taskId. The description adds minimal value beyond the schema by clarifying that checklist items belong to a 'specific task', reinforcing the parameter roles. Since the schema already documents parameters well, the baseline is 3, and the description doesn't add significant extra meaning.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Get' and the resource 'checklist items (subtasks)', specifying they belong to a parent task. It distinguishes checklist items as subtasks, which helps differentiate from sibling tools like get-tasks or get-task-lists. However, it doesn't explicitly contrast with create-checklist-item or update-checklist-item, keeping it at 4 instead of 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing listId and taskId), exclusions, or comparisons to sibling tools like get-tasks (which might return tasks without checklist details). Usage is implied from the purpose but lacks explicit context.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jhirono/todoMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server