Skip to content
boatweb.dev
All work

● live

Fackbeed

One inbox for bug reports, feature requests and feedback from all my projects.

Started
Oct 2026
Version
v1.1
Commits
231
Visit fackbeed.online(opens in a new tab)
  • Cloudflare Workers
  • D1
  • TypeScript
  • Resend
  • three.js
  • anime.js
  • esbuild
  • Vitest
Fackbeed's home page with its particle-wave hero

What it is

Every app I build eventually needs a "report a bug" button, and I didn't want to build it five times. Fackbeed is the one place all of them send people to. Someone reports a bug, asks for a feature or leaves feedback, and gets a ticket number with the app's own prefix (FB-0042 for Daily Standup) plus a private link to follow it. No account needed.

On my side, every ticket from every app lands in one admin inbox. Daily Standup is the first app wired in. It's one Cloudflare Worker with static assets and a D1 database, and no framework.

How it works for the person reporting

  1. They click "Send feedback" in an app. The app's server signs a link and opens the form.
  2. They write what happened and attach up to 5 screenshots. The draft survives reloads and an expired link.
  3. They get a private ticket page and an email receipt. From that page they can reply, or erase their personal details.
  4. When I move the ticket to Planned, Shipped, Closed or Declined, they get an email.
Fackbeed's home page in light mode
The public home page. Its main job is finding your ticket again.

Decisions worth writing down

Signed, one-time links instead of an open form

Feedback only comes from my own invite-only apps, so the inbox must not be floodable. Nobody can submit from a plain URL. The app's server signs the link with HMAC-SHA256 and a per-project secret. A link lasts 10 minutes and works once.

"Works once" turned out to be subtle. An audit before launch found that one link could send 4 tickets. The signature is 43 base64url characters, and the last one carries 2 spare bits that atob ignores, so four spellings decode to the same signature. Each spelling had its own digest in the used-links table, so the primary key never caught the reuse. Now only the canonical spelling is accepted: the server re-encodes the decoded bytes and refuses the token if the text doesn't match.

Caps that hold under concurrency

There are caps per app user (5 tickets an hour, 20 a day) and across everything (50 a day). The first version read the counts and then wrote the ticket, so parallel requests all saw the old count. Now the cap is enforced inside the write. The ticket insert and the counter bumps go in one D1 batch, and after each bump a guard statement copies the counter row onto its own key if it's over the limit. That breaks the primary key, the batch fails, and everything rolls back. One transaction, no gap between reading and writing.

Screenshots lose their metadata twice

Screenshots can carry GPS coordinates and camera details. The form redraws every screenshot on a canvas, even ones that already fit, so only pixels leave the browser. The server strips metadata again for anything that arrives some other way. It drops whole EXIF, XMP and text segments from JPEG, PNG and WebP and copies everything else byte for byte, so the pixels are never touched.

D1 is 500 MB on the free plan, so screenshots have a budget too. Each app user gets 10 MB a day, and once screenshots hold 400 MB the form stops taking them. The text still goes through.

Email that stays inside the free tier

All mail goes through Resend, whose free tier allows 100 emails a day. So the Worker counts every email it tries in a UTC day. From 80, my own alerts wait for the hourly digest. From 100, or if Resend refuses one, mail to a sender is held and the hourly cron tries once more. Only if that fails too does the ticket get a visible mail_failed event.

A routing quirk

With not_found_handling set, browser navigations to paths that aren't static files get the 404 page without ever reaching the Worker. The Worker's own paths (/f/*, /t/*, /api/* and a few more) have to be listed in run_worker_first so it runs before the asset server.

Privacy

A ticket link is a credential, and Workers invocation logs record every request URL, so those logs are off. Fonts are self-hosted, so only Cloudflare sees visitors' IP addresses. Sender details are forgotten 180 days after a ticket closes, and spam is deleted after 30 days. My alerts never carry the sender's email or the ticket link.

What's next

More of my apps, each added from the admin with its own prefix and secret. GitHub Notify is on hold: a browser extension can't keep a signing secret, so its relay would have to sign the links.