**You can start tomorrow, but not until you've settled four decisions in the design, because they change the order state machine and the schema.** The overall shape is sound. Reserving stock and writing the order in one transaction, charging outside any transaction, and reusing the order id as the provider's idempotency key are all the right calls. The holes are in the failure paths, which is where money bugs live.

## Must fix before building

1. **Reconciliation doesn't say what to do when the provider has no charge.**
   - Case: the service commits the `PENDING` order and stock reservation (step 2), then crashes before calling the provider. Two minutes later the job asks the provider about that order and gets "not found". The design doesn't say what happens next.
   - Step 6 also says "settle as `FAILED`" without saying the stock is restored. As written, stock leaks every time reconciliation fails an order.

2. **Nothing prevents two actors from settling the same order.** The request thread and the reconciliation job can both be working on one order.
   - Case: a charge takes longer than expected, and the job sees the order as `PENDING` and finds "not found" at the provider. The job marks it `FAILED` and restores stock. Then the original request's charge succeeds. The customer is charged, the order says `FAILED`, and the stock is back on sale.
   - Fix: make every transition conditional, e.g. `UPDATE ... WHERE status = 'PENDING'`, and only restore stock if that update changed a row. Also decide what happens when a `FAILED` order turns out to have been charged, which probably means an automatic refund.
   - Reconciliation runs on both instances, so it also needs a lock (advisory lock or `FOR UPDATE SKIP LOCKED`), or the two copies will race each other too.

3. **The client has no way to learn the outcome after a `202`.** There is no `GET /orders/{id}`, no webhook, and no mention of customer auth. A customer who gets a `202` can only retry the `POST`.

4. **The source of prices is undefined.** `order_items.unit_price` and `total` have no stated origin. If they come from the client's cart, that is a pricing vulnerability. The design should say the server looks up prices and computes the total.

## Should fix (resolve in the doc, not necessarily before day one)

- **The module rule contradicts step 2.** "No module reads another module's tables" conflicts with one transaction that updates `stock` (inventory) and inserts into `orders`. Name the decision, for example orders owns the transaction and passes a handle to an inventory function.
- **Idempotency key scope is too loose.**
  - A global unique key means two customers sending the same key collide. Scope it to `(customer_id, key)`.
  - Two concurrent requests with the same key will hit the unique-violation error, so handle it by returning the winner's order.
  - Same key with a different cart should return `422`, not the old order.
- **Schema is incomplete.**
  - There are no primary keys or foreign keys on `stock(sku)` or `order_items`.
  - There is no `CHECK (available >= 0)` and no index for the reconciliation query on `(status, created_at)`.
  - Reservations that touch several SKUs can deadlock unless you update them in sorted SKU order.
- **Decline versus error is not defined.** Say which provider responses mean "declined" (step 5), which mean "unknown" (step 6), and which mean "our request was invalid".
- **The email can be lost.** If the process dies between commit and queue, the confirmation never goes out. A transactional outbox or an `email_sent` flag fixes this. At 2,000 orders a day, accept the gap or fix it, but write down which.
- **Stuck orders hold stock for up to 30 minutes** before anyone is alerted. That is fine at your volume, but say it is deliberate.
- **The request can hang for about 30 seconds.** Four attempts at 5 s each plus backoff can exceed typical load balancer timeouts. Check this against the actual timeout.
- **Single Postgres.** Point-in-time recovery is a backup, not availability. That is acceptable at this scale, but state it.

## Tests to add

- Crash after step 2 and before the charge, then reconciliation settles the order and restores stock.
- Reconciliation racing the live request (the case in item 2).
- Two concurrent `POST`s with the same key.
- Two concurrent buyers of the last unit. As written, "buying the last unit" may not be concurrent.
- Decline restores stock exactly once.
- Email failure leaves the order `PAID`.
- Multi-SKU orders with a failure partway through.

Step 1 of your list should be a short revision 4 covering items 1–4, then build schema, inventory, and orders in parallel while the state machine is pinned down.

VERDICT: READY WITH CHANGES
