Budget Pipeline
A personal data pipeline that pulls my bank and card activity every morning, itemizes my Amazon charges from the order history I export, cleans it all into tested tables and turns it into a private dashboard. I built it the way I’d build a production pipeline: layered, tested, scheduled and safe to rerun.
The dashboard, with made-up dataWhy I built it
Shopping is my most expensive hobby, and budgeting apps only told me half the story. My bank shows every Amazon order as one total, so I couldn’t tell skincare from cables. I wanted to see exactly where my money goes, set limits I’d keep, and plan bigger things, like how different rents would change when I could retire. So I replaced my budgeting app with a pipeline of my own. It costs about $15 a year: that’s SimpleFIN, the service that connects to my banks. MotherDuck, GitHub Actions and Cloudflare all run on their free plans.
Why SimpleFIN is safe to use: it only reads. It shares balances, transactions and account names, and it has no way to move money. My bank logins never touch SimpleFIN or my code: the banks are connected through MX, the financial data company that handles the logins. My pipeline holds a single access key, kept as an encrypted secret, and I can cut it off at any time by deleting the connection in SimpleFIN.
How the data flows
Data is loaded first and transformed inside the warehouse (ELT), the same pattern I use at work.
Where the data comes from
Banks, cards and brokerages (SimpleFIN)Amazon order history exportWhere it shows up
Private dashboard, behind a loginGoals and cash-flow forecastRetirement projectionsCategory fixes I make on the dashboard are saved to a small cloud database and folded into the next build.
Runs every morning on a schedule. If any of the 95 data checks fails, nothing is published.
Pulls bank and card data every morningBank, card and investment activity arrives on its own each day, with no laptop involved.
A GitHub Actions schedule runs a Prefect flow at dawn. The bank aggregator allows about 24 requests a day, so each run makes exactly one, covering the last week, and never retries a refusal. Every file is logged with a checksum, so rerunning a day can’t create duplicates.
GitHub Actions, Prefect, Python, SimpleFIN
Keeps the raw data exactly as it arrivedEverything lands untouched first, and gets cleaned up afterwards.
Raw tables hold each bank response and Amazon export exactly as it was sent. If I fix how something is parsed, I rebuild from raw instead of asking the banks again, and history comes along for free. When I moved the warehouse to MotherDuck, only the raw tables had to travel (as Parquet files); everything else was rebuilt from them.
DuckDB, MotherDuck, Parquet, SQL
Splits Amazon charges into the items I boughtMy card shows one Amazon total. The pipeline shows the serum, the cable and the lamp.
Amazon’s order history export is matched to card charges by date and amount, the charge is shared out across the items, and returned items are taken off. Amazon renamed its export columns partway through, so staging reads both versions.
dbt, SQL
Sorts every transaction into a categoryRules do most of the work, and I can fix anything right from the dashboard.
Categories come from pattern rules kept in version control, with priorities and one-off overrides. A fix I make on the live dashboard is saved to a small cloud database and merged over the rules on the next build, so it reaches every report. A broken pattern is skipped instead of breaking the build.
dbt seeds, Cloudflare D1
Tests the data before anything is published95 checks run on every build. If one fails, nothing goes out.
dbt tests cover uniqueness, missing values, relationships between tables, allowed categories and custom rules like one balance per account per day. The deploy step also refuses to upload unless the site is still behind its login, for both the main address and the preview links.
dbt tests, Cloudflare Access
Turns it into answers I actually useWhat did I spend this week? Can I afford this before payday? When could I retire?
The dashboard shows spending by week and month, a spending calendar, card due dates and a 90-day cash-flow forecast, savings and spending goals, retirement projections under different rent and lifestyle choices, and a look back at the year’s biggest purchases: were they worth it?
JavaScript, HTML, CSS, Cloudflare Pages
Keeps my financial data privateThe real dashboard sits behind a login, and real numbers never touch the code repository.
Secrets live in GitHub’s encrypted settings and a local file that isn’t committed. The demo runs the same pipeline on a made-up person generated from a fixed seed, so nothing real is ever public.
Cloudflare Access, GitHub secrets
Try it with made-up data
The demo is the real dashboard, built by the same pipeline and tests, for a made-up person paid weekly, renting, with two cards and a long weekend in Portland. Click a category, fix a transaction, add a goal or compare rents in the retirement page. Nothing is saved, and none of it is mine.
Open the demoIf you know AWS
I picked these for their free tiers, but each one has a familiar AWS counterpart. The design would carry over piece for piece.
| What I use | What it does here | Closest AWS service |
|---|---|---|
| Cloudflare Pages | hosts the dashboard | S3 + CloudFront |
| Cloudflare Pages Functions | small server code: settings, rule edits | Lambda behind API Gateway |
| Cloudflare D1 | small serverless SQL database | DynamoDB or Aurora Serverless |
| Cloudflare Access | login in front of the site | Cognito or IAM Identity Center |
| GitHub Actions schedule | runs the pipeline every morning | EventBridge Scheduler + a Fargate task |
| Prefect | orders the steps, with retries | Step Functions or MWAA (Airflow) |
| MotherDuck | the cloud warehouse | Redshift Serverless, or Athena over S3 |
| GitHub secrets | keys and tokens | Secrets Manager |
Decisions worth explaining
- DuckDB, then MotherDuck. A personal dataset is megabytes. DuckDB ran it locally for free while I built, and MotherDuck hosts the same database in the cloud without rewriting a single dbt model.
- ELT instead of ETL. Raw data is kept as sent, so a parsing fix replays over all of history without calling the banks again, which matters when the source only allows about 24 requests a day.
- Rule fixes in a database, not a code change. Fixing a category from my phone shouldn’t need a commit. Edits are stored in Cloudflare D1, applied on screen right away, and merged over the version-controlled rules at build time.
- A check before every deploy. The upload step confirms the site is still behind its login, including preview copies, before it publishes real numbers.
- Synthetic data first. A seeded generator produces the same made-up records every run, which made tests and rerun checks repeatable before any real account was connected, and now powers the demo.
Where it stands
- Done Daily cloud run: SimpleFIN → MotherDuck → dbt (95 tests) → Cloudflare, with a login and a pre-deploy check.
- Done Itemized Amazon spending, category rules editable from the dashboard, goals, forecasts and retirement projections.
- Next Notes on transactions, and a monthly budget for each category.
Contact
Michelle Lee · hello@michulee.com · Privacy policy