resend-node

The official Node.js and TypeScript SDK for sending email through the Resend API.

SDK
npm
v6.20.0
943stars
MIT License

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
87/100Excellent
Development Activity100
Maintenance100
Community52
Maturity56
Momentum40

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
86/100Excellent
Architecture85
Code Quality88
Innovation80
Learning Curve90

Resend’s official Node.js SDK is a fully typed client for the Resend email API, letting you send transactional and marketing email with a few lines of code. It wraps every Resend endpoint — emails, batches, broadcasts, domains, contacts, audiences/segments, API keys, webhooks, and more — behind a single ergonomic Resend class.

Beyond plain text and HTML, the SDK can render React email components to HTML at send time via @react-email/render, so you can author templates as JSX and ship them without a separate build step. It targets modern Node.js (>=20), ships dual ESM/CJS builds, and returns a consistent { data, error } shape on every call.

What You Get

  • A single typed Resend client exposing every Resend API resource (emails, batch, broadcasts, domains, contacts, segments, API keys, webhooks, templates, and more).
  • First-class React email support that renders JSX templates to HTML at send time via the optional @react-email/render peer dependency.
  • A consistent { data, error } return shape on every call, so failures are handled as values rather than thrown exceptions.
  • Dual ESM/CJS builds with bundled .d.ts type declarations and idempotency-key support for safe retries.

Common Use Cases

  • Sending transactional email such as sign-up confirmations, password resets, and receipts from a Node.js backend.
  • Delivering marketing broadcasts and managing contacts, segments, and suppressions programmatically.
  • Rendering React Email components to HTML and sending them directly without a separate template pipeline.

Under The Hood

Architecture — The public surface is a single Resend class in src/resend.ts that holds a base URL, user agent, and an auth Headers object, then instantiates one resource controller per API area (Emails, Batch, Broadcasts, Domains, Contacts, Segments, ApiKeys, Webhooks, and more) as readonly fields. Each controller receives the Resend instance and calls its shared post/get/put/patch/delete helpers, which funnel into one fetchRequest method wrapping the native fetch; that method normalizes every outcome into a { data, error, headers } response so errors are returned as values. React templates are rendered to HTML in src/render.ts, which lazily imports @react-email/render only when a react payload is supplied.

Tech Stack — Written in TypeScript targeting Node.js >=20, with a build via tsdown producing dual ESM/CJS output plus .d.ts declarations. Runtime dependencies are minimal: postal-mime for inbound email parsing and standardwebhooks for webhook verification, with @react-email/render as an optional peer dependency. Tooling uses Biome for lint/format, Vitest for tests, and PollyJS for recorded HTTP fixtures.

Code Quality — Testing is thorough: 36 *.spec.ts files sit alongside the source, plus integration specs backed by recorded HAR fixtures under __recordings__ and a separate e2e/ suite. Each resource is split into a controller plus a dedicated interfaces/ directory, giving strong type coverage and consistent naming. Error handling is deliberate — fetchRequest distinguishes JSON API errors, malformed responses, and network failures, returning a typed ErrorResponse in each case.

API Design — The developer experience is a highlight: a two-line setup (new Resend(key) then resend.emails.send(...)) gets you sending, method names mirror REST verbs and resource names, and the uniform { data, error } return removes try/catch boilerplate. All request and response types are exported from the package root, the README documents text, HTML, and React flows, and idempotency keys are a first-class option for safe retries.

Used by 39 apps in this directory

TypeScript
100%
MIT

Botpress

AI Assistants · AI Development · Customer Support

14,872

The open-source hub for building and deploying LLM-powered AI agents with TypeScript-first tooling, 40+ integrations, and a revolutionary code-execution agent framework.

View details
95
Repo Health
82
Technical
66
Dependency
Built with
TypeScript100%
Updated yesterday
TypeScript
99%
Apache 2.0

Bubble Lab

Automation · AI Development

1,095

Open-core workflow engine for building AI-powered automations in TypeScript that run natively inside Slack — no context switching required.

View details
35
Repo Health
78
Technical
72
Dependency
Built with
TypeScript99%
Updated 3 months ago
TypeScript
55%
Other

Cap

Team Chat · Video Conferencing

20,986

Open source Loom alternative with GPU-accelerated recording, instant share links, AI summaries, and full self-hosting via Docker Compose.

View details
89
Repo Health
81
Technical
65
Dependency
Built with
TypeScript55%
Rust40%
Updated yesterday
Swift
64%
GPL 3.0

cmux

Developer Tools · AI Development

26,221

A native, Ghostty-based macOS terminal with vertical tabs, agent-aware notifications, and a scriptable browser built for running many parallel AI coding agent sessions instead of juggling tmux panes.

View details
84
Repo Health
81
Technical
72
Dependency
Built with
Swift64%
Rust14%
Updated today
TypeScript
92%
MIT

Dittofeed

Marketing · Automation

2,903

Open-source omni-channel customer engagement platform for automating transactional and marketing messages via email, SMS, WhatsApp, Slack, and mobile push.

View details
54
Repo Health
75
Technical
63
Dependency
Built with
TypeScript92%
Updated 4 months ago
TypeScript
92%
AGPL 3.0

Documenso

Digital Signiture

14,603

Self-hosted, open-source DocuSign alternative with legally binding PDF signatures, multi-party workflows, and a full REST and tRPC API.

View details
93
Repo Health
79
Technical
72
Dependency
Built with
TypeScript92%
Updated today
TypeScript
99%
Other

Dokploy

Devops · Hosting Control Panel · Security

36,702

Self-hosted PaaS that deploys apps and databases on your own VPS using Docker, Traefik, and multi-build-system orchestration

View details
89
Repo Health
76
Technical
65
Dependency
Built with
TypeScript99%
Updated yesterday
TypeScript
100%
Other

Dub

Marketing · Analytics

24,521

The open-source link attribution platform for short links, conversion tracking, and affiliate programs — powering 100M+ clicks monthly.

View details
81
Repo Health
78
Technical
65
Dependency
Built with
TypeScript100%
Updated today
TypeScript
96%

Finance

AI Assistants · Invoicing Finance

890

Bloomberg-grade financial data and AI-powered analysis through a conversational chat interface you can self-host.

View details
62
Repo Health
62
Technical
71
Dependency
Built with
TypeScript96%
Updated 1 weeks ago

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search