Skip to main content
Glama
Leanware-io

ClickUp MCP Integration

by Leanware-io

clickup_get_task

Retrieve a specific task from ClickUp using its unique task ID to access task details and information.

Instructions

Get a task by its ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
task_idYes

Implementation Reference

  • Executes the tool logic: destructures task_id from input, calls taskService.getTask(task_id), returns response as text content.
    handler: async (input) => { const { task_id } = input; const response = await taskService.getTask(task_id); return { content: [{ type: "text", text: JSON.stringify(response) }], }; },
  • Defines the tool name, description, and input schema requiring 'task_id' as string.
    name: "clickup_get_task", description: "Get a task by its ID", inputSchema: { task_id: z.string(), },
  • Core helper method that performs the HTTP request to ClickUp API to fetch the task by ID.
    async getTask(taskId: string): Promise<ClickUpTask> { return this.request<ClickUpTask>( `/task/${taskId}?custom_task_ids=false&team_id=${this.workspaceId}&include_subtasks=true&include_markdown_description=true` ); }
  • src/index.ts:89-91 (registration)
    Registers the clickup_get_task tool (included in the tools array) to the MCP server using server.tool().
    tools.forEach((tool) => { server.tool(tool.name, tool.description, tool.inputSchema, tool.handler); });
  • Defines the tool object using defineTool utility, which is later exported and registered.
    const getTaskTool = defineTool((z) => ({ name: "clickup_get_task", description: "Get a task by its ID", inputSchema: { task_id: z.string(), }, handler: async (input) => { const { task_id } = input; const response = await taskService.getTask(task_id); return { content: [{ type: "text", text: JSON.stringify(response) }], }; }, }));

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