## TL;DR
amount_due is the original invoice total; amount_remaining is what is still unpaid after partial payments. After a partial payment, amount_due stays the same and amount_remaining drops. Reconcile against amount_remaining, and mark the invoice paid only when it hits zero.

```text
amount_remaining vs amount_due partial payment
```

## Use this when
- An invoice shows amount_due larger than amount_remaining after a partial payment.
- Your reconciliation code treats amount_due as the outstanding balance and double-counts.
- A customer paid part of an invoice and asks what they still owe.

## Not for this skill when
- The customer overpaid. Overpayments create credit balances, a different field set.
- The invoice total itself is wrong. That is a line-item problem.

## Steps
1. ('Read both fields on the invoice. Verify: amount_due is the original total, amount_remaining is total minus payments.', 'Sum the invoice payments and confirm they equal amount_due minus amount_remaining. Verify: the math reconciles.', 'When amount_remaining hits zero, the invoice auto-finalizes as paid. Verify: status is paid, not open.', 'Update your ledger from amount_remaining, never amount_due, for outstanding balances. Verify: no invoice is double-counted as owed.', 'If a partial payment was accidental, issue a refund or apply the remainder as credit per your policy. Verify: the customer record reflects the resolution.')

## Variant phrasings
### stripe amount_remaining amount_due difference
Field-comparison search.

### stripe invoice partial payment remaining balance
Symptom search.

### amount_due not updating after payment stripe
Confusion search.


Compatibility: Stripe Billing invoices API, all client versions. Both fields are on the invoice object.

## Why it happens
Stripe keeps amount_due as the invoice total for its lifetime, a record of what was billed, while amount_remaining tracks collection progress. Partial payments are common in B2B (deposits, split payments, wire plus card), so the invoice object needs both the original bill and the live balance. amount_due never shrinks because the bill itself did not shrink; only the unpaid remainder did.

## Edge cases / pitfalls
- Do not key dunning off amount_due. A half-paid invoice would get full-balance collection emails.
- amount_remaining can go negative on overpayments; handle that branch explicitly.
- Refunds increase amount_remaining back up. Partial refunds re-open collection.
- Your webhook handler should compare against amount_remaining when deciding invoice.paid means paid in full.

## Provenance

Resolved from the public thread: https://vectle.com/posts/pst_ip3OXGa6IaPN9MqFE9o7WA
