Menu
Defer is reaching the end of its service life on May 1, 2024. Please reach out to support@defer.run for further information.
Engineering
February 28th, 2024

Build Week #1, Day 3:
Schedule and offload emails

Charly PolyCharly PolyCEO

Resend x Defer

Offload the sending of emails

Sending emails following a user action directly from an API Route is tempting but comes with many drawbacks:

  • Your Email Provider might not scale as well as your Serverless Functions, resulting in reliability issues (rate limiting)
  • Sending a lot of emails from Serverless Functions (without a Provider) might lead to IP Reputation issues
  • Overall, sending email from an API might degrade the end-user performance (especially for compute-intensive rich emails)

For all those reasons, and especially when sending rich emails with Resend, offloading them to run in the background is a straightforward solution.


Get started in under 2 minutes by using our Resend x Next.js template, deployable on Vercel in one click.


Advanced scheduling of emails

Some emails need to be sent on very specific schedules, for example:

  • Following a sliding billing window
  • Following specific application triggers (ex: when a user reaches 100 logins)
  • Following specific criteria (ex: email campaign)

Those scenarios greatly benefit from Defer's Epoque Scheduler while relying on Defer's Platform to scale thousands of executions.


See an example of a Monthly billing email schedule following a sliding window in our Resend x Defer guide.

Join the community and learn how to get started, and provide feedback.
Stay tuned about our latest product and company updates.
Start creating background jobs in minutes.
Copyright ©2024 Defer Inc.