Sending Email
Holamail is a lightweight SMTP listener. It accepts the basic SMTP commands HELO/EHLO, MAIL FROM, RCPT TO, DATA, and QUIT, then logs the message. It does not deliver email to external recipients.
Connection Details
| Parameter | Public test host | Local instance |
|---|---|---|
| Host | smtp.testmail.hola.cloud |
localhost |
| Port | 25 |
2525 |
| Encryption | None | None |
| Authentication | None | None |
Holamail does not support STARTTLS or SMTP AUTH.
SMTP Protocol Flow
The raw SMTP conversation follows this sequence:
1HELO client.example.com
2MAIL FROM:<noreply@example.com>
3RCPT TO:<user@example.com>
4DATA
5Subject: Hello from Holamail
6
7This message will be logged by Holamail.
8.
9QUIT
Examples
Using curl
1curl --url smtp://smtp.testmail.hola.cloud:25 \
2 --mail-from noreply@example.com \
3 --mail-rcpt user@example.com \
4 --upload-file email.txt
Where email.txt contains:
1Subject: Hello from Holamail
2
3This message will be logged by Holamail.
Plain TCP Session
1telnet localhost 2525
Then enter:
1HELO client.example.com
2MAIL FROM:<noreply@example.com>
3RCPT TO:<user@example.com>
4DATA
5Subject: Local Holamail test
6
7Hello from a local Holamail listener.
8.
9QUIT
Using Go's net/smtp
1package main
2
3import (
4 "log"
5 "net/smtp"
6)
7
8func main() {
9 to := []string{"user@example.com"}
10 msg := []byte("To: user@example.com\r\n" +
11 "Subject: Hello from Holamail\r\n" +
12 "\r\n" +
13 "This message will be logged by Holamail.\r\n")
14
15 err := smtp.SendMail("smtp.testmail.hola.cloud:25", nil,
16 "noreply@example.com", to, msg)
17 if err != nil {
18 log.Fatal(err)
19 }
20}
Using Python's smtplib
1import smtplib
2from email.message import EmailMessage
3
4msg = EmailMessage()
5msg.set_content("This message will be logged by Holamail.")
6msg["Subject"] = "Hello from Holamail"
7msg["From"] = "noreply@example.com"
8msg["To"] = "user@example.com"
9
10with smtplib.SMTP("smtp.testmail.hola.cloud", 25) as server:
11 server.send_message(msg)
Expected Behavior
Holamail accepts syntactically valid SMTP input and logs the message. It is useful for confirming that an application can speak SMTP without sending real email.
Unsupported features include external delivery, HTTP APIs, STARTTLS, AUTH, rate limiting, templates, analytics, and tracking.
Comments