Ravi Sir's Cards › AWS
Why an async order API?
What is a VPC: your own private network inside one AWS Region, example ThreeTierVpc 10.0.0.0/16.
Read card text
What this card says
Why do we need it?
If checkout waits for inventory, fraud checks, and email, the shopper stares at a spinner and retries.
What is it?
Async intake: API accepts the order fast (HTTP 202), puts a message on SQS, and a worker Lambda writes DynamoDB later.
How to do it
Build SQS queue + DynamoDB PK orderId + intake Lambda (SendMessage) + worker Lambda (SQS trigger) + POST /orders.
202 Accepted
Example
curl POST {"sku":"TEE-RED","qty":2} returns 202 in ~50 ms; ~2 s later DynamoDB shows status accepted.