# Resend installation ## Install the package Use Bun first when possible: ```bash bun add @workermailer/resend ``` If your project uses npm: ```bash npm install @workermailer/resend ``` ## Add your API key as a secret ```bash wrangler secret put RESEND_API_KEY ``` If you want a default sender address available across sends, store that too. ```bash wrangler secret put RESEND_FROM ``` ## Minimal Worker config This package uses `fetch`, so you do not need the socket-specific setup required by the SMTP package. A normal Worker deployment is enough as long as outbound HTTPS is available. ## Recommended environment shape ```ts interface Env { RESEND_API_KEY: string; RESEND_FROM?: string; } ``` ## Local development Because the package uses `fetch`, local development is simpler than SMTP. You can still choose to stub delivery in dev mode if you do not want to hit the real API. ```ts if (import.meta.env?.DEV) { console.log('Skipping real Resend send in local development'); return; } ```