Overview
RefundLedger is a finance-first Shopify application for understanding refund leakage at SKU level. It turns order, refund, shipping, tax, and return records into a dashboard that shows which products are creating repeated losses and how confident each calculation is.
It is deliberately read-only. RefundLedger does not process refunds, run a returns portal, or act as an accounting system.
The problem
A store can know its total refunded amount and still fail to see the operational pattern behind it. Shipping refunds, partial quantities, taxes, and incomplete line-item mappings make it difficult to answer a more useful question: which SKUs are repeatedly damaging margin?
Product approach
The app normalizes Shopify data into a refund ledger and derives SKU-level metrics such as units sold, units refunded, refund rate, net sales, and estimated leakage.
The product includes:
- finance-oriented dashboard KPIs and trends;
- top-leaking SKU identification;
- filterable SKU and refund ledgers;
- per-SKU detail with confidence levels;
- CSV exports and weekly refund-loss email summaries;
- incremental synchronization through webhooks, queues, and scheduled jobs.
Privacy and reliability
RefundLedger does not intentionally store customer names, email addresses, phone numbers, addresses, or IP addresses. Its database is limited to the order, product, variant, SKU, amount, tax, status, and timestamp fields required for the analysis.
Queue jobs are designed for at-least-once delivery and are made idempotent. Large syncs can continue from saved cursors, and failed work is isolated in a dead-letter queue instead of blocking the live application.
Architecture
The embedded Shopify interface uses React Router and Shopify App Bridge. Two Cloudflare Workers separate interactive web traffic from queue and scheduled work. D1 stores sessions and normalized commerce data, while Cloudflare Queues coordinate synchronization and report generation.
My role
I defined the product and financial metrics, designed the no-PII data boundary, implemented the Shopify synchronization pipeline, dashboard, export system, billing gates, and Cloudflare deployment architecture.
Current status
RefundLedger is a private beta. Its repository remains private while Shopify review requirements, protected data permissions, and the first merchant validation cycle are completed.