npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

nodebb-plugin-emailer-cloudflare

v0.1.0

Published

Send NodeBB emails through Cloudflare Email Sending REST API. No SMTP required. Includes admin UI, credential verification, test email, safety policies, and rate limiting.

Readme

nodebb-plugin-emailer-cloudflare

Send all NodeBB emails through Cloudflare Email Sending using their REST API -- no SMTP server required.

Drop-in replacement for NodeBB's default email transport. Configure your Cloudflare API token, and every notification, password reset, and digest email is delivered through Cloudflare's infrastructure.

Features

  • Zero SMTP configuration -- uses Cloudflare's REST API directly
  • Admin panel UI -- guided setup with auto-detect for your Account ID
  • Credential verification -- test your API token from the admin panel before going live
  • Send test email -- confirm end-to-end delivery right from the settings page
  • From address & name overrides -- optionally override NodeBB's default sender identity
  • Reply-To support -- set a default reply-to address for all outgoing mail
  • CC, BCC, and attachments -- full support for all email features
  • Safety policies -- sender allowlist, recipient allowlist/denylist to prevent accidental sends
  • Rate limiting -- configurable per-minute and per-day send limits (enforced locally)
  • Detailed error reporting -- structured Cloudflare API errors surfaced in NodeBB logs

Requirements

  • NodeBB 3.2.x or 4.x
  • Node.js 18 or later (uses native fetch)
  • A Cloudflare account with Email Sending enabled
  • A domain onboarded for Email Sending in your Cloudflare dashboard
  • A Cloudflare API token with Email Sending: Edit permission

Installation

From npm

cd /path/to/nodebb
npm install nodebb-plugin-emailer-cloudflare
./nodebb build
./nodebb restart

From GitHub

cd /path/to/nodebb/node_modules
git clone https://github.com/jameswross2003/nodebb-plugin-emailer-cloudflare.git
cd .. && ./nodebb build && ./nodebb restart

Then activate the plugin in Admin > Extend > Plugins.

Setup

1. Onboard your sending domain

In the Cloudflare dashboard, navigate to Build > Email Service > Email Sending and click + Onboard Domain. Add the domain your forum sends from (e.g. example.com for [email protected]). This must be completed before emails can be sent.

2. Create an API token

Go to Profile > API Tokens and create a custom token with:

| Setting | Value | |---------|-------| | Permissions | Account -- Email Sending -- Edit | | Permissions | Account -- Account Settings -- Read (for auto-detect) | | Account Resources | Include -- your account |

3. Configure the plugin

In NodeBB, go to Admin > Plugins > Emailer (Cloudflare):

  1. Paste your API token and click Save
  2. Click Detect next to the Account ID field to auto-fill it, then Save again
  3. Click Verify Credentials to confirm the token is valid
  4. Enter your email address and click Send Test to verify delivery

Configuration Options

| Field | Required | Description | |-------|----------|-------------| | API Token | Yes | Cloudflare API token with Email Sending permission | | Account ID | Yes | Your Cloudflare account ID (auto-detected or from dashboard sidebar) | | From Address | No | Override NodeBB's configured sender address | | From Name | No | Override NodeBB's configured sender name | | Reply-To | No | Default reply-to address when NodeBB doesn't provide one |

Safety Policies

Optional safeguards that run locally before any email reaches Cloudflare:

  • Allowed From -- Comma-separated domains or addresses. When set, only matching senders can send. Prevents accidental sender spoofing.
  • Recipient Allowlist -- Only these domains/addresses can receive mail. Ideal for staging environments.
  • Recipient Denylist -- Block specific domains/addresses. Ignored when an allowlist is active.
  • Rate Limits -- Per-minute and per-day caps. Set to 0 to disable.

Troubleshooting

| Symptom | Fix | |---------|-----| | "Missing Cloudflare account ID or API token" | Save both fields in the admin panel | | Verify fails with 403 | Regenerate your token with the correct permissions | | Test email fails but verify succeeds | Your domain may not be onboarded -- check Email Sending in Cloudflare | | "Sender not permitted" error | Add your from address/domain to the Allowed From policy field | | Rate limit errors in logs | Increase or disable the per-minute/per-day limits |

Compatibility

This plugin is compatible with NodeBB's plugin system and follows the same patterns as the official emailer plugins (SendGrid, Mailgun, Mandrill). It hooks into static:email.send and transparently replaces the default email transport.

License

MIT