Skip to content

feat(finance): add payment-reconciliation-pro skill - #119

Open
bendaley wants to merge 4 commits into
Fluid-WeCommerce:mainfrom
bendaley:ben/payment-reconciliation
Open

feat(finance): add payment-reconciliation-pro skill#119
bendaley wants to merge 4 commits into
Fluid-WeCommerce:mainfrom
bendaley:ben/payment-reconciliation

Conversation

@bendaley

@bendaley bendaley commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Adds finance/payment-reconciliation-pro.md — a new, more powerful version of the reconciliation skill
  • Original finance/payment-reconciliation.md left intact; only change is output path /tmp~/Desktop

What's new in Pro

Multi-PSP - Stripe (with expand[]=data.charges for richer diagnostics), Braintree, dLocal, PayPal fully instrumented. PPRO/Citcon/unknown surface Fluid-side totals with a manual reconciliation note.

Root cause classification - every discrepancy classified into one of 8 named causes with severity:

  • UNRECORDED_SUCCESS (HIGH) — Stripe succeeded, no Fluid record
  • STATUS_DISAGREEMENT (HIGH) — matched by ID but statuses disagree
  • PSP_DISPUTE (HIGH) — charge disputed in Stripe
  • AMOUNT_DELTA (MEDIUM) — matched but amounts differ
  • ORPHANED_REFUND_ID (MEDIUM) — refund ID stored as transaction ID
  • GATEWAY_TIMEOUT (MEDIUM) — no PSP ID returned, likely pre-auth failure
  • PSP_DIRECT_CHARGE (LOW) — in PSP not Fluid, created outside Fluid flow
  • UNRESOLVED_DECLINE (LOW) — Fluid declined, no PSP record

Action items - numbered, severity-sorted list with specific next steps and suggested owner (Engineering / Finance / Support).

Richer HTML report - PSP coverage summary grid, action items above detail tables, collapsible per-cause tables, matched-and-clean count.

Rails fallback - explicit Path A (Rails runner) and Path B (Fluid API) so it runs without gem install.

Test plan

  • Run against a sandbox company with Stripe — confirm transaction count matches, report saves to ~/Desktop
  • Verify action items appear for each discrepancy type present
  • Verify original payment-reconciliation.md still runs correctly

🤖 Generated with Claude Code

bendaley and others added 4 commits July 31, 2026 14:09
Adds a Mist skill that reconciles Fluid's internal payment ledger against each connected PSP, gateway, and APM for a given company and timeframe. Uses Rails runner to access date-filtered transactions and decrypted credentials, then calls Stripe, Braintree, dLocal, PPRO, Citcon, and PayPal APIs directly to compare counts, amounts, and statuses. Outputs a clean terminal report and saves to file.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ent parameter

Add a required environment prompt (sandbox vs production) so the skill never silently defaults to one or the other. Threads the SANDBOX flag through the Rails runner to filter payment accounts accordingly, and updates the notes section to document the requirement.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
New skill with multi-PSP coverage, root cause classification (8 named
causes with severity), per-discrepancy action items with owner, and a
richer HTML report including a PSP summary grid and collapsible detail
tables. Original payment-reconciliation skill left intact.

Also fixes output path to ~/Desktop in the original skill.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@bendaley bendaley changed the title feat(finance): Payment Reconciliation skill feat(finance): add payment-reconciliation-pro skill Jul 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant