An AI workflow layer for SnappyMail, the lightweight webmail client.
SnappyPilot extends SnappyMail with drafting, rewriting, translation and email context assistance through OpenRouter. The foundation for agentic email orchestration, starting with compose and reply: you review the output and control what gets sent.
PHP + vanilla JavaScript. A self-contained plugin, with no frontend framework or Node.js runtime on the server.
Requires SnappyMail 2.38.2, PHP 8.4 with cURL, Git and sudo access.
After editing the live plugin, see refresh.md to force the UI to pick up JS/CSS changes.
You can clone the repo anywhere temporary on the VPS. Use /tmp/snappy-pilot, then install the plugin into SnappyMail’s real plugin folder.
Run this entire block on your VPS:
cd /tmp && \
rm -rf snappy-pilot && \
git clone --depth 1 https://github.com/juansebsol/snappy-pilot.git && \
cd snappy-pilot && \
mkdir -p dist/snappy-pilot && \
cp -a index.php lib js css LICENSE README.md DEPLOY.md docs dist/snappy-pilot/ && \
sudo apt-get update && \
sudo apt-get install -y rsync && \
sudo bash scripts/deploy.sh \
--root /var/lib/snappymail-data/_data_/_default_/plugins \
--owner www-data \
--group www-data \
--applyThis clones the repository, assembles the plugin files and installs them here:
/var/lib/snappymail-data/_data_/_default_/plugins/snappy-pilot
Open SnappyMail Admin:
Extensions → SnappyPilot → Enable
Then open its settings, enter your OpenRouter API key and model ID, turn on Enable SnappyPilot, and save. The default API base URL is https://openrouter.ai/api/v1. Reload webmail.
In Compose or Reply, type / on a new line or click ✦ Pilot. Draft replies, improve writing, change tone, translate, summarize available email context or give a custom instruction.
Select text to edit just that passage. Choose Generate, review the result, then Replace, Insert below or Discard. The API key stays server-side; email content is shared only when you request generation.
PHP 8.4, Node.js 20+ and npm:
npm ci
npm test
npm run packageThe release goes in dist/snappy-pilot/; packaging requires that folder to be absent. Plugin code lives in index.php, lib/, js/ and css/.
- Developer guide — architecture, configuration and test setup.
- SnappyMail integration — verified APIs and editor boundaries.
- Validation — test coverage and remaining live checks.
- Deployment reference — verification, updates and uninstall.