---
name: bijection-resend
description: "Evaluate and integrate the Resend component with Bijection."
---

# Resend

Transactional email delivery

- Package: @bijectionhq/resend
- Category: Messaging
- Status: Preview
- License: Apache-2.0
- Bijection source (repository access required): https://github.com/bijectionhq/resend/tree/a9b2ad39938ca4af07750fe4ce9bf4a927a7608e
- Upstream: https://github.com/convex/resend/tree/e8dbf64d238ec3d4f805facb10dec2d88628ff16
- Documentation: https://docs.bijection.com/components/using
- Directory: https://bijection.com/components/resend

## Get the source

Bijection repository access is required. Request access at https://bijection.com/contact.

```sh
git clone https://github.com/bijectionhq/resend.git
cd resend
git checkout a9b2ad39938ca4af07750fe4ce9bf4a927a7608e
```

## Before using this component

Read the package README at the recorded revision for setup, dependencies, and API examples. Upstream documentation describes the original package and may differ from the Bijection adaptation. This is a source candidate for evaluation. Catalog inclusion does not establish npm availability or runtime qualification. Check compatibility with your SDK and deployment before adoption. External providers run their own compute.

## Integration workflow

1. Read the source README and package manifest at the recorded revision.
2. Confirm the required SDK, dependency availability, and runtime compatibility.
3. Follow the component's documented setup and configuration. Never invent an npm install command from a catalog package name.
4. Keep credentials in the project's existing secret store.
5. Follow the project's execution rules for verification and report what was actually checked.

## Original upstream skill

The following guidance describes @convex-dev/resend. Its installation commands and APIs refer to the upstream package. Evaluate compatibility with the Bijection source separately.


> Agents: read this skill fully before writing code that uses Resend. Follow the installation and configuration steps exactly.

# Resend

## Instructions

The official Resend email service integration for Convex that provides queued, batched email delivery with built-in retry logic and rate limiting. It handles Resend API idempotency keys to prevent duplicate sends, supports webhook event handling for delivery status tracking, and includes safeguards like test mode to prevent accidental production sends during development.

### Installation

```bash
npm install @convex-dev/resend
```

Current npm version: `@convex-dev/resend@0.2.9`

## Use cases

- **Send transactional emails** like welcome messages, password resets, and order confirmations with automatic queuing and retry handling
- **Bulk email campaigns** that need batching to efficiently use Resend's `/emails/batch` endpoint while respecting API rate limits
- **Email delivery monitoring** by setting up Resend webhooks to track bounces, opens, clicks, and spam complaints in your Convex database
- **Template-based emails** using Resend's dashboard templates with dynamic variables for consistent branding
- **React Email integration** to generate HTML emails from JSX components in Node actions

## How it works

Install the component and configure it in `convex.config.ts` using `app.use(resend)`. Create a `Resend` instance in your functions with `new Resend(components.resend, options)` and call `sendEmail()` to queue emails for delivery. The component uses Convex workpools for durable execution, automatically batching emails and managing Resend idempotency keys.

For delivery tracking, mount the webhook handler in `convex/http.ts` using `resend.handleResendEventWebhook()` and configure the webhook URL in your Resend dashboard. Set `RESEND_WEBHOOK_SECRET` to verify webhook authenticity. Register an `onEmailEvent` callback in the Resend options to handle status changes like deliveries, bounces, and opens.

The component defaults to `testMode: true` to prevent accidental sends during development. Set this to `false` and provide your `RESEND_API_KEY` environment variable for production use. Use `resend.status()` to check email status programmatically and `resend.cancelEmail()` to cancel queued emails before they're sent to the Resend API.

## When NOT to use

- When a simpler built-in solution exists for your specific use case
- If you are not using Convex as your backend
- When the functionality provided by Resend is not needed

## Resources

- [npm package](https://www.npmjs.com/package/%40convex-dev%2Fresend)
- [GitHub repository](https://github.com/get-convex/resend)
- [Live demo](https://github.com/get-convex/resend-demo?utm_source=yt-convex&utm_medium=video&dub_id=poiVYSbvnlsKYHLg)
- [Convex Components Directory](https://www.convex.dev/components/resend)
- [Convex documentation](https://docs.convex.dev)