Back in September I wrote about my “DIY Federated Reader” experiment: a Gmail-to-Mastodon bot that turns my newsletter inbox into a public, federated news stream I’m able to read as a “feed” in Flipboard. This project is now featured on the “Trusted Voices” page of ResistAndHeal.com, a website and project I started in December 2024. […]
Back in September I wrote about my “DIY Federated Reader” experiment: a Gmail-to-Mastodon bot that turns my newsletter inbox into a public, federated news stream I’m able to read as a “feed” in Flipboard. This project is now featured on the “Trusted Voices” page of ResistAndHeal.com, a website and project I started in December 2024. A few weeks after writing that initial post, on Heal Our Culture, I connected this project to the bigger goal of “reclaiming our news feeds” and resisting the polarizing, ad-driven algorithms of Big Tech platforms.
Tonight I spent some time “vibe coding” a maintenance release of the Federated Reader bot, tightening up how it chooses links and remembers what it has already shared. The bot script still lives on GitHub and the script results are “live” (and continually updating) on my secondary Mastodon account, @FederatedReader… but under the hood it’s now a bit smarter and (hopefully) less repetitive.

What changed?
The following explanation of my vibe coded changes was provided by ChatGPT… AFTER I ended up taking code which turned out to be broken, and asked Claude AI to fix it.
Tonight’s work on the Federated Reader bot was less about adding flashy features and more about tightening the plumbing under the hood:
- Smarter, more reliable link detection.
The bot still uses my original “smart URL” pipeline: it looks at canonical/meta tags, scores all the links in the email body, and only falls back to “first URL in the text” when it has to. That’s what lets it handle Substack, Ghost, Mailchimp and friends without hard-coding each provider.- Cleaner URL “canonicalization.”
Many newsletters wrap their real article URLs in redirects or decorate them with analytics parameters. The updated script now decodes Substack’s special redirect links, follows common?redirect=/?url=style parameters when they contain a full URL, stripsutm_*and similar tracking tags, lowercases hostnames, and removes extra slashes. Tiny variations of the same link now normalize to a single canonical URL.- Junk / tracking links are filtered out.
Some messages still include links that should never be posted—things like the XHTML namespace URL, Substack’s image-based “open pixel,” or broken Ghost click-tracking links. The bot now recognizes those patterns and treats them as junk, so they don’t appear in the Mastodon feed at all.- Persistent de-duplication.
The script remembers both which Gmail messages it has processed and which cleaned URLs it has already posted, and it prunes that memory after a configurable number of days. That gives me a stable “only post this link once” guarantee without running into Google Script Properties size limits.- Optional Mastodon-history check.
For now I’ve left the cross-checking of my recent Mastodon posts turned off (to avoid API scope issues), but the logic is still there behind a configuration flag if I ever want an extra layer of safety.- Nicer posts and better error reporting.
Each post now includes the newsletter subject, author name, and date, plus the URL and a couple of hashtags like#OwnYourFeedand#FederatedReader. If the script has trouble talking to my Mastodon instance, it logs a detailed error and can even email me a heads-up.
From a user’s perspective, the result is simple: the @federatedreader Mastodon account (and my Flipboard channel fed by it) should post fewer glitches, no “XHTML namespace” nonsense, and far fewer repeats of the same tracking URL.
Note my desire to be transparent here: The “vibe coding” scripting updates described above are well beyond my ability to independently create or replicate. After letting my updated Nov 4 code version run (Commit 7e4e617) I posted a Nov 5 version (Commit 3568988) via Claude AI’s help, and it appears to work. I’ll monitor this over the next 12 to 24 hours to verify.
Why this matters
In my Heal Our Culture post, I argued that “to heal our culture, we need to reclaim our news feeds and collaborate to reinvent social media.” Little tools like DIY Federated Reader are one small way I’m trying to live into that idea: Curating a slow, human-chosen feed of writing by sources I trust and value, using open tools and federated platforms.
If you’re experimenting with your own federated reader, you’re welcome to fork the project on GitHub, tweak the filters for your own newsletters, and share what you learn. The more of us who become neighbors and filters for each other online, the less power the default, engagement-hacked feeds have over our attention.
* AI Attribution: I used “ChatGPT 5 Thinking” to draft an initial version of this blog post, which I edited further. I created the included image with the same AI model, using this fun prompt:
Can you please create a square visualization of the key ideas here… but use the style of an oil painting, make this look mystical like a medieval and silk road setting… maybe in a caravanserai in ancient times… and a young blonde mystic (make it look like me, let me know if you need a selfie for help) is using magical spells and alchemy to create something amazing that is both welcome and exciting to an audience that looks on during an evening campfire story….













