2023/11/20

Weekend Project 7: Automating Workout Reminders on Wod.is with Vercel, Supabase and Mailgun

Part of the reason wod.is exists is to keep me accountable for my workouts. One of the most effective ways to stay on track is through timely reminders, and what better way to do that than with email notifications? In this article, I'll walk you through the process of setting up automated workout reminders on wod.is using Vercel, Supabase, and Mailgun.

1. Daily Workout Generation: Every day at 12 am, my Vercel cron jobs swing into action, generating the workouts of the day. The magic happens through the generate-wods endpoint, where a command is sent to my Inngest client. This triggers the generate-wods event handler, which selects workout types, marks one as public, and sends commands to create new WODs.

Wod.is Vercel Project Settings Cron Jobs
Wod.is Generate WODs Cron Job API Route

Subscribe to continue reading this post.

Subscribe