Mark Invoice Paid
invoice_mark_paidRecord a payment against an invoice, updating the amount paid and remaining balance, and mark the invoice as paid when fully settled.
Instructions
Record a full or partial payment against an invoice. Updates amount_paid and amount_due; sets status="paid" only when the outstanding balance reaches zero. As a side effect, a fully-paid invoice updates the client payment_history (total_revenue, paid_invoices, avg_days_to_payment, late_payment_count) which invoice_risk then uses for future predictions. Returns a confirmation with the paid amount and remaining balance.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| amount | No | Amount paid in invoice currency; omit to settle the full remaining balance | |
| invoice_id | Yes | UUID of the invoice to update | |
| payment_method | No | How the payment was received (stripe|paypal|bank_transfer|credit_card|cash|check|crypto|other) |