Skip to content
Neel Bhavsar
All work

Car rental at scale — availability that never lies

Braganza

Role
Full stack
Year
2026
Impact
200+ vehicles · 40% fewer support tickets
Braganza — cover

Overview

Braganza is a full-stack car rental platform: customers browse a live fleet, pick dates, price a booking and pay, while operators manage vehicles, pricing rules and handovers from an admin side.

The hard requirement was consistency. A car shown as available must actually be bookable, and two people hitting checkout on the same vehicle at the same second must not both succeed.

What I built

  • Worked across the whole stack — Express API and PostgreSQL data model through to the React and Next.js booking interface.
  • Modelled fleet, availability windows, pricing rules and bookings in PostgreSQL, with typed contracts shared end to end in TypeScript.
  • Built the Redis availability cache with targeted invalidation on every booking state change.
  • Built the customer-facing booking flow in Next.js — fleet browsing, date selection, live quotes and checkout — plus the operator admin views.
  • Owned the AWS deployment and the caching strategy behind it.

The hard parts

Double-booking under load

Availability checks and booking creation run inside a single transaction with row-level locking on the vehicle, so concurrent checkouts serialise instead of racing. The loser gets a clean conflict response, not a corrupted booking.

Search that stays fast

Date-range availability across the whole fleet is expensive to compute per request, so results are cached in Redis keyed by fleet segment and window, and invalidated precisely when a booking touches that window rather than flushed wholesale.

Pricing that changes shape

Seasonal rates, durations and add-ons all stack. Pricing lives in a rule table evaluated in a deterministic order, which keeps quotes reproducible and auditable long after the booking is made.

One quote, two places

The price a customer sees while picking dates has to match what the API charges at checkout. Pricing is computed server-side and the Next.js front-end renders only what the API returns, so there is no second implementation to drift.

Outcomes

Double bookings
0
Cached availability
Redis
Production deploy
AWS

Stack

  • Node.js
  • Express
  • React
  • Next.js
  • TypeScript
  • PostgreSQL
  • Redis
  • AWS

Live

Visit the site