Questions · Published 2026-11-29 · Updated 2026-11-29 · AgentiSend
Resend vs Nodemailer
Resend vs Nodemailer is a delivery service beside a Node.js library: Resend sends the message, and Nodemailer only builds it and hands it to a transport.
The two are used together. Nodemailer does not replace Resend, and Resend is not a Node.js package you import in place of Nodemailer.
We read Nodemailer's homepage, npm, Resend's Nodemailer page, and Resend's SMTP page on 28 November 2026. We make AgentiSend. The install for our transport stays on the Nodemailer guide. Prices stay on AgentiSend vs Resend.
What each one is
Nodemailer describes itself as an email sending library for Node.js. The homepage, read on 28 November 2026, lists SMTP, Sendmail, and streams among its transports. npm returned nodemailer at 10.6.1 that day. The README at tag v10.6.1 says that release targets Node.js 20 and later. The license field on that npm version is MIT-0.
Resend's documented way to use that library is SMTP. The Nodemailer page requires an API key and a verified domain, then sets host smtp.resend.com, port 465, username resend, and the API key as the password. The SMTP page lists five ports: 25, 465, 587, 2465, and 2587. It calls 465 and 2465 implicit TLS, and 25, 587, and 2587 STARTTLS. The same page says the rate limit on SMTP is the same as the API. The API introduction, read the same day, says the default maximum is 10 requests per second per team.
The only repository under the Resend GitHub organization whose name contains Nodemailer is resend/resend-nodemailer-smtp-example. GitHub reported its last push as 23 November 2026. Its index.ts uses the same host, port, and username as the docs page. Its package.json depends on nodemailer at latest and is marked private. A repository search for nodemailer in org:resend returned that one repository.
The same send
This is the program on Resend's Nodemailer page. The addresses onboarding@resend.dev and delivered@resend.dev are theirs. An address at resend.dev is not a test address on our API: a send to it is a real send. Our stand-in for delivered@resend.dev is delivered@simulator.agentisend.com, listed on test addresses.
import nodemailer from 'nodemailer';
const transporter = nodemailer.createTransport({
host: 'smtp.resend.com',
secure: true,
port: 465,
auth: {
user: 'resend',
pass: 're_xxxxxxxxx',
},
});
const info = await transporter.sendMail({
from: 'onboarding@resend.dev',
to: 'delivered@resend.dev',
subject: 'Hello World',
html: '<strong>It works!</strong>',
});
console.log('Message sent: %s', info.messageId);Source: Send emails using Nodemailer with SMTP, fetched 28 November 2026. The password in that page's sample is re_xxxxxxxxx.
The same sendMail call through our transport posts the message to POST /emails. GET /emails/{id} reads it back. POST /api-keys creates the key the transport sends. npm listed nodemailer-agentisend-transport at 0.1.1 on 28 November 2026. That published package.json requires Node.js 20 or later and nodemailer 6.9.0 or later. info.messageId is the id from the POST /emails response.
npm install nodemailer nodemailer-agentisend-transportimport nodemailer from 'nodemailer';
import { createTransport } from 'nodemailer-agentisend-transport';
const transporter = nodemailer.createTransport(createTransport());
const info = await transporter.sendMail({
from: process.env.MAIL_FROM,
to: 'delivered@simulator.agentisend.com',
subject: 'Hello World',
html: '<strong>It works!</strong>',
});
console.log(info.messageId);createTransport() reads AGENTISEND_API_KEY. It reads AGENTISEND_BASE_URL when that variable is set, and otherwise uses https://api.agentisend.com. MAIL_FROM has to be an address on a domain you have verified. The simulator recipient does not have to be.
curl -sS -X POST https://api.agentisend.com/emails \
-H "Authorization: Bearer $AGENTISEND_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{"from":"billing@yourdomain.com","to":"delivered@simulator.agentisend.com","subject":"Your receipt","text":"Thanks — the details are attached."}'201
{
"id": "9c8f8f0e-3d1a-4d3f-9a1e-2b7c1a0f5e42",
"simulated": true,
"warnings": []
}curl -sS -X GET https://api.agentisend.com/emails/9c8f8f0e-3d1a-4d3f-9a1e-2b7c1a0f5e42 \
-H "Authorization: Bearer $AGENTISEND_API_KEY"200
{
"api_key_id": "example",
"attachments": [],
"bcc": [],
"cc": [],
"created_at": "2026-09-04T09:14:00.000Z",
"domain": "example",
"from": "example",
"headers": {},
"html": "example",
"id": "9c8f8f0e-3d1a-4d3f-9a1e-2b7c1a0f5e42",
"last_event": "queued",
"message_id": "example",
"object": "email",
"provider_message_id": "example",
"reply_to": [],
"scheduled_at": "2026-09-04T09:14:00.000Z",
"status": "queued",
"subject": "example",
"tags": {},
"template_id": "9c8f8f0e-3d1a-4d3f-9a1e-2b7c1a0f5e42",
"template_version": -9007199254740991,
"text": "example",
"to": [],
"updated_at": "2026-09-04T09:14:00.000Z",
"warnings": []
}curl -sS -X POST https://api.agentisend.com/api-keys \
-H "Authorization: Bearer $AGENTISEND_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{"name":"example","permission":"full_access"}'201
{
"budget_per_period": 5000,
"created_at": "2026-09-04T09:14:00.000Z",
"domain_scope": "example",
"expires_at": "2026-09-04T09:14:00.000Z",
"id": "9c8f8f0e-3d1a-4d3f-9a1e-2b7c1a0f5e42",
"inboxes": [],
"last_used_at": "2026-09-04T09:14:00.000Z",
"loop_guard": "off",
"name": "example",
"object": "api_key",
"period": "monthly",
"permission": "full_access",
"previous_key_expires_at": "2026-09-04T09:14:00.000Z",
"rate_ceiling_per_minute": 600,
"request_count_30d": -9007199254740991,
"rotated_at": "2026-09-04T09:14:00.000Z",
"scopes": [],
"system": false,
"token": "as_abababababababababababababababababababababababababababababababab",
"token_prefix": "as_abababab"
}A refused request carries code, message, and fix. The transport throws an error whose fix is that field. The error catalogue lists every code.
Side by side
| Nodemailer | Resend, via Nodemailer | AgentiSend transport | |
|---|---|---|---|
| What it is | Library. npm nodemailer 10.6.1 on 28 November 2026 | Delivery service. The Nodemailer page sends over SMTP | npm nodemailer-agentisend-transport 0.1.1, posting to POST /emails |
| Who accepts the message | The transport you configure | smtp.resend.com | https://api.agentisend.com |
| Host, port, username | Yours. Their sample uses port 465 and username resend | smtp.resend.com, port 465, username resend. Other ports are on the SMTP page | No SMTP host. The key is the Bearer token |
| Password | Whatever that server asks for | The Resend API key | The AgentiSend API key, in AGENTISEND_API_KEY |
info.messageId | Whatever the transport returns | Logged in their sample. This page does not describe that server's id format | The id from POST /emails |
| Idempotency | Not a Nodemailer feature | SMTP header Resend-Idempotency-Key (SMTP page). API keys expire after 24 hours (Send Email) | The package does not set an Idempotency-Key HTTP header. The API keeps one for 7 days when the caller sends it (the same email twice) |
| Rate | The server's | Same as the API: 10 requests per second per team | 600 requests in 60 seconds on a new key (rate limits) |
| Recipients on one send | The server's | to is max 50 on the Send Email page | 50 |
SMTP on this API
The status page reports Outgoing mail as not offered until smtp.agentisend.com is published. Until that line says the host is up, use the transport above.
When the host is up, the SMTP guide is the source for the settings: port 587 or 465, username agentisend, password an API key with permission to send. A header named Idempotency-Key, Resend-Idempotency-Key, X-Entity-Ref-ID, or Message-ID is how that host dedupes a retry. Those header names are the SMTP guide's, and they are not what nodemailer-agentisend-transport sends. The package puts custom headers in the JSON headers object and sets four HTTP headers of its own: authorization, accept, content type, and user agent.
FAQ
Is Nodemailer the same as Resend?
No. Nodemailer is the Node.js library at https://nodemailer.com/. npm returned version 10.6.1 on 28 November 2026. Resend is the service that accepts mail. Resend's Nodemailer page sends through smtp.resend.com.
Can I use Nodemailer with Resend?
Yes. Install nodemailer, then create a transport with host smtp.resend.com, port 465, username resend, and the API key as the password. That page also requires an API key and a verified domain. The sample program is in the section above, and the example repository is https://github.com/resend/resend-nodemailer-smtp-example.
Does Nodemailer deliver the email?
Nodemailer builds the message and hands it to a transport. The homepage lists SMTP, Sendmail, and streams among them. With none configured, nothing is delivered.
What SMTP ports does Resend document?
The Nodemailer page uses port 465. The SMTP page also lists 25, 587, 2465, and 2587. It calls 465 and 2465 implicit TLS, and 25, 587, and 2587 STARTTLS. The username on both pages is resend.
Can Nodemailer send through AgentiSend?
Yes, with nodemailer-agentisend-transport, which posts each message to POST /emails. The SMTP host smtp.agentisend.com is a second path, and the status page reports Outgoing mail as not offered until that host is published. The install steps are on the Nodemailer guide at /docs/guides/nodemailer.
Does the transport package dedupe a retry?
No. The published package does not send an Idempotency-Key HTTP header, so a second sendMail is a second POST /emails. The API does dedupe when that header is present. The SMTP host, once it is published, dedupes from the four header names in the SMTP guide.
Next
- Send email with Nodemailer
- Send through SMTP
- Test addresses
- Resend API docs
- AgentiSend API docs
- AgentiSend vs Resend
- Resend MCP server and AgentiSend MCP server, for a caller that does not import Nodemailer
- Email MCP server
- Resend skills and AgentiSend skills
- React Email MCP
- Resend llms.txt and AgentiSend llms.txt
- Email for AI agents