Skip to main content
Glama
robertn702

Sunsama MCP Server

delete-task

Remove tasks permanently from your Sunsama workspace using task IDs to maintain organized workflows and eliminate completed or unnecessary items.

Instructions

Delete a task permanently

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitResponsePayloadNoWhether to limit response size
taskIdYesThe ID of the task to delete
wasTaskMergedNoWhether the task was merged before deletion

Implementation Reference

  • The main handler function that executes the 'delete-task' tool logic by calling the client's deleteTask method and formatting the JSON response.
    export const deleteTaskTool = withTransportClient({
      name: "delete-task",
      description: "Delete a task permanently",
      parameters: deleteTaskSchema,
      execute: async (
        { taskId, limitResponsePayload, wasTaskMerged }: DeleteTaskInput,
        context: ToolContext,
      ) => {
        const result = await context.client.deleteTask(
          taskId,
          limitResponsePayload,
          wasTaskMerged,
        );
    
        return formatJsonResponse({
          success: result.success,
          taskId,
          deleted: true,
          updatedFields: result.updatedFields,
        });
      },
    });
  • Zod input schema for the 'delete-task' tool defining required taskId and optional limitResponsePayload, wasTaskMerged parameters.
    export const deleteTaskSchema = z.object({
      taskId: z.string().min(1, "Task ID is required").describe(
        "The ID of the task to delete",
      ),
      limitResponsePayload: z.boolean().optional().describe(
        "Whether to limit response size",
      ),
      wasTaskMerged: z.boolean().optional().describe(
        "Whether the task was merged before deletion",
      ),
    });
  • src/main.ts:32-44 (registration)
    Registration of all tools to the MCP server, including 'delete-task' via the allTools array imported from src/tools/index.ts.
    // Register all tools
    allTools.forEach((tool) => {
      server.registerTool(
        tool.name,
        {
          description: tool.description,
          inputSchema: "shape" in tool.parameters
            ? tool.parameters.shape
            : tool.parameters,
        },
        tool.execute,
      );
    });
  • The taskTools array that includes the deleteTaskTool, which is spread into allTools for server registration.
    export const taskTools = [
      // Query tools
      getTasksBacklogTool,
      getTasksByDayTool,
      getArchivedTasksTool,
      getTaskByIdTool,
    
      // Lifecycle tools
      createTaskTool,
      deleteTaskTool,
    
      // Update tools
      updateTaskCompleteTool,
      updateTaskSnoozeDateTool,
      updateTaskBacklogTool,
      updateTaskPlannedTimeTool,
      updateTaskNotesTool,
      updateTaskDueDateTool,
      updateTaskTextTool,
      updateTaskStreamTool,
    ];
Behavior2/5

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

With no annotations, the description carries full burden but only states it's a permanent deletion. It lacks critical behavioral details: whether deletion is irreversible, if it requires specific permissions, what happens to associated data, error conditions, or response format. For a destructive operation, this is a significant gap in transparency.

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 wasted words. It's front-loaded with the core action ('Delete a task') and adds a key modifier ('permanently'). Every word earns its place, making it easy for an agent to parse quickly.

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?

For a destructive tool with no annotations and no output schema, the description is incomplete. It doesn't address safety implications, return values, or error handling. Given the complexity of deletion (permanent data loss) and lack of structured fields, more context is needed to guide the agent effectively.

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 parameters are fully documented in the schema. The description adds no additional meaning about parameters beyond implying 'taskId' is required for deletion. It doesn't explain why 'limitResponsePayload' or 'wasTaskMerged' are relevant, leaving that to the schema. Baseline 3 is appropriate given high schema coverage.

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

Purpose4/5

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

The description clearly states the action ('Delete') and resource ('a task'), specifying it's a permanent deletion. It distinguishes from siblings like 'get-task-by-id' or 'update-task' by focusing on removal rather than retrieval or modification. However, it doesn't explicitly differentiate from potential archival tools (though none are listed as siblings).

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. It doesn't mention prerequisites (e.g., task must exist), exclusions (e.g., don't use for active tasks), or comparisons to siblings like 'get-archived-tasks' or update operations. The agent must infer usage from the 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/robertn702/mcp-sunsama'

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