@roucoule/send
v0.1.0
Published
Open-source CLI and library to send Roucoule newsletters via your own SMTP server.
Maintainers
Readme
@roucoule/send
Open-source CLI and library to send Roucoule emails via your own SMTP server.
Roucoule itself is a closed-source SaaS, but this client is open: it handles your SMTP credentials, so you can audit exactly what happens to them. They never leave your machine.
Why this exists
Roucoule never sees your SMTP credentials. This package keeps them on your machine and sends emails directly to your SMTP server, using the Roucoule API only to fetch article content and report delivery results.
Installation
Node (npm)
npm install -g @roucoule/send
# or one-off:
npx @roucoule/send --feed-id feed_xxx art_yyyDeno (JSR)
deno install -gA jsr:@roucoule/sendBoth expose the same roucoule-send command.
Quick start
# First run: interactive wizard for SMTP + API token.
# Saved to ~/.config/roucoule/config.json (mode 0600).
roucoule-send
# Send an article (prepare it as "ready to send" in the Roucoule UI first).
roucoule-send --feed-id feed_xxx art_yyy
# Dry run.
roucoule-send --feed-id feed_xxx --dry-run art_yyyRun roucoule-send --help for full options.
Programmatic use
// Node:
import { createApiClient, createNodemailerSender, send } from "@roucoule/send";
// Deno:
// import { ... } from "jsr:@roucoule/send";
const api = createApiClient("https://roucoule.dev", "rcl_…");
const sender = createNodemailerSender({
host: "mail.example.com",
port: 465,
username: "[email protected]",
password: "…",
});
const result = await send({ api, sender }, "feed_xxx", "art_yyy");
console.log(`Sent ${result.sent}, failed ${result.failed}`);GitHub Action
See examples/github-action.yml.
Deliverability
Whatever you send with, your From: domain needs SPF, DKIM, and DMARC. Test
with mail-tester.com before your first real send.
License
MIT. See LICENSE.
Contributing
Bug reports and small PRs welcome. This package is intentionally minimal — a thin client over the Roucoule API. Feature requests are better directed to the Roucoule service itself.
