Skip to main content
Glama

create_list

Create a new list directly in a ClickUp space by providing a name and either space ID or space name, enabling workspace organization without folder structure.

Instructions

Create a new list directly in a ClickUp space (not in a folder). You MUST provide either spaceId or spaceName. For creating lists inside folders, use create_list_in_folder instead.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesName of the list
spaceIdNoID of the space to create the list in. Use this instead of spaceName if you have the ID.
spaceNameNoName of the space to create the list in. Alternative to spaceId - one of them MUST be provided.
contentNoDescription or content of the list
dueDateNoDue date for the list (Unix timestamp in milliseconds)
priorityNoPriority level: 1 (urgent), 2 (high), 3 (normal), 4 (low)
assigneeNoUser ID to assign the list to
statusNoStatus of the list

Implementation Reference

  • Executes the 'create_list' tool: validates input, resolves space ID, creates list using listService.createList, returns formatted response.
    export async function handleCreateList(parameters: any) { const { name, spaceId, spaceName, content, dueDate, priority, assignee, status } = parameters; // Validate required fields if (!name) { throw new Error("List name is required"); } let targetSpaceId = spaceId; // If no spaceId but spaceName is provided, look up the space ID if (!targetSpaceId && spaceName) { const spaceIdResult = await workspaceService.findSpaceIDByName(spaceName); if (!spaceIdResult) { throw new Error(`Space "${spaceName}" not found`); } targetSpaceId = spaceIdResult; } if (!targetSpaceId) { throw new Error("Either spaceId or spaceName must be provided"); } // Prepare list data const listData: CreateListData = { name }; // Add optional fields if provided if (content) listData.content = content; if (dueDate) listData.due_date = parseInt(dueDate); if (priority) listData.priority = priority; if (assignee) listData.assignee = assignee; if (status) listData.status = status; try { // Create the list const newList = await listService.createList(targetSpaceId, listData); return { content: [{ type: "text", text: JSON.stringify( { id: newList.id, name: newList.name, content: newList.content, space: { id: newList.space.id, name: newList.space.name }, message: `List "${newList.name}" created successfully` }, null, 2 ) }] }; } catch (error: any) { throw new Error(`Failed to create list: ${error.message}`); } }
  • Defines the 'create_list' tool schema including input parameters validation (name required, spaceId or spaceName, optional content, dueDate, etc.).
    export const createListTool = { name: "create_list", description: "Create a new list directly in a ClickUp space (not in a folder). You MUST provide either spaceId or spaceName. For creating lists inside folders, use create_list_in_folder instead.", inputSchema: { type: "object", properties: { name: { type: "string", description: "Name of the list" }, spaceId: { type: "string", description: "ID of the space to create the list in. Use this instead of spaceName if you have the ID." }, spaceName: { type: "string", description: "Name of the space to create the list in. Alternative to spaceId - one of them MUST be provided." }, content: { type: "string", description: "Description or content of the list" }, dueDate: { type: "string", description: "Due date for the list (Unix timestamp in milliseconds)" }, priority: { type: "number", description: "Priority level: 1 (urgent), 2 (high), 3 (normal), 4 (low)" }, assignee: { type: "number", description: "User ID to assign the list to" }, status: { type: "string", description: "Status of the list" } }, required: ["name"] } };
  • src/server.ts:67-93 (registration)
    Registers 'create_list' tool (via createListTool) in the list returned for ListToolsRequest.
    server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools: [ workspaceHierarchyTool, createTaskTool, getTaskTool, getTasksTool, updateTaskTool, moveTaskTool, duplicateTaskTool, deleteTaskTool, createBulkTasksTool, updateBulkTasksTool, moveBulkTasksTool, deleteBulkTasksTool, createListTool, createListInFolderTool, getListTool, updateListTool, deleteListTool, createFolderTool, getFolderTool, updateFolderTool, deleteFolderTool ] }; });
  • src/server.ts:124-127 (registration)
    Routes calls to 'create_list' tool to the handleCreateList handler function.
    case "create_list": return handleCreateList(params); case "create_list_in_folder": return handleCreateListInFolder(params);
  • src/server.ts:25-29 (registration)
    Imports the createListTool definition and handleCreateList handler from list.ts.
    createListTool, handleCreateList, createListInFolderTool, handleCreateListInFolder, getListTool, handleGetList, updateListTool, handleUpdateList, deleteListTool, handleDeleteList

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

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