Skip to main content
Glama

approve_request_completion

Confirm final completion of tasks in MCP TaskManager by approving the request. Displays task status for review; allows adding new tasks if necessary.

Instructions

After all tasks are done and approved, this tool finalizes the entire request. The user must call this to confirm that the request is fully completed.

A progress table showing the final status of all tasks will be displayed before requesting final approval.

If not approved, the user can add new tasks using 'request_planning' and continue the process.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
requestIdYes

Implementation Reference

  • The core handler function that executes the logic for approving the completion of a request. It checks if all tasks are approved, marks the request as completed, saves the data, and returns a success message with the task progress table.
    public async approveRequestCompletion(requestId: string) { const request = this.data.requests.find((r) => r.requestId === requestId); if (!request) { throw new Error("Request not found"); } if (!request.tasks.every((t) => t.approved)) { throw new Error("Not all tasks are approved yet"); } request.completed = true; await this.saveTasks(); return { message: "Request completion approved. All done!\n" + this.formatTaskProgressTable(requestId), }; }
  • Zod input schema for the approve_request_completion tool, defining the required requestId parameter.
    const ApproveRequestCompletionSchema = z.object({ requestId: z.string(), });
  • index.ts:165-169 (registration)
    Tool registration in the listTools method, specifying the name, description, and input schema for approve_request_completion.
    { name: "approve_request_completion", description: "Approve the completion of an entire request.", inputSchema: ApproveRequestCompletionSchema, },
  • Dispatcher case in the callTool method that validates input using the schema and delegates to the approveRequestCompletion handler.
    case "approve_request_completion": { const parsed = ApproveRequestCompletionSchema.safeParse(parameters); if (!parsed.success) { throw new Error(`Invalid parameters: ${parsed.error}`); } return this.approveRequestCompletion(parsed.data.requestId); }

Other Tools

Related 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/Rudra-ravi/mcp-taskmanager'

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