Building a Serverless API With Google, Firebase and PostgreSQL
summary
Builds a static Middleman site that uses Firebase Functions and the Firebase realtime DB to power a Stripe checkout where the client writes a Stripe token directly to the DB and database-triggered Node functions charge the card, email customers via Drip, and finally replicate to PostgreSQL at compose.com for escape hatch and reporting. Covers rules vs HTTP triggers, admin SDK privileges, a painful recursive email loop bug, and a real-world surprise where analytics billing spiked from $25 to $2,000.
AI-written summary · about
chapters (74)
- 0:00Introduction
- 0:58Robs website
- 1:30Success and failure
- 2:38Serverless confusion
- 3:03Best way to think about serverless
- 3:37Have you tried
- 5:14Inspiration
- 5:54Code
- 6:18What does this buy
- 7:43What you get
- 8:56Why
- 9:07Service lockin
- 9:24Internet of Things
- 9:57Firebase
- 10:19Firebase Pricing
- 11:19The Take Away
- 12:16Use Your Head
- 12:55Businesses Are Here To Make Money
- 13:15Volkswagen
- 13:41GoDaddy
- 14:07Be Prepared
- 14:18Trust No One
- 14:34Fun Stuff
- 15:03How Does It Run
- 15:23Authentication
- 16:22Firebase JSON
- 16:57Firebase Rules
- 17:43What are we building
- 18:05The mental leap
- 18:41Creating a static site
- 18:55Using middleman
- 19:29Static website
- 20:06Working with Firebase
- 20:36Stripe Checkout
- 21:23Firebase Events
- 22:41Stripe
- 22:58PCI Compliant
- 23:18JavaScript
- 23:52Firebase SDK
- 24:39Firebase Console
- 25:03Firebase Data Structure
- 25:57Firebase Node Code
- 26:42Pulling Data from Event
- 27:41Running asynchronous code
- 28:18Updating the checkout path
- 28:35Using ViewJS
- 28:48Using ViewFire
- 29:19Using Stripe
- 29:29Writing to Firebase
- 29:44Firebase Functions
- 31:09Triggering on Events
- 32:32Writing to Database
- 33:15Security
- 33:51Data Pathway Rules
- 36:17Validate vs Write
- 36:38A Whole as a Whole
- 37:09Option 2 HTTP Events
- 37:19Option 2 Ajax Post
- 37:36Option 3 HTTP on Request
- 38:14Option 4 Using Express
- 39:00Option 4 Missing Features
- 39:44Admin Database Ref
- 40:34HTTP Response
- 41:16Anonymous Authentication
- 42:37Notifications
- 43:00Functions
- 43:17Drip
- 43:34Automations
- 43:44Custom Events
- 44:42Custom Fields
- 45:07Admin Backend
- 45:49Why Am I Doing This
- 47:22Firebase Authentication
- 48:10Conclusion
related talks
22mGo serverless: manage payments in your apps
51mServerless with Firebase in the wild
35mConvergence of Serverless APIs & Compute
28mServerless Angular, Material, Firebase and Google Cloud applications
29mServerless For Startups
54mFocus on Your Code, Not Infrastructure, with Google Cloud Functions
22mBuilding Fast on the Modern Serverless Stack
35mGoogle Cloud Functions and Firebase
