Building a fast, zero-bloat custom apparel and developer mug storefront usually requires paying $39+/month for heavy e-commerce SaaS themes. Instead, I built a serverless Cloudflare Workers + R2 + KV Print-on-Demand Studio paired with a Python numpy cylindrical porcelain-glaze mockup compositor.
👉 Live Storefront: https://wittycraft-studio.tranhoangtu-it.workers.dev
How the Mockup & Edge Pipeline Works
- Floodfill Alpha Extraction +
MultiplyFabric & Glaze Blending: Instead of slapping rectangular stickers onto flat vector polygons, our Python pipeline strips solid#FFFFFFbackgrounds via border BFS floodfill, applies a subtle cosine cylindrical warp (numpy) matching the curvature of an 11oz ceramic mug, and blends ink usingImageChops.multiplyso real studio cotton folds and porcelain reflections shine directly through the print. - Cloudflare R2 + Workers KV Persistence: Every 30-minute batch pushes crisp
.jpgstudio mockups directly into an R2 bucket (MEDIA_BUCKET) with immutableCache-Controledge headers and updates the product index in Workers KV (CATALOG_KV), complete with dynamic/sitemap.xmlandSchema.org/ProductJSON-LD routes (/item/WC-028,/item/WC-025,/item/WC-026).
Developer & Tech Desk Favorites on the Shelf
- Explain It To The Duck (#WC-028) — Rubber duck debugging meets mechanical keyboards & espresso.
- Unbothered & Caffeinated Capybara (#WC-025) — Yuzu cedar hot spring capybara for calm on-call shifts.
- Engineer Dictionary Definition Mug (#WC-007) — Minimalist Georgia serif porcelain mug.
Feel free to browse the full 32-piece studio catalog at WittyCraft Apparel & Mug Co. — happy to answer questions about the R2 + KV edge architecture or numpy cylindrical warping in the comments!


