Skip to main content
Glama
jhirono

Microsoft Todo MCP Service

create-checklist-item

Add a checklist item to break down Microsoft Todo tasks into smaller, manageable steps for better organization and progress tracking.

Instructions

Create a new checklist item (subtask) for a task. Checklist items help break down a task into smaller, manageable steps.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
listIdYesID of the task list
taskIdYesID of the task
displayNameYesText content of the checklist item
isCheckedNoWhether the item is checked off

Implementation Reference

  • Registers the 'create-checklist-item' MCP tool, including its description, input schema, and handler function.
    server.tool(
      "create-checklist-item",
      "Create a new checklist item (subtask) for a task. Checklist items help break down a task into smaller, manageable steps.",
      {
        listId: z.string().describe("ID of the task list"),
        taskId: z.string().describe("ID of the task"),
        displayName: z.string().describe("Text content of the checklist item"),
        isChecked: z.boolean().optional().describe("Whether the item is checked off")
      },
      async ({ listId, taskId, displayName, isChecked }) => {
        try {
          const token = await getAccessToken();
          if (!token) {
            return {
              content: [
                {
                  type: "text",
                  text: "Failed to authenticate with Microsoft API",
                },
              ],
            };
          }
    
          // Prepare the request body
          const requestBody: any = {
            displayName
          };
    
          if (isChecked !== undefined) {
            requestBody.isChecked = isChecked;
          }
    
          // Make the API request to create the checklist item
          const response = await makeGraphRequest<ChecklistItem>(
            `${MS_GRAPH_BASE}/me/todo/lists/${listId}/tasks/${taskId}/checklistItems`,
            token,
            "POST",
            requestBody
          );
          
          if (!response) {
            return {
              content: [
                {
                  type: "text",
                  text: `Failed to create checklist item for task: ${taskId}`,
                },
              ],
            };
          }
    
          return {
            content: [
              {
                type: "text",
                text: `Checklist item created successfully!\nContent: ${response.displayName}\nID: ${response.id}`,
              },
            ],
          };
        } catch (error) {
          return {
            content: [
              {
                type: "text",
                text: `Error creating checklist item: ${error}`,
              },
            ],
          };
        }
      }
    );
  • The main handler function for the tool: authenticates via getAccessToken, constructs the request body with displayName and optional isChecked, performs a POST request to the Microsoft Graph API endpoint for checklistItems, and returns formatted success or error messages.
    async ({ listId, taskId, displayName, isChecked }) => {
      try {
        const token = await getAccessToken();
        if (!token) {
          return {
            content: [
              {
                type: "text",
                text: "Failed to authenticate with Microsoft API",
              },
            ],
          };
        }
    
        // Prepare the request body
        const requestBody: any = {
          displayName
        };
    
        if (isChecked !== undefined) {
          requestBody.isChecked = isChecked;
        }
    
        // Make the API request to create the checklist item
        const response = await makeGraphRequest<ChecklistItem>(
          `${MS_GRAPH_BASE}/me/todo/lists/${listId}/tasks/${taskId}/checklistItems`,
          token,
          "POST",
          requestBody
        );
        
        if (!response) {
          return {
            content: [
              {
                type: "text",
                text: `Failed to create checklist item for task: ${taskId}`,
              },
            ],
          };
        }
    
        return {
          content: [
            {
              type: "text",
              text: `Checklist item created successfully!\nContent: ${response.displayName}\nID: ${response.id}`,
            },
          ],
        };
      } catch (error) {
        return {
          content: [
            {
              type: "text",
              text: `Error creating checklist item: ${error}`,
            },
          ],
        };
      }
    }
  • Zod input schema defining the required parameters listId, taskId, displayName and optional isChecked for creating a checklist item.
    {
      listId: z.string().describe("ID of the task list"),
      taskId: z.string().describe("ID of the task"),
      displayName: z.string().describe("Text content of the checklist item"),
      isChecked: z.boolean().optional().describe("Whether the item is checked off")
    },
  • TypeScript interface defining the structure of a ChecklistItem, used for typing the API response in the handler.
    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?

With no annotations provided, the description carries full burden but only states it 'creates' without disclosing behavioral traits like permissions needed, whether it's idempotent, error conditions, or what happens on success/failure. It mentions checklist items help with task breakdown, but this is functional purpose, not operational behavior.

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?

Two sentences that are front-loaded with the core action and purpose. No wasted words, though the second sentence could be considered slightly explanatory rather than essential.

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

Completeness2/5

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

For a creation tool with no annotations and no output schema, the description is incomplete. It lacks behavioral details (e.g., what's returned, error handling) and usage context, relying heavily on the schema for parameters but not compensating for other gaps.

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%, so parameters are well-documented in the schema. The description adds no parameter-specific information beyond implying 'displayName' is for text content and context for 'listId' and 'taskId'. This meets the baseline for high schema coverage.

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 ('Create') and resource ('new checklist item (subtask) for a task'), with additional context about purpose ('break down a task into smaller, manageable steps'). It doesn't explicitly differentiate from siblings like 'create-task' or 'update-checklist-item', but the focus on subtasks is reasonably distinct.

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?

No explicit guidance on when to use this tool versus alternatives like 'create-task' or 'update-checklist-item'. The description implies usage for subtasks but doesn't specify prerequisites (e.g., needing an existing task) or exclusions, leaving the agent to infer context from parameter names alone.

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