Skip to content

Phase 2a: Resend fallback and production binding - #1917

Merged
neuromechanist merged 4 commits into
feature/issue-1893-epic-email-cffrom
feature/issue-1895-phase2a-fallback
Oct 24, 2026
Merged

neuromechanist merged 4 commits into
feature/issue-1893-epic-email-cffrom
feature/issue-1895-phase2a-fallback

Conversation

@neuromechanist

Copy link
Copy Markdown
Contributor

Summary

  • sendEmail falls back to Resend once, only when Cloudflare refuses with a code that certainly sent nothing and that Resend can answer (E_RATE_LIMIT_EXCEEDED, E_DAILY_LIMIT_EXCEEDED, E_ACCOUNT_SUSPENDED, E_SENDER_DOMAIN_NOT_AVAILABLE), EMAIL_FALLBACK is resend, and a Resend key is set. A suppressed recipient, a validation, header or delivery error, a timeout, an internal or unknown error, and a configuration error never fall back. Staging never sets EMAIL_FALLBACK, so staging still cannot reach Resend.
  • Production gets the send_email binding restricted to [email protected] and [email protected], but no EMAIL_PROVIDER: it keeps sending through Resend until the flip, after the Cloudflare limit increase and a clean staging soak (maintainer decision, 2026-10-23).

Part of #1895, epic #1893.

Test plan

  • backend/test/email-provider.test.ts 62 tests: each fallback code reaches the Resend stand-in exactly once with the [DEV] subject; every non-fallback case does not; gate variants; fence before either provider
  • Targeted email suites 112 pass; full backend suite 8363 pass, 0 fail
  • bun run typecheck, bun run lint

🤖 Generated with Claude Code

@github-actions

github-actions Bot commented Oct 24, 2026 •

Copy link
Copy Markdown

📦 Package Preview

Your package is ready to test!

bun install -g nemar-cli@PR1917

Version: 0.10.24-PR1917.262b0d5
Commit: 262b0d5


🤖 Updated on each push.

@neuromechanist
neuromechanist merged commit c318ccc into feature/issue-1893-epic-email-cf Oct 24, 2026
14 checks passed
@neuromechanist
neuromechanist deleted the feature/issue-1895-phase2a-fallback branch October 24, 2026 06:44

This branch was previously deployed

1 inactive deployment
npm — 262b0d59 Deployed Oct 24, 2026 by neuromechanist via publish #3830
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant