Your core flow is sound, and I'd build from it. The decisions that usually sink checkout designs are already right: stock reservation is atomic, the payment call is outside the transaction, the provider gets an idempotency key, and there's a reconciliation job and a stuck-order alert. What's left is mostly unspecified behavior, which is cheap to settle before you start. Here is everything I found, most severe first.

## High: decide before coding

1. **Orders that were never charged get stuck.**
   - If an instance dies after step 2 commits and before step 3 sends the charge, the order is `PENDING` with stock reserved and no charge at the provider.
   - The reconciler asks the provider about that order and gets "not found". The design doesn't say what to do with that answer.
   - It should mean: if the provider has no record and the order is older than the retry window, mark it `FAILED` and restore the stock.
   - Without that rule, the stock stays locked and the 30-minute alert fires on every crash.

2. **Status changes need a guard.**
   - The request handler (steps 4–5) and the reconciler (step 6) can settle the same order. A slow request can still be retrying when the reconciler looks at it.
   - Each settle should be `UPDATE ... SET status = :new WHERE id = :id AND status = 'PENDING'`.
   - Stock should be restored only if that update changed a row. Otherwise stock can be restored twice, and an order can flip between `PAID` and `FAILED`.
   - With two instances, both will also run the reconciler every 5 minutes. Use `SELECT ... FOR UPDATE SKIP LOCKED` or an advisory lock so they don't process the same orders.

3. **"No module reads another module's tables" conflicts with the transactions.**
   - Steps 2 and 5 write `stock` (inventory) and `orders` (orders) in one transaction.
   - Pick a mechanism and write it down. For example, `OrderCheckout` opens the transaction and passes it to both modules. Or inventory exposes `reserve(tx, items)` and `release(tx, items)`.
   - Also, payments owns no table. Decide where the provider's charge id and state live. I'd store the charge id on the order or in a `payments` table, because the reconciler and any future refund need it.

4. **Idempotency edge cases.**
   - Two concurrent requests with the same key: the loser hits the unique constraint at insert, after it has already reserved stock. It rolls back, but the design says it should return the existing order, not an error. Say so, and handle the unique violation explicitly.
   - The same key sent with a different cart should return `422`, not the old order.
   - Scope the unique constraint to `(customer_id, idempotency_key)`, so one customer's key can't collide with another's.
   - A repeat while the order is `PENDING` should return the current state and must not start a second charge attempt.

5. **A confirmation email can be lost.** If the process dies after the `PAID` commit and before the email is queued, no email is ever sent. The queue also isn't in your infrastructure list, which has only Postgres and the load balancer. The simplest fix is an `outbox` table written in the same transaction as `PAID`, with a small worker that sends from it. That also avoids adding a new queue.

6. **Prices and payment inputs aren't defined.** `order_items.unit_price` and `total` need a source. If the client sends prices, anyone can set their own. The design needs a price source (a product/price table or a catalog call) and server-side total calculation. It also doesn't say how the payment method reaches the provider (a client token?) or how the caller is authenticated.

## Medium: settle during the first day

7. **Stock reservation details.**
   - A SKU with no `stock` row updates zero rows and returns `409`, the same as out of stock. Unknown SKU should be `422`/`404`.
   - A cart with the same SKU on two lines should be merged first.
   - Lock rows in sorted SKU order, or two overlapping multi-item carts can deadlock.

8. **Retry rules and request time.**
   - Retry only timeouts and `5xx`. A `4xx` from the provider should not be retried, and the design doesn't say whether it counts as a decline.
   - Four attempts at 5 s each plus backoff is about 20–30 s with the HTTP request held open. Check that against the load balancer and client timeouts.

9. **Schema is missing constraints and indexes.**
   - Primary keys on `orders.id` and `stock.sku`, and a foreign key from `order_items.order_id`.
   - A unique constraint on `(order_id, sku)`.
   - `CHECK (available >= 0)` and `CHECK` on `status`.
   - `NOT NULL` where intended.
   - An index on `(status, created_at)` for the reconciler, and one on `order_items.order_id`.

10. **No API contract.** The response codes and bodies for success, decline (`402`?), `409`, `202`, and a duplicate aren't listed. A client that gets `202` needs `GET /orders/{id}` to poll, and that endpoint isn't defined.

11. **Test plan has gaps, and the reconciler is the riskiest part.** Add tests for:
    - the reconciler: charge found paid, found declined, not found, still unknown
    - an in-flight request racing the reconciler
    - concurrent duplicate keys
    - a two-item cart where the second item is out of stock (checks the rollback)
    - stock restored exactly once after a decline
    - email failure not failing the order
    - the same key with a different cart

    Concurrency tests need a real Postgres, not a mock. Your CLAUDE.md asks for tests first, so order the build around the reconciler tests.

## Low: tidy up

12. **Observability:** besides the 30-minute alert, add a metric or alert for reconciler failures, outbox backlog, and the rate of `409` and decline responses.
13. **Settle latency:** the reconciler runs every 5 minutes and only picks up orders older than 2 minutes, so a `202` order can take up to about 7 minutes to settle. That's probably fine, but tell the client to expect it.
14. **Missing states:** there's no `CANCELLED` or `REFUNDED`. Fine for v1, but note that it's out of scope.
15. **Housekeeping:** there's no migration or rollout note, no rate limiting, and no data-retention note for customer and order data. Revision 3 has no changelog of what changed.
16. **`status` and `currency` as free text:** a Postgres enum or a `CHECK` is safer. Also say whether `total` is validated against the sum of the items.

Items 1–6 are specification gaps rather than redesigns. I'd estimate half a day to write them into `design.md`, and then you can start building.

VERDICT: READY WITH CHANGES
