Send Emails in Edge Functions
Vložit
- čas přidán 4. 08. 2024
- @resendlabs is the Email API for developers and allows us to send Emails from our custom domains both with Supabase Auth and in Edge Functions.
Conveniently connect your Supabase account to Resend using their integration[0] to automatically send auth emails from your own domains. Additionally use their API in Edge Functions to automatically send emails based on Database Webhooks[1].
[0] supabase.com/partners/integra...
[1] supabase.com/docs/guides/data...
- Find the code: github.com/thorwebdev/edgy-ed...
- Read the docs: resend.com/docs/send-with-sup...
🎙️ Presented by Thor Schaeff (@thorwebdev go.thor.bio/x)
Chapters
00:00 Intro to Resend.com
00:17 Connect Supabase Auth to Resend
01:10 Configure a custom domain with Resend
01:59 Set up custom SMTO for Supabase Auth with Resend
03:15 Send an invitation email with Supabase Auth and Resend
04:34 Send Emails in Serverless Edge Functions
06:25 Generate TypeScript types for the auth schema
08:10 Handle Database Webhook payload
09:25 Make fetch request to Resend API to send email
12:33 Set up Resend API key and store as secret
14:21 Deploy the Supabase Edge Function
14:50 Configure Auth Database Webhook
15:40 Automatically send email when user is deleted
16:30 Automatically send email when new user signs up - Věda a technologie
Cool! Resend FTW, I'm glad you have integration :)
What an awesome video!
Hey Supabase thanks for this, do you plan to do a video on integration with Amazon SES?
can we do similar logic of sending emails with regular serverless functions with resend?
💚💚💚
Can you do a video on how to do custom auth emails using React email?
I have added domain and clicked on last button i.e configure smtp supabase. after clicked button still loading
How do I choose my email domain. Do I have to buy one or is there some I could use for free? Thanks everyone
Good video!
Could you teach me if you know how to use react-email with Edge Functions?
Deno support React?
react-email is not yet supported on Deno, but the @resendlabs team is actively working on this, so shouldn't be too long!
Possible to do a video on using local llama2 to build a chatbot possibly with genoss api endpoint with supabase ?
You might find this useful: github.com/ykhli/local-ai-stack
Is it possible to send a series of email based on a given timeframe? say 1 email every 24 hours?
Read the docs here: resend.com/docs/send-with-supabase-edge-functions
Drink some water, my dude. Great video with great info, but the constant tongue-clicking from what I assume is dry mouth got seriously distracting.
Ha, I never even noticed that, thanks for pointing it out, will try and pay more attention to it 👍 For now, let's call this ASMR 😅
Also, I only saw your comment after uploading today's video, sorry, you might not like it 🤣
@thorwebdev I enjoy all your content, don't you worry about that. 😉
Lord, people will complain about anything.