delete_instance
Remove a specific Tembo Cloud instance by providing the organization ID and instance ID to manage resources effectively.
Instructions
Delete an existing Tembo instance
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| instance_id | Yes | Delete this instance id | |
| org_id | Yes | Organization id of the instance to delete |
Input Schema (JSON Schema)
{
"properties": {
"instance_id": {
"description": "Delete this instance id",
"type": "string"
},
"org_id": {
"description": "Organization id of the instance to delete",
"type": "string"
}
},
"required": [
"org_id",
"instance_id"
],
"type": "object"
}
Implementation Reference
- src/tools.ts:367-383 (handler)The handler function for the 'delete_instance' tool. It extracts org_id and instance_id from the request arguments, calls temboClient.deleteInstance with the path parameters, and returns the JSON-stringified response or error.delete_instance: async (request) => { const { org_id, instance_id } = request.params.arguments as { org_id: string; instance_id: string; }; const response = await temboClient.deleteInstance({ path: { org_id, instance_id }, }); return { content: [ { type: "text", text: JSON.stringify(response.data ?? response.error, null, 2), }, ], }; },
- src/tools.ts:163-177 (schema)The tool schema definition for 'delete_instance', including name, description, and inputSchema specifying required org_id and instance_id.{ name: "delete_instance" as const, description: "Delete an existing Tembo instance", inputSchema: { type: "object", properties: { org_id: { type: "string", description: "Organization id of the instance to delete", }, instance_id: { type: "string", description: "Delete this instance id" }, }, required: ["org_id", "instance_id"], }, },
- src/index.ts:32-34 (registration)Registration of all tools (including delete_instance schema via TOOLS) for the ListToolsRequestHandler.server.setRequestHandler(ListToolsRequestSchema, () => { return { tools: TOOLS }; });
- src/index.ts:36-59 (registration)Dynamic registration of tool handlers (including delete_instance via TOOL_HANDLERS) for the CallToolRequestHandler.server.setRequestHandler( CallToolRequestSchema, async (request): Promise<z.infer<typeof CallToolResultSchema>> => { const toolName = request.params.name; try { if (isAllowedTool(toolName)) { return await TOOL_HANDLERS[toolName](request); } throw new Error(`Unknown tool: ${toolName}`); } catch (error) { return { content: [ { type: "text", text: `Error: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } }, );