Skip to main content
Glama
DiversioTeam

ClickUp MCP Server

by DiversioTeam

create_task_from_template

Create ClickUp tasks using predefined templates to standardize workflows and reduce manual setup time. Customize templates with specific details and assign them to project lists.

Instructions

Create a task from a template

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
template_nameYesTemplate name
customizationsNoCustomizations to apply to template
list_idYesList ID for the new task

Implementation Reference

  • Implements the core logic for creating a task from predefined templates (bug_report, feature_request, code_review), applying customizations, and using the ClickUpClient to create the task.
    async def create_task_from_template(
        self,
        template_name: str,
        list_id: str,
        customizations: Optional[Dict[str, Any]] = None,
    ) -> Dict[str, Any]:
        """Create a task from a template."""
        # Define common templates
        templates = {
            "bug_report": {
                "name": "Bug Report: {title}",
                "description": "## Description\n\n## Steps to Reproduce\n1. \n2. \n3. \n\n## Expected Behavior\n\n## Actual Behavior\n\n## Environment\n",
                "priority": 2,
                "tags": ["bug"],
            },
            "feature_request": {
                "name": "Feature: {title}",
                "description": "## Feature Description\n\n## User Story\nAs a [user type], I want [goal] so that [benefit].\n\n## Acceptance Criteria\n- [ ] \n- [ ] \n\n## Technical Notes\n",
                "priority": 3,
                "tags": ["feature"],
            },
            "code_review": {
                "name": "Code Review: {title}",
                "description": "## PR Link\n\n## Changes Summary\n\n## Checklist\n- [ ] Code follows style guidelines\n- [ ] Tests added/updated\n- [ ] Documentation updated\n- [ ] No console errors\n",
                "priority": 2,
                "tags": ["review"],
            },
        }
    
        template = templates.get(template_name)
        if not template:
            return {"error": f"Template '{template_name}' not found"}
    
        # Apply customizations
        task_data = template.copy()
        if customizations:
            task_data["name"] = task_data["name"].format(**customizations)
            task_data.update(customizations)
    
        # Create task
        task_request = CreateTaskRequest(
            name=task_data["name"],
            description=task_data.get("description"),
            priority=task_data.get("priority"),
            tags=task_data.get("tags"),
        )
    
        task = await self.client.create_task(list_id, task_request)
    
        return {
            "id": task.id,
            "name": task.name,
            "template": template_name,
            "url": format_task_url(task.id),
        }
  • Defines the input schema and metadata for the create_task_from_template tool.
        name="create_task_from_template",
        description="Create a task from a template",
        inputSchema={
            "type": "object",
            "properties": {
                "template_name": {"type": "string", "description": "Template name"},
                "customizations": {
                    "type": "object",
                    "description": "Customizations to apply to template",
                },
                "list_id": {"type": "string", "description": "List ID for the new task"},
            },
            "required": ["template_name", "list_id"],
        },
    ),
  • Registers the create_task_from_template tool in the ClickUpTools class's _tools dictionary, mapping the tool name to its handler method.
    self._tools: Dict[str, Callable] = {
        "create_task": self.create_task,
        "get_task": self.get_task,
        "update_task": self.update_task,
        "delete_task": self.delete_task,
        "list_tasks": self.list_tasks,
        "search_tasks": self.search_tasks,
        "get_subtasks": self.get_subtasks,
        "get_task_comments": self.get_task_comments,
        "create_task_comment": self.create_task_comment,
        "get_task_status": self.get_task_status,
        "update_task_status": self.update_task_status,
        "get_assignees": self.get_assignees,
        "assign_task": self.assign_task,
        "list_spaces": self.list_spaces,
        "list_folders": self.list_folders,
        "list_lists": self.list_lists,
        "find_list_by_name": self.find_list_by_name,
        # Bulk operations
        "bulk_update_tasks": self.bulk_update_tasks,
        "bulk_move_tasks": self.bulk_move_tasks,
        # Time tracking
        "get_time_tracked": self.get_time_tracked,
        "log_time": self.log_time,
        # Templates
        "create_task_from_template": self.create_task_from_template,
        "create_task_chain": self.create_task_chain,
        # Analytics
        "get_team_workload": self.get_team_workload,
        "get_task_analytics": self.get_task_analytics,
        # User management
        "list_users": self.list_users,
        "get_current_user": self.get_current_user,
        "find_user_by_name": self.find_user_by_name,
    }
  • Registers the MCP list_tools handler which returns definitions including create_task_from_template via ClickUpTools.get_tool_definitions().
    @self.server.list_tools()
    async def list_tools() -> List[Tool]:
        """List all available tools."""
        return self.tools.get_tool_definitions()
  • Registers the MCP call_tool handler which dispatches to ClickUpTools.call_tool, enabling execution of create_task_from_template.
    @self.server.call_tool()
    async def call_tool(
        name: str, arguments: Optional[Dict[str, Any]] = None
    ) -> List[TextContent | ImageContent | EmbeddedResource]:
        """Call a specific tool."""
        logger.debug(f"Calling tool: {name} with arguments: {arguments}")
    
        try:
            result = await self.tools.call_tool(name, arguments or {})
            return [TextContent(type="text", text=result)]
        except Exception as e:
            logger.error(f"Error calling tool {name}: {e}", exc_info=True)
            return [TextContent(type="text", text=f"Error: {e!s}")]
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It states 'create' which implies a write operation, but doesn't disclose behavioral traits such as permissions needed, whether it's idempotent, error handling, or what the output looks like. This is inadequate for a mutation tool with zero annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with zero waste. It's appropriately sized and front-loaded, making it easy to parse quickly without unnecessary elaboration.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given this is a mutation tool with no annotations and no output schema, the description is incomplete. It doesn't explain what happens after creation, error conditions, or how it differs from similar tools. For a tool that creates tasks, more context is needed to guide effective use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all three parameters. The description adds no meaning beyond what's in the schema—it doesn't explain how 'template_name' relates to available templates, what 'customizations' can include, or how 'list_id' is used. Baseline 3 is appropriate as the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Create a task from a template' clearly states the verb ('create') and resource ('task'), but it's vague about what 'from a template' entails and doesn't distinguish this tool from its sibling 'create_task'. It's better than a tautology but lacks specificity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'create_task' or 'create_task_chain'. There's no mention of prerequisites, context, or exclusions, leaving the agent to infer usage from the tool name alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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

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