Nathaniel Lewis

Project 01 · Serverless · live since Nov 8, 2026

Resume access control, v2: approval-based

Rebuilt resume requests as an approval workflow: private, expiring, download-limited links instead of email attachments.

  • Cloudflare Workers
  • D1
  • R2
  • Turnstile
  • HMAC-signed links
  • Brevo

Problem

Once emailed, the resume had no expiry, no download limit and no record of who held it.

Approach

An approval workflow on Workers, D1 and R2, with signed review links and expiring downloads.

Result

Live and verified end to end; now part of CV Snapshot's Plus plan.

  1. RequestTurnstile, rate limits
  2. Review linkHMAC-signed email
  3. Approvedeliberate click
  4. Private link7 days, 3 downloads

The problem

Version 1 replaced three WordPress plugins with a Cloudflare Worker, but access still ran through me by hand. Each request arrived as an email, I sent the resume as an attachment, and from then on the file had no expiry, no download limit, and no record of who held it.

The approach

Rebuilt it as an approval workflow on Cloudflare Workers, D1 and R2. A recruiter submits a short form, checked by Turnstile, a honeypot, and per-visitor and per-site rate limits. I get an email with an HMAC-signed review link; opening it only shows the request, and approving or declining takes a deliberate button press, so email link scanners can't act on my behalf.

On approval, the recruiter gets a private link that works for 7 days and 3 downloads. The PDF sits in a private bucket and streams only after the code checks out, and the database stores only a hash of that code. A decline sends a polite note with no reason given, and requests I don't answer expire after 14 days with the same note.

Data collection is minimal by design: visitor IPs are stored only as salted hashes, message text is never stored, request logs are purged after 90 days, and a kill switch turns the feature off without a redeploy.

The result

Live on nathaniellewiscv.com since Nov 8, 2026, and verified end to end: request, approval email, approval and download, each confirmed in the mail provider's log. 75 automated tests cover the feature, and 220 cover the order system it runs on.

Live testing caught two failures the unit tests couldn't: Outlook rejected the approval email as spam, fixed with a clear sender name, reply-style wording and a plain-text link under each button; and browser autofill filled the hidden spam trap, silently dropping real requests, fixed by renaming the field and logging every trap hit. It now ships to clients as part of CV Snapshot's Snapshot Plus plan.

  • 75automated tests on the feature
  • 7 days / 3link lifetime and download limit
  • 2live-only failures caught and fixed

What I'd tell the next engineer

Unit tests prove the code works. Only a live test proves the email lands and the form behaves in a real browser.