update_list
Rename a ClickUp list by providing its ID and the new name.
Instructions
Update an existing ClickUp list's name.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| list_id | Yes | The ID of the list to update | |
| name | Yes | The new name of the list |
Implementation Reference
- src/tools/task-tools.ts:376-397 (handler)The 'update_list' tool handler registered on the McpServer. It accepts list_id and name as input (Zod-validated), calls listsClient.updateList(), and returns the result as JSON text. Error handling is included.
server.tool( 'update_list', 'Update an existing ClickUp list\'s name.', { list_id: z.string().describe('The ID of the list to update'), name: z.string().describe('The new name of the list') }, async ({ list_id, name }) => { try { const result = await listsClient.updateList(list_id, { name }); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }] }; } catch (error: any) { console.error('Error updating list:', error); return { content: [{ type: 'text', text: `Error updating list: ${error.message}` }], isError: true }; } } ); - src/clickup-client/lists.ts:85-87 (helper)The ListsClient.updateList() method that makes an HTTP PUT request to /list/{listId} with the update params.
async updateList(listId: string, params: UpdateListParams): Promise<List> { return this.client.put(`/list/${listId}`, params); } - src/clickup-client/lists.ts:18-21 (schema)The UpdateListParams interface defining the shape of the update parameters (name is optional).
export interface UpdateListParams { name?: string; // ...other parameters for updating a list... } - src/tools/task-tools.ts:379-382 (schema)The Zod schema for the 'update_list' tool defining the required input fields: list_id (string) and name (string).
{ list_id: z.string().describe('The ID of the list to update'), name: z.string().describe('The new name of the list') }, - src/tools/task-tools.ts:16-16 (registration)The setupTaskTools function that registers all tools (including 'update_list') on the McpServer.
export function setupTaskTools(server: McpServer): void {