r/audiobookshelf • • 1h ago

I built a $0/mo Cloudflare Worker + R2 + HTTP/3 (QUIC) edge-caching front door for Audiobookshelf — looking for beta testers!

8 Upvotes

I love self-hosting Audiobookshelf at home, but running it over a residential upload connection had two annoying pain points for me:

  1. Slow browsing/covers when scrolling through the library away from home.
  2. Stream drops when switching networks (Wi-Fi ↔ 5G/LTE) — walking out the front door changes your phone's IP and kills the TCP stream to your home server.

I didn't want to pay to host ABS in the cloud or upload my entire multi-TB library to cloud storage. Then I realized: you only listen to 1–3 books at a time.
So I built abs-edge-cache, an open-source Cloudflare Worker that sits in front of your existing Audiobookshelf server (e.g., behind a Cloudflare Tunnel) and turns Cloudflare's global edge into a smart caching layer—while keeping your full library on your home server.
What it does

  • HTTP/3 (QUIC) audio streaming: Native players (AppleCoreMedia, ExoPlayer, browsers) stream over QUIC so Wi-Fi ↔ cellular handoffs migrate mid-stream without dropping—and it automatically falls back to HTTP/2 or HTTP/1.1 on any device or network that doesn't support QUIC.
  • Smart R2 audio caching (sliding window): Pressing Play warms the active chapter and upcoming chapters (WARM_WINDOW_TRACKS) into Cloudflare R2 in the background, serving 206 byte-range requests from the nearest edge POP. Finished books are automatically evicted from R2, and hitting Download only uses R2 if the book is already cached (never wastes R2 space on local downloads).
  • Instant edge-cached UI & metadata: Covers, static Web UI assets, RSS feeds (/feed/:slug), and library/progress JSON are cached at Cloudflare's edge with instant invalidation on edits or progress syncs.
  • Offline-origin resilience: If your home server reboots or your tunnel drops temporarily, cached reads fall back to STALE-IF-ERROR, and listening progress writes (/sync, /close, PATCH /progress) are queued and automatically replayed as soon as your server comes back online.
  • Built-in R2 Free-Tier Circuit Breaker (FREE_TIER_GUARD): Enabled by default to cap storage at 9.0 GB (with oldest-book LRU eviction) and Class A/B ops at 80% of Cloudflare R2's free tier so you never get a surprise bill (or set FREE_TIER_GUARD="no" if you use paid R2).
  • Security: Scanner/bot blocker, edge login brute-force rate limiting, device/country session locking, and optional HS256 JWT signature verification (VERIFY_JWT).

Looking for Beta Testers!
So far I've tested this thoroughly with Absorb on iOS, and it's been rock solid. I'd love feedback and bug reports from anyone willing to test it with:

  • Official Audiobookshelf app (iOS & Android)
  • Plappa / ShelfPlayer
  • Web UI / RSS podcast clients

It includes a 1-click "Deploy to Cloudflare" button in the README (plus full manual Wrangler instructions and a unit test suite):
GitHub: https://github.com/binyaminyblatt/abs-edge-cache
Would love to hear how it behaves on your setup or if you run into any client quirks!


r/audiobookshelf • • 46m ago

I built Spokarr – request audiobooks like in Overseerr/Seerr, with Audiobookshelf sign-in

10 Upvotes

Hi everyone! I wanted my family to be able to request audiobooks the way they request movies in Seerr – but Readarr never found the editions we actually wanted (German readings with a specific narrator), so I built Spokarr.

What it does

  • Browse and search the Audible catalog (any store – US, UK, DE, FR, …) and pick the exact edition: narrator, unabridged/abridged, language.
  • Sign in with your Audiobookshelf account – no new accounts. Admins approve requests (or give people auto-approve).
  • Spokarr searches your indexers (Prowlarr or Newznab), scores every release against the edition (title, narrator, language, dramatization vs. reading, size per minute) and sends the best one to SABnzbd or qBittorrent.
  • Finished books land in your Audiobookshelf library as Author/Title, get scanned, matched against Audible and tagged “Requested by <name>”.
  • Discord/ntfy notifications, stalled-download detection, English and German UI, mobile friendly.
  • Small: plain Node.js, no dependencies, Docker images for amd64 and arm64 – runs fine on a Pi.

GitHub: https://github.com/BlugDeg/Spokarr (MIT) docker pull ghcr.io/blugdeg/spokarr:latest

It's early (v0.4), so feedback and bug reports are very welcome – especially from people using other Audible stores than DE/US. Transparency note: I built it with a lot of help from an AI coding assistant (Claude). It runs on my home server, but it's new – expect rough edges.