Member-only story
The Webhook Returned 200. The Order Never Moved to Paid. Where’s the Bug?
A walk through one of the trickiest interview questions in payments engineering, and why reconciliation isn’t optional.
Shriram Bhat7 min read·3 days ago--
I came across an interview question last week that’s been stuck in my head ever since. It looked simple on the surface, but the more I sat with it, the more I realised it captures almost everything that’s hard about building real payment systems.
Here’s the setup:
A customer pays for something. The charge goes through on the payment processor. PayPal fires a webhook to your server. Your webhook handler returns 200 OK.
But the order in your DB is still showing “pending.”
The customer’s money is gone. Your system thinks nothing happened.
Where’s the bug?
If you’ve spent any time near production systems, your gut probably says “oh, that’s a five-minute fix.” It isn’t. This is the kind of bug that quietly lives in production for months. Nobody notices until a customer support ticket lands on your desk, or worse, until a finance team starts asking why the numbers don’t tie out at month-end.