Skip to Content
sesameSend

Local development

Run the API and dashboard on your machine.

You need Node 20 or newer, pnpm, a Supabase project and an AWS account.

git clone <your repository URL> sesamesend && cd sesamesend
pnpm install
cp .env.example .env

Fill in .env as you go; every variable is documented in that file. Then:

  1. Create the Supabase project, apply the schema. See Supabase.

  2. Create the AWS resources. See AWS setup.

  3. Set UNSUBSCRIBE_SECRET (openssl rand -base64 32 | tr -d '\n'), PUBLIC_BASE_URL (http://localhost:3000) and DASHBOARD_LOGIN_FROM.

  4. Create your first team and key:

    node --env-file=.env scripts/bootstrap.mjs "My team" you@example.com

    This writes OPENSEND_API_KEY and CRON_SECRET to .env and never prints the key. It also makes you the team owner, so you can sign in to the dashboard.

  5. Run it:

    pnpm dev

    Open http://localhost:3000/login. Only invited addresses get a sign-in link.

Background jobs

Scheduled sends, webhook delivery, broadcasts, automations, SES events and inbound mail run from six /internal/* endpoints. Locally, run the cron runner in a second terminal:

node --env-file=.env scripts/cron-runner.mjs

Without it, scheduled mail and webhooks sit still. See Vercel and background jobs.

Test without sending

  • Simulator addresses at resend.dev (delivered, bounced, complained, suppressed) are answered locally.
  • pnpm check:offline runs the offline checks: no database, AWS or email needed.
  • RESEND_BASE_URL=http://localhost:3000 TEST_TO=you@example.com node --env-file=.env scripts/compat-send.mjs sends real mail through the official SDK. Point it at a test Supabase project, not production.

Webhooks to localhost

Webhook endpoints must be https URLs. By default webhooks cannot reach private IP addresses. For a receiver on your own network, set OPENSEND_WEBHOOK_ALLOW_PRIVATE=1. It is for development and is ignored in production.