create_folderless_list
Create a new list in a ClickUp space without placing it in a folder. Provide the space ID and list name.
Instructions
Create a new list directly in a ClickUp space without placing it in a folder.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| space_id | Yes | The ID of the space to create the folderless list in | |
| name | Yes | The name of the folderless list |
Implementation Reference
- src/tools/task-tools.ts:338-350 (handler)The handler function that executes the create_folderless_list tool logic. It calls listsClient.createFolderlessList with space_id and name, returning the result or an error.
async ({ space_id, name }) => { try { const result = await listsClient.createFolderlessList(space_id, { name }); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }] }; } catch (error: any) { console.error('Error creating folderless list:', error); return { content: [{ type: 'text', text: `Error creating folderless list: ${error.message}` }], isError: true }; } - src/tools/task-tools.ts:331-337 (schema)The tool registration with Zod schema defining the input parameters: space_id (string) and name (string).
server.tool( 'create_folderless_list', 'Create a new list directly in a ClickUp space without placing it in a folder.', { space_id: z.string().describe('The ID of the space to create the folderless list in'), name: z.string().describe('The name of the folderless list') }, - src/tools/task-tools.ts:331-351 (registration)Registration of the create_folderless_list tool via server.tool(), including its schema and handler.
server.tool( 'create_folderless_list', 'Create a new list directly in a ClickUp space without placing it in a folder.', { space_id: z.string().describe('The ID of the space to create the folderless list in'), name: z.string().describe('The name of the folderless list') }, async ({ space_id, name }) => { try { const result = await listsClient.createFolderlessList(space_id, { name }); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }] }; } catch (error: any) { console.error('Error creating folderless list:', error); return { content: [{ type: 'text', text: `Error creating folderless list: ${error.message}` }], isError: true }; } } - src/clickup-client/lists.ts:60-68 (helper)The ListsClient.createFolderlessList helper method that makes the actual API POST request to /space/{spaceId}/list.
/** * Create a new folderless list in a space * @param spaceId The ID of the space to create the list in * @param params The list parameters * @returns The created list */ async createFolderlessList(spaceId: string, params: CreateListParams): Promise<List> { return this.client.post(`/space/${spaceId}/list`, params); } - src/clickup-client/lists.ts:13-16 (helper)The CreateListParams interface used as the params type for the createFolderlessList method.
export interface CreateListParams { name: string; // ...other parameters for creating a list... }