feat(mail): add smtp email delivery

This commit is contained in:
Schubert Ferenc 2026-07-04 00:06:20 +02:00
parent faddaa91d0
commit 3456b04ed4
25 changed files with 529 additions and 60 deletions

View file

@ -1,5 +1,6 @@
import { NextResponse } from "next/server";
import { adminConfigurationStatus, appVersion, checkStorage } from "@/lib/runtime/config";
import { getSmtpSettings, isSmtpConfigured } from "@/lib/mail/config";
export async function GET() {
let storage = "ok";
@ -10,11 +11,14 @@ export async function GET() {
storage = "error";
}
const smtpSettings = await getSmtpSettings();
return NextResponse.json({
status: storage === "ok" ? "ok" : "error",
version: appVersion,
storage,
admin: adminConfigurationStatus(),
smtp: isSmtpConfigured(smtpSettings) ? "configured" : "missing",
timestamp: new Date().toISOString(),
});
}