whooing_delete_entry
Delete a transaction entry from Whooing using its entry ID. First find the entry ID via whooing_entries.
Instructions
Delete a transaction entry from Whooing. Use whooing_entries to find the entry_id first.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| entry_id | Yes | Entry ID to delete (from whooing_entries) | |
| section_id | No | Section ID. Defaults to WHOOING_SECTION_ID env var. |
Implementation Reference
- src/server.ts:1376-1401 (registration)Registration of the whooing_delete_entry tool with its input schema and handler via server.registerTool.
// whooing_delete_entry — Delete an entry via Whooing DELETE API server.registerTool( "whooing_delete_entry", { description: "Delete a transaction entry from Whooing. " + "Use whooing_entries to find the entry_id first.", inputSchema: { entry_id: z.number().int().describe("Entry ID to delete (from whooing_entries)"), section_id: z .string() .optional() .describe("Section ID. Defaults to WHOOING_SECTION_ID env var."), }, annotations: { readOnlyHint: false }, }, async (args) => { const sectionId = args.section_id ?? client.defaultSectionId; await client.apiDelete(`entries/${args.entry_id}/${sectionId}.json`); return { content: [{ type: "text", text: `Entry ${args.entry_id} deleted.` }], }; } ); - src/server.ts:1383-1389 (schema)Input schema for whooing_delete_entry requiring entry_id (int) and optional section_id (string).
inputSchema: { entry_id: z.number().int().describe("Entry ID to delete (from whooing_entries)"), section_id: z .string() .optional() .describe("Section ID. Defaults to WHOOING_SECTION_ID env var."), }, - src/server.ts:1392-1400 (handler)Handler that calls client.apiDelete to delete an entry via the Whooing DELETE API.
async (args) => { const sectionId = args.section_id ?? client.defaultSectionId; await client.apiDelete(`entries/${args.entry_id}/${sectionId}.json`); return { content: [{ type: "text", text: `Entry ${args.entry_id} deleted.` }], }; }