Connect Resend to Fondoo
This guide sets Resend as the delivery service for the email your Fondoo site sends. Fondoo still decides who may receive each message, checks consent and suppressions, and keeps the delivery log. Resend only carries the mail. Your AI agent keeps using the normal Fondoo email operations, such as sendemail, and the messages go out through your own Resend account.
This page covers the resend delivery provider. To let your agent read your Resend domains and look up sent messages without sending anything, see the separate Resend platform guide (resend_platform).
What Fondoo can do with it
- Send transactional and marketing email for a site through your Resend account (
send_email, newsletters and support replies all use the same pipeline). - Use Resend for one site only, or as the default for the whole workspace. A site setting overrides the workspace setting.
- Receive delivery, bounce, complaint, open and click events from Resend by webhook. Hard bounces and complaints add the address to your suppression list, so Fondoo stops mailing it.
Approvals and limits that still apply:
configure_email_providerandset_providerneed the workspace owner.- Marketing email needs evidenced consent and a postal address set with
update_email_settings. - An agent that sends more than 1,000 marketing emails for a site in a month needs your approval.
- Each
send_emailcall takes up to 100 recipients.
Before you start
- A Resend account. Resend has a free plan and paid plans. Check Resend pricing for current volumes. Resend bills you directly. Fondoo's per-site email overage charge does not apply to mail sent through your own provider.
- A domain verified in Resend. Resend requires at least one verified domain before you can send (Domains).
- The same domain added and verified on your Fondoo site (
set_custom_domain, thenget_domain_statusuntil it is active). Fondoo refuses to set up a sending domain it has not verified. - Use the same domain name in both places. Fondoo matches the From domain exactly. Resend recommends a sending subdomain such as
updates.example.com. Fondoo only accepts a subdomain if that subdomain is itself a verified domain on your Fondoo site.
Step by step: get your credentials
- Sign in to Resend and open Domains (resend.com/domains). Click to add your domain and follow the add a domain guide. Add the DNS records Resend shows at your DNS host. Wait until Resend shows the domain as verified.
- Open API Keys (resend.com/api-keys) and create a new key. Resend asks for a name, a permission and an optional domain (API keys).
- Name it something you will recognise, such as
fondoo-delivery. - Choose Sending access. Fondoo only calls the send endpoint with this key, so it does not need full access (permission values).
- Optionally restrict the key to your sending domain.
- Name it something you will recognise, such as
- Copy the key now. Resend does not show the key value again after you create it.
- Write down the list of domains you will send from, in lowercase, for example
example.com. This becomes thedomainslist below.
You now have:
| Fondoo credential field | What to put in it |
|---|---|
apiKey (required) | The Resend API key from step 2 |
domains (required in practice) | List of your verified sending domains, lowercase |
webhookSecret (optional) | The webhook signing secret, added in the Webhooks step |
Connect it in Fondoo
In the dashboard. The Connections page lists an Email card, but it only opens setup instructions. There is no form for Resend keys yet. Use your agent or the REST API.
By asking your agent. Example prompt:
Set my site's email provider to Resend. I will run the credential step myself. Then set up example.com as the sending domain and check it.
configure_email_provider takes the key directly in its input. It has no secure paste page. Anything you paste into a chat can stay in chat logs. Prefer running that call yourself over REST from your own terminal, using an owner API key. The agent can do the other steps.
The calls, in order:
configure_email_provider({siteId, provider:"resend", credential:{apiKey:"re_...", domains:["example.com"]}}). Leave outsiteIdto make it the workspace default.set_provider({siteId, capability:"email", provider:"resend"}). If an email provider was already selected for this site or workspace, this step decides which one is used.setup_sending_domain({siteId, domain:"example.com"}). Resend owns the DNS records, so Fondoo returns no records here. It only checks that the domain is in yourdomainslist.check_sending_domain({siteId, domain:"example.com"}).
You can also ask your agent for connect_service({provider:"resend", siteId}). That returns a signed 15-minute link with these instructions. It never takes credentials.
REST equivalent. Every operation is POST /v1/ops/<operation>:
curl -X POST https://api.getfondoo.com/v1/ops/configure_email_provider \
-H "Authorization: Bearer $FONDOO_OWNER_KEY" \
-H "Content-Type: application/json" \
-d '{"siteId":"YOUR-SITE-ID","provider":"resend","credential":{"apiKey":"'"$RESEND_API_KEY"'","domains":["example.com"]}}'Self-hosted Fondoo uses your own API origin instead of api.getfondoo.com.
Webhooks
Webhooks let Fondoo learn about bounces and complaints. Without them, Fondoo cannot suppress bad addresses that Resend reports.
- Run
get_email_provider({siteId}). CopyfeedbackUrl. It looks likehttps://<fondoo email origin>/webhooks/email/resend/<providerId>. - In Resend open Webhooks (resend.com/webhooks), click Add Webhook, paste the URL and select these events:
email.sent,email.delivered,email.bounced,email.complained,email.opened,email.clicked(create a webhook, event types). Fondoo ignores other event types. - Open the webhook's details page and copy its signing secret (verify webhooks).
- Run
configure_email_provideragain with the same scope (samesiteId, or none) and the full credential, now includingwebhookSecret. Keeping the same scope keeps the sameproviderId, so the URL stays valid. Changing the scope creates a new connection with a new URL.
How signing works: Resend signs each delivery using Svix headers (svix-id, svix-timestamp, svix-signature). Fondoo checks the HMAC-SHA256 signature over the raw body with your secret (a leading whsec_ is accepted). It rejects requests more than 5 minutes old. A bounce counts as hard when Resend reports the bounce type Permanent.
Test that it works
get_email_provider({siteId})should showprovider: "resend"and the scope you chose.check_sending_domain({siteId, domain})should returnverified: true.- Add yourself as a contact (
create_contact), then send yourself a transactional message withsend_email({siteId, to, from:"hello@your-domain", subject, text, category:"transactional"}). - Check
list_emails({siteId})orget_emailfor the status. The message should also appear in Resend's Emails list. If webhooks are set, a delivered event follows.
Troubleshooting
- "Sender domain is not configured" or "Verify sender DNS with your provider...": the From domain is not in your
domainslist, or the list has a different spelling or case. Re-runconfigure_email_providerwith the exact lowercase domain. - "Verify domain ownership before configuring email.": the domain is not active on your Fondoo site yet. Finish
set_custom_domainandget_domain_statusfirst. - "From must use the site's authenticated domain or the shared sending domain":
check_sending_domainhas not marked the domain verified. With Resend, Fondoo has no DNS records of its own to check, so this check may not pass in the current release. This may differ for your account. If it stays false after the steps above, contact Fondoo support. - "Resend send failed" in the delivery log: often a key with the wrong domain restriction, a revoked key, or a domain that is not verified in Resend. Check the key in Resend and create a new one if needed.
- Webhook calls rejected: the secret in Fondoo does not match the webhook, or you changed the connection scope and the URL changed. Re-copy the secret, re-run
configure_email_provider, and confirm the URL fromget_email_provider. - 429 errors: Resend's default API limit is 10 requests per second per team (API reference). Fondoo already paces sends well below this.
Limits, data and security
- Fondoo sends through a Resend connection at up to one message per second. It retries later when it hits a limit.
- Fondoo stores the credential (API key, domains, webhook secret) encrypted, bound to that connection.
get_email_providernever returns it. - Fondoo keeps a delivery record for each message and suppression entries for hard bounces and complaints. It reads only the event type, message ID and recipient from webhooks.
- To rotate the key: create a new key in Resend, run
configure_email_provideragain with the new key, test, then delete the old key in Resend. - To stop using Resend: run
set_provider({siteId, capability:"email", provider:"builtin"})to go back to Fondoo's built-in delivery, then delete the API key and webhook in Resend.
Official links
- Resend API keys: https://resend.com/docs/dashboard/api-keys/introduction
- Create API key permissions: https://resend.com/docs/api-reference/api-keys/create-api-key
- Domains: https://resend.com/docs/dashboard/domains/introduction
- Add a domain: https://resend.com/docs/add-a-domain
- Webhooks: https://resend.com/docs/webhooks/create-webhook
- Webhook event types: https://resend.com/docs/webhooks/event-types
- Verify webhook requests: https://resend.com/docs/webhooks/verify-webhooks-requests
- API rate limits: https://resend.com/docs/api-reference/introduction
- Pricing: https://resend.com/pricing
