Add Email Queue Support to Resend Adapter #16064
joshuademarco
started this conversation in
Feature Requests & Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hey guys, I really enjoy using Payload and would love to contribute something back to the project.
In my current setup, using Vercel effectively locks my organisation into using Resend instead of Nodemailer.
This works well overall, but we occasionally run into rate limits when sending large volume of emails _(e.g. 429 errors due to the 5 requests/second or daily limits).
I would like to propose the following:
Introduce an optional queue configuration for the Resend adapter.
When set,
payload.sendEmail()would automatically enqueue emails instead of sending them immediately.This would ensure that emails are not lost when rate limits are hit (especially critical ones like verification emails).
I am not sure if nodemailer would benefit from such an option.
While this can currently be implemented manually by enqueueing jobs, doing so would also require to manually handle collection auth hooks.
Any particular way i should approach this?
Beta Was this translation helpful? Give feedback.
All reactions