Žiadny popis

Daniel Bohry db4dc21ccc add readme 3 týždňov pred
.github 291de8026d first commit 3 týždňov pred
gradle 291de8026d first commit 3 týždňov pred
src 4b4aacdf63 add log 3 týždňov pred
.gitattributes 291de8026d first commit 3 týždňov pred
.gitignore 291de8026d first commit 3 týždňov pred
Dockerfile 291de8026d first commit 3 týždňov pred
README.md db4dc21ccc add readme 3 týždňov pred
build.gradle 291de8026d first commit 3 týždňov pred
gradlew 291de8026d first commit 3 týždňov pred
gradlew.bat 291de8026d first commit 3 týždňov pred
settings.gradle 291de8026d first commit 3 týždňov pred

README.md

Mail Server

A Spring Boot email service that provides REST API endpoints for sending emails through Gmail SMTP.

Setup

Prerequisites

  • Java 25
  • Gmail account with app-specific password

Environment Variables

email_username=your-gmail@gmail.com
email_password=your-gmail-app-password
auth.api=http://your-auth-service-url

Run

./gradlew bootRun

API

Send Email

POST /api/mail

Headers:

Authorization: Bearer <token>
Content-Type: application/json

Request:

{
  "to": "recipient@example.com",
  "subject": "Subject",
  "content": "Email content"
}

Response: 201 Created

Docker

docker build -t mail-server .
docker run -p 8080:8080 -e email_username=... -e email_password=... mail-server