| Name | Type | ID | Data Handling |
|---|---|---|---|
| Resend | Newsletter | newsletter-resend | Client / Server |
Resend is a multipurpose service that handles all aspects of digital mail programmatically - from sending and receiving emails with in-depth analytics to managing campaigns. By default, our configuration sends emails with your chosen content, using the user's email address or any input you provide (check other variants below).
This is how you can use it.
Start from creating Resend account. In the API Keys section of your User panel create a new key. Then add it under the DL_RESEND_API_KEY within your .env file, like this:
Just after initialize Resend adapter within the app.config.ts file.
The adapter will now connect with the DlNewsletter component to send emails from your website to your inbox using the Resend API. Voilà ! 🥳
Now, if you would like to use a different Resend API, for example to add/create a new audience entry, simply change the endpoint URL and the body of your request. For example, it might look like this:
Thanks to this setup, you'll be able to collect your audience's emails and then plan and send any of your email campaigns, coordinated with Resend Broadcasts and Segments APIs - very powerful stuff. Remember to provide full access for your Resend API Key.
Server handler included
Under the hood, DocLayer automatically adds a special server endpoint (handler) to run Resend API calls. Since the service uses secret API keys, all requests must be handled server-side. You don't need to do anything else after the above steps, but you will need an appropriate server functions setup for your chosen deployment platform. Build your application targeting your intended environment.
More about building your application for specific deployment platforms, you can read here.
Authorize your domain
To safely send emails from your website to your inbox - and to prevent them from landing in the spam folder - you should authorize your domain with the dedicated DNS setup provided by the Resend app. Visit your dashboard’s Domains panel to complete the setup.
