Building with Stripe Data Pipeline and the Neon backend
Stripe Data Pipeline's real-time sync streams Stripe objects into Postgres tables within seconds, which lets apps drop webhooks entirely: they write to Stripe's API and read charges, prices and promotion codes from synced stripe.* tables. Two example apps compute credit balances as a SQL view (purchased minus spent), so refunds, disputes and duplicate deliveries are handled without handler code. Double spending is prevented by a per-user advisory lock plus a conditional UPDATE that claims a job only if the view shows enough balance. Neon point-in-time branches copy Stripe data, app data, object storage and disabled triggers, so billing bugs can be reproduced and fixed locally without touching production.
Related posts
- Stripe-To-Postgres Sync Engine as standalone Library
Supabase mediumAdeptSupabase's stripe-sync-engine, a webhook listener that normalizes Stripe events into relational Postgres tables, is now published as the npm package @supabase/stripe-sync-engine instead of only a Docker image. It can run in Node.js, Express or Supabase Edge Functions via a StripeSync class whose processWebhook method takes the raw body and signature. Schema migrations should be run separately with runMigrations or folded into the regular migration workflow, after which incoming webhooks populate a stripe schema. Keeping Stripe data local avoids API round-trips and enables joins for billing dashboards, fraud checks and dunning workflows.
- Sync Stripe Data to Your Supabase Database in One Click
Supabase mediumAdeptSupabase now offers a one-click Stripe Sync Engine integration that copies Stripe customers, subscriptions, invoices and payments into real Postgres tables, kept current via webhooks plus scheduled backfills run through pgmq-based Supabase Queues and Edge Functions with retries. Unlike the existing Stripe Foreign Data Wrapper, which translates each query into Stripe API calls and slows down or hits rate limits on joins and aggregations, the sync engine lets queries run against local indexed data. Example SQL shows finding unconverted signups, computing MRR by plan, and spotting inactive paying accounts. Stripe contributed JSONB storage with generated columns, cursor-based incremental sync, Connect multi-account support and a CLI to the open-source engine.
- Practical Guide to Database Branching
Neon mediumAdept
Neon's copy-on-write storage makes Postgres database branches instant and cheap: each branch shares the parent's base data, gets its own autoscaling compute that scales to zero, and can be created from any point within the history retention window. Recommended workflows include a protected production branch whose child branches get new credentials automatically, staging and per-developer or per-pull-request branches that are periodically reset from the parent, and anonymized branches (beta) as the parent when data contains PII. Point-in-time branches support recovering dropped tables, debugging bad migrations and audits without rolling back production. Ephemeral branches should be deleted promptly, and the restore window (6 hours on the Free plan, 1 day on paid plans) can be shortened to cut storage costs.
- How Cedalio uses Neon for an efficient development workflow
Neon easyNovice
Cedalio, an ESG data verification startup, moved from DynamoDB to Postgres and picked Neon over RDS for a simpler API and console. GitHub Actions creates a Neon database branch and a Fly.io app instance for each PR, then deletes both after merge, and scale-to-zero keeps these temporary environments cheap. A one-database-per-customer design gives tenant isolation. Their backend reads the Postgres WAL, bundles and encrypts operations, stores them optionally on IPFS or Arweave, and commits a hash to a client-owned smart contract for tamper-evident auditing.
- Adopting Neon branching in CI/CD pipelines: a practical story by Shepherd
Neon mediumAdept
Shepherd, an insurtech startup that moved its Alchemist pricing engine from SQLite to Postgres, uses Neon's copy-on-write database branches to give every pull request an ephemeral test database. GitHub Actions call the Neon API to create a branch when a PR opens and delete it on merge. Changes then flow from per-developer and per-PR branches to staging and production, with Render pre-deploy commands applying migrations tracked in a dedicated timestamped table. The team credits branching with removing the cost and effort of keeping test instances synced with production, and notes that scale-to-zero means it no longer pays for idle databases.