1
Login to Supabase
In order for our Edge Functions to work we need to connect them to our existing Supabase
account. Login to Supabase via the CLI:
2
Pushing The Edge Functions
For our Edge Functions to be available in production we need push them to Supabase:
3
Enabling Supabase Cron Jobs
Cron Jobs are a custom Supabase extension that needs to be enabled. Here’s how to enable the cron jobs extension:
4
Scheduling The Edge Functions at 00:00
For our last step, we need to schedule our cron jobs to trigger our manage-subscriptions and manage-free-trials edge functions EVERY night at 00:00:00. Here’s how:
Creating a Supabase Edge Function
If needed, it’s also possible to add a new Edge Function using the following command:Testing a Function on Localhost
Pre-Requisites: In order to test Supabase Edge Functions on localhost, please ensure to have
Docker Desktop installed. You can download it from [here].