Skip to main content
Glama
Leanware-io

ClickUp MCP Integration

by Leanware-io

clickup_create_task

Create new tasks in ClickUp with details like name, description, priority, due dates, and assignees to organize project work.

Instructions

Create a new task in ClickUp

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesTask name
markdown_descriptionNoTask description in markdown format
list_idYesClickUp list ID
priorityNoTask priority (1-4): 1=Urgent, 2=High, 3=Normal, 4=Low
due_dateNoDue date as Unix timestamp in milliseconds
tagsNoArray of tag names to add to the task
time_estimateNoTime estimate in milliseconds
assigneesNoArray of user IDs to assign to the task
custom_fieldsNoCustom fields to set on task creation
parentNoParent task ID to create this task as a subtask

Implementation Reference

  • The MCP tool handler function that maps input parameters to CreateTaskParams and calls taskService.createTask to execute the task creation, returning the JSON response.
    handler: async (input): Promise<any> => {
      const taskParams: CreateTaskParams = {
        name: input.name,
        list_id: input.list_id,
        markdown_description: input.markdown_description,
        priority: input.priority,
        due_date: input.due_date,
        tags: input.tags,
        time_estimate: input.time_estimate,
        assignees: input.assignees,
        custom_fields: input.custom_fields,
        parent: input.parent,
      };
    
      const response = await taskService.createTask(taskParams);
      return {
        content: [{ type: "text", text: JSON.stringify(response) }],
      };
    },
  • Zod schema defining the input parameters for the clickup_create_task tool.
    inputSchema: {
      name: z.string().describe("Task name"),
      markdown_description: z
        .string()
        .optional()
        .describe("Task description in markdown format"),
      list_id: z.string().describe("ClickUp list ID"),
      priority: z
        .number()
        .optional()
        .describe("Task priority (1-4): 1=Urgent, 2=High, 3=Normal, 4=Low"),
      due_date: z
        .number()
        .optional()
        .describe("Due date as Unix timestamp in milliseconds"),
      tags: z
        .array(z.string())
        .optional()
        .describe("Array of tag names to add to the task"),
      time_estimate: z
        .number()
        .optional()
        .describe("Time estimate in milliseconds"),
      assignees: z
        .array(z.number())
        .optional()
        .describe("Array of user IDs to assign to the task"),
      custom_fields: z
        .array(
          z.object({
            id: z.string().describe("Custom field ID"),
            value: z
              .union([
                z.string(),
                z.number(),
                z.boolean(),
                z.array(z.unknown()),
                z.record(z.unknown()),
              ])
              .describe("Value for the custom field"),
          })
        )
        .optional()
        .describe("Custom fields to set on task creation"),
      parent: z
        .string()
        .optional()
        .describe("Parent task ID to create this task as a subtask"),
    },
  • src/index.ts:89-91 (registration)
    Registration of the clickup_create_task tool (along with others) to the MCP server using server.tool.
    tools.forEach((tool) => {
      server.tool(tool.name, tool.description, tool.inputSchema, tool.handler);
    });
  • The TaskService.createTask method that performs the actual HTTP POST request to the ClickUp API to create the task.
    async createTask(params: CreateTaskParams): Promise<ClickUpTask> {
      const { list_id, ...taskData } = params;
    
      return this.request<ClickUpTask>(`/list/${list_id}/task`, {
        method: "POST",
        body: JSON.stringify(taskData),
      });
    }

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/Leanware-io/clickup-mcp-server'

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