SAFE EVEN WHEN THE REQUEST REPEATS.
An e-commerce backend designed around checkout, payments, inventory workflows and safe handling of repeated operations, built on ASP.NET Core with Clean Architecture and CQRS.
- 01 / SECTION
THE PROBLEM
Checkout and payment workflows receive retried commands and duplicate webhooks when networks fail or clients retry.
Without protection, a single customer action can charge twice, decrement stock twice, or create duplicate orders.
- 02 / SECTION
THE APPROACH
Idempotency keys ensure operations process once; subsequent requests safely return the stored result without re-triggering side effects.
Commands and queries are separated with CQRS through MediatR, so write paths stay explicit about the state they change.
- 03 / SECTION
STRUCTURE
Clean Architecture keeps domain rules independent of ASP.NET Core and EF Core, with the domain model owning invariants around carts, orders and inventory.
JWT-based authentication protects the API surface, and Redis backs caching and fast lookups on hot read paths.
- 04 / SECTION
OUTCOME
Repeated checkout attempts and duplicate payment webhooks converge on a single correct result.
The backend stays predictable under retry-heavy, real-world network conditions instead of only on the happy path.
- ASP.NET CORE
- EF CORE
- CLEAN ARCHITECTURE
- DDD
- CQRS
- MEDIATR
- JWT
- REDIS