Settings

Theme

Resend to RSS, or when a friend wants RSS instead of an email

github.com

4 points by tarasyarema 3 months ago · 2 comments

Reader

tarasyaremaOP 3 months ago

Here's today funny story:

I'm building a company and as we are early stage, we have a newsletter for people that might be interested in our progress, and one of them is a good friend of mine. Nevertheless, he asked to be removed from our newsletter, and instead of just unsubscribing like a normal person, he said "just give me an RSS feed"... So I built this while having lunch today...

The interesting technical bit: Resend's broadcast API doesn't return email content (it's documented but still surprising). So you can't just fetch broadcasts and serve them as RSS...

The workaround is to:

1. Fetch broadcast metadata (subject, from address) 2. Fetch all sent emails separately 3. Match them by comparing subject + from fields 4. Cache everything in Vercel blob storage

The cron job respects Resend's 2 req/sec rate limit, so first sync takes ~4 minutes for 370 emails. But subsequent runs are incremental - only 9 seconds when there's nothing new.

Built with Next.js API routes + Vercel Blob + Vercel Cron. Works surprisingly well for such a hacky approach. The matching-by-subject thing feels fragile but hasn't failed yet jeje

---

PS: Are you still using RSS?

PS2: I initially thought of using Google Groups for this, but seems it's not supported. Sad :/

PS3: Thanks Claude Code 2 <3

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection