clickup_get_task_by_custom_id
Retrieve a specific ClickUp task using its custom identifier to access task details and manage workflow items efficiently.
Instructions
Get a task by its custom ID
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| custom_id | Yes |
Implementation Reference
- src/controllers/task.controller.ts:44-50 (handler)The MCP tool handler function that extracts the custom_id from input, calls the task service method, and returns the response as JSON text.handler: async (input) => { const { custom_id } = input; const response = await taskService.getTaskByCustomId(custom_id); return { content: [{ type: "text", text: JSON.stringify(response) }], }; },
- Zod input schema defining the required 'custom_id' parameter as a string.inputSchema: { custom_id: z.string(), },
- src/index.ts:89-91 (registration)Registration of the tool (along with others) to the MCP server via server.tool call in a loop over the tools array.tools.forEach((tool) => { server.tool(tool.name, tool.description, tool.inputSchema, tool.handler); });
- src/services/task.service.ts:40-44 (helper)Helper service method that performs the actual ClickUp API GET request for a task by its custom ID.async getTaskByCustomId(customId: string): Promise<ClickUpTask> { return this.request<ClickUpTask>( `/task/${customId}?custom_task_ids=true&team_id=${this.workspaceId}&include_subtasks=true&include_markdown_description=true` ); }