Case studyHeycar · Contract · 2022—2024
Unifying Payments Across Three Markets
Heycar is an e-commerce marketplace for cars operating across the UK, France, and Germany. I unified its fragmented, country-specific payment and order systems into one platform — and refactored it so any payment gateway can plug in.
01The problem
Heycar sells cars online across three European markets — the UK, France, and Germany. But each market ran its own payment and order service: the same logic implemented three times, maintained three times, and drifting apart over time.
Every new payment method or bug fix meant doing the work in triplicate, the customer experience differed by country, and the operational cost of keeping three parallel systems alive was high.
02What I built
I orchestrated the integration of Heycar's payment and order service across all three markets into a single unified platform, then refactored the payment service into a Hexagonal (ports & adapters) architecture.
↕ ports & adapters ↕
03Key decisions
Hexagonal architecture (ports & adapters)
The payment domain — the actual business rules — was refactored to know nothing about any specific gateway. Providers plug in behind ports as adapters, so adding or swapping a gateway (Stripe and others) is a new adapter, not a rewrite. That's what let customers choose their preferred payment method without destabilizing the core.
One platform, configured per market — not three forks
The UK, France, and Germany previously ran separate payment and order services: triple the code, triple the maintenance, inconsistent behaviour. I unified them into a single platform driven by per-country configuration, which is where the 50% operational-cost reduction came from.
A gateway-agnostic core is a testable core
Because the domain logic is isolated from external gateways, it can be unit-tested without hitting real payment providers — making the most business-critical code the most reliable, and safe to change.
04Outcome
Consolidating three country-specific systems into one unified, gateway-agnostic platform cut operational costs by 50%, let customers pick their preferred payment method, and left the payment service far more scalable and maintainable — new markets and providers now extend the system instead of forking it.
Want the deeper technical walk-through?