Weekend Annoying Task Challenge: Sorting Room
Every inbox has the same problem: a hundred emails, and only two or three that actually matter. Sorting Room fixes that by automatically sorting pasted emails into three clear buckets and drafting replies for the ones that need a response — powered by Amazon Bedrock, AWS Lambda, and S3.
Vision & What the App Does
I don't think there's a single Monday morning I've opened my inbox and felt good about it. A hundred-plus unread emails, and somewhere buried in there are two or three that actually need me to do something. The rest is noise: newsletters I forgot I subscribed to, automated notifications, FYIs that don't need a reply, all mixed in with the one message from my manager that's been quietly waiting three days for a response because I scrolled past it twice.
So I built Sorting Room, an app that does the one thing I wish my inbox did on its own: sort itself. You paste in a batch of emails and it automatically drops each one into a category. "Needs Reply" gets a short AI-drafted response sitting right next to it, ready to send or tweak. "FYI Only" is stuff worth knowing but not worth acting on. "Can Archive" is everything else. Instead of reading fifty emails to find the two that matter, I just look at one tray.
How You Built It
I decided early on that I wasn't going to touch Gmail's OAuth flow. That's a rabbit hole I didn't have a weekend for, so instead the app just takes pasted email subjects and snippets through a simple form. It sounds like a small compromise but it meant I could actually finish this instead of getting stuck in an auth setup screen for six hours.
The frontend is one HTML page. I leaned into a "mailroom" theme for it, three physical looking trays that the sorted emails visually land into, because I wanted it to feel like an actual sorting process instead of a generic dashboard. Since it's static, it deploys straight to S3 with zero build tooling.
The backend is a single Lambda function in Python. It takes whatever I paste in, sends it to Amazon Bedrock with a prompt telling the model exactly how to classify each email and when to draft a reply, and hands back structured JSON that the page turns into the three trays.
Honestly, the AI part was the easy part. Everything that actually slowed me down was infrastructure plumbing, and I hit basically every classic mistake along the way:
I set the Bedrock client to us east 1 out of habit, completely forgetting my Lambda function itself was running in Sydney. It took me a minute to realize Nova Lite is actually available directly in ap southeast 2, so I didn't even need to reach across regions once I fixed that.
Then my first test run just quietly did nothing useful, because a brand new Lambda execution role only comes with permission to write logs. It has zero ability to call Bedrock until you explicitly attach that permission yourself, which isn't obvious until you go looking for why nothing is happening.
I also skipped API Gateway entirely and used a Lambda Function URL instead, which felt like the right call for something this small. The catch was the CORS settings weren't sitting where I expected them. They're tucked under an "Additional settings" section that's collapsed by default, so I spent a bit of time convinced the option just didn't exist.
And right at the end, deploying the actual frontend, I hit a 403 Forbidden on a bucket where Block Public Access was already off. Turns out disabling that setting isn't enough on its own. You also need an explicit bucket policy granting public read access, and you have to hit the site through the S3 website hosting endpoint specifically, not the regular object URL, or it'll deny you even with a correct policy.
None of these were hard problems once I found them. They were just the kind of thing where the error message doesn't point straight at the fix, so you end up checking each layer one at a time until something clicks.
AWS Services Used / Architecture Overview
I used Amazon S3 to host the static frontend, AWS Lambda for the backend logic, a Lambda Function URL as the public HTTPS trigger instead of API Gateway, and Amazon Bedrock with the Nova Lite model to handle classification and reply drafting.
Browser (S3 static site) │ POST { emails: [...] } ▼Lambda Function URL (public HTTPS trigger) │ invokes ▼Lambda (Python handler) │ classify ▼Amazon Bedrock (Nova Lite) │ ▼Sorted JSON flows back → rendered into 3 trays in the browser
The flow is: browser sends a POST request with the pasted emails, straight to the Lambda Function URL, which triggers the Lambda function, which calls Bedrock, which returns the classification, which the Lambda hands back as JSON, which the browser renders into the three trays. One synchronous call, no queues, no polling, nothing scheduled. It's about as simple a trigger chain as you can build, which felt right for something this size.
What You Learned
I came into this expecting the AI prompt to be the hard part, and it really wasn't. The actual learning was everywhere else: how Lambda execution roles default to nearly nothing, how region choice for Bedrock quietly matters even when you don't think it will, where CORS settings hide on a Function URL, and how particular S3 is about the difference between "public access is allowed" and "public access is actually configured." I also got a much better feel for Bedrock's converse API and getting clean structured JSON back out of it, which I'll definitely reuse on the next thing I build.
Link to App or Repo

Enjoyed reading this content? Let the author know!
Your likes, comments, shares, and saves help creators reach more builders.
Loading recommendations
Loading article