A remarkably simple and lightweight HTTP API for sending emails.
Emails are sent through a local SMTP server at port 25 (tested with Postfix).
http-mailer 0.1.0
Mubelotix <[email protected]>
USAGE:
http-mailer [OPTIONS]
OPTIONS:
-a, --addr <ADDR> Address to listen on [default: localhost:8000]
-c, --cert <CERT> Path to ssl certicate
-h, --help Print help information
-k, --api-key <API_KEY> Hashed api key (with sha256)
-p, --privkey <PRIVKEY> Path to ssl private key
-V, --version Print version information
POST /send-email HTTP/2
Api-Key: password
From: [email protected]
To: [email protected]
Reply-To: [email protected]
Subject: Testing email
This is the body
POST /send-email HTTP/2
Api-Key: password
From: [email protected]
To: [email protected]
Reply-To: [email protected]
Subject: Testing email
This is a text message.
-----END-TEXT-BEGIN-HTML-----
<p>This is a text <i>message<i>.<p>