confirm_match
Confirm a proposed match between a receipt and a transaction to finalize financial reconciliation. This action completes the matching process and counts toward plan usage.
Instructions
Confirm match. Confirm a proposed match between a receipt and transaction. This action is billable and counts toward your plan usage.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Match ID |
Implementation Reference
- src/tools.js:253-256 (handler)Handler function that calls client.confirmMatch(args.id) to confirm a proposed match between a receipt and transaction.
case "confirm_match": { await client.confirmMatch(args.id); return `Match ${args.id} confirmed successfully.`; } - src/tools.js:110-121 (schema)Schema definition for confirm_match tool: requires a string 'id' parameter (Match ID to confirm).
name: "confirm_match", description: "Confirm a proposed match between a receipt and transaction. This links them together permanently.", inputSchema: { type: "object", properties: { id: { type: "string", description: "Match ID to confirm", }, }, required: ["id"], }, - src/tools.js:1-205 (registration)The tool is registered as part of the exported 'tools' array in src/tools.js, listed alongside other tools like list_matches and reject_match.
export const tools = [ { name: "list_receipts", description: "List receipts with optional filtering. Use this to find receipts by vendor name, date range, or match status.", inputSchema: { type: "object", properties: { search: { type: "string", description: "Search by vendor name", }, status: { type: "string", enum: ["all", "matched", "unmatched", "hidden"], description: "Filter by match status", }, limit: { type: "number", description: "Max results to return (default 20)", }, }, }, }, { name: "get_receipt", description: "Get detailed information about a specific receipt including line items and matched transaction.", inputSchema: { type: "object", properties: { id: { type: "string", description: "Receipt ID (e.g., rcpt_01abc123)", }, }, required: ["id"], }, }, { name: "list_transactions", description: "List bank transactions with optional filtering. Use this to find transactions by description or match status.", inputSchema: { type: "object", properties: { search: { type: "string", description: "Search by transaction description", }, status: { type: "string", enum: ["all", "matched", "unmatched", "hidden"], description: "Filter by match status", }, statementId: { type: "string", description: "Filter by bank statement ID", }, limit: { type: "number", description: "Max results to return (default 20)", }, }, }, }, { name: "get_transaction", description: "Get detailed information about a specific bank transaction.", inputSchema: { type: "object", properties: { id: { type: "string", description: "Transaction ID (e.g., btxn_01abc123)", }, }, required: ["id"], }, }, { name: "list_statements", description: "List uploaded bank statements.", inputSchema: { type: "object", properties: { limit: { type: "number", description: "Max results to return (default 20)", }, }, }, }, { name: "list_matches", description: "List proposed matches between receipts and transactions. Use this to review matches that need confirmation.", inputSchema: { type: "object", properties: { status: { type: "string", enum: ["proposed", "confirmed", "rejected"], description: "Filter by match status (default: proposed)", }, limit: { type: "number", description: "Max results to return (default 20)", }, }, }, }, { name: "confirm_match", description: "Confirm a proposed match between a receipt and transaction. This links them together permanently.", inputSchema: { type: "object", properties: { id: { type: "string", description: "Match ID to confirm", }, }, required: ["id"], }, }, { name: "reject_match", description: "Reject a proposed match. The receipt and transaction will not be suggested as a match again.", inputSchema: { type: "object", properties: { id: { type: "string", description: "Match ID to reject", }, reason: { type: "string", description: "Optional reason for rejection", }, }, required: ["id"], }, }, { name: "spending_summary", description: "Get spending summary with flexible grouping. Use this to answer questions like 'How much did I spend this month?' or 'What are my expenses by vendor?'", inputSchema: { type: "object", properties: { groupBy: { type: "string", enum: ["total", "vendor", "month", "week", "day"], description: "How to group the spending data (default: total)", }, dateFrom: { type: "string", description: "Start date (YYYY-MM-DD)", }, dateTo: { type: "string", description: "End date (YYYY-MM-DD)", }, vendorId: { type: "string", description: "Filter by specific vendor ID", }, limit: { type: "number", description: "Max results for grouped queries (default 20)", }, }, }, }, { name: "top_vendors", description: "Get top vendors ranked by total spending. Use this to answer 'Who are my biggest vendors?' or 'Where do I spend the most?'", inputSchema: { type: "object", properties: { limit: { type: "number", description: "Number of vendors to return (default 10)", }, }, }, }, { name: "spending_trends", description: "Get monthly spending trends over time. Use this to answer 'How has my spending changed?' or 'Show me spending trends'", inputSchema: { type: "object", properties: { months: { type: "number", description: "Number of months to include (default 6)", }, }, }, }, { name: "unmatched_summary", description: "Get a summary of items needing attention: unmatched receipts, transactions without receipts, and proposed matches to review. Use this for 'What needs my attention?' or 'Do I have unmatched expenses?'", inputSchema: { type: "object", properties: {}, }, }, ]; - src/client.js:84-86 (helper)Client helper method that sends a POST request to /api/matches/{id}/confirm to execute the actual API call.
async confirmMatch(id) { return request("POST", `/api/matches/${id}/confirm`); }, - src/index.js:266-267 (registration)Response formatting in the dynamic OpenAPI-based handler in src/index.js, used when tools are fetched from the OpenAPI spec at runtime.
case "confirm_match": return "Match confirmed successfully.";