feat: add test button to create channel form using ad-hoc smtp test endpoint
- Add TestSmtpCommand and TestSmtpHandler for ad-hoc smtp testing without saving - Add POST /admin/channels/test-smtp endpoint accepting raw smtp settings - Show Test button on both Create and Edit forms - Test reads current form values so channel can be tested before saving
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
using HrynCo.NotificationService.Services.Core;
|
||||
using MediatR;
|
||||
|
||||
namespace HrynCo.NotificationService.Services.EmailChannels.TestSmtp;
|
||||
|
||||
/// <summary>
|
||||
/// Sends a test email using the provided SMTP settings without persisting anything.
|
||||
/// </summary>
|
||||
public sealed record TestSmtpCommand(
|
||||
string Host,
|
||||
int Port,
|
||||
string Username,
|
||||
string Password,
|
||||
bool UseSsl,
|
||||
string FromEmail,
|
||||
string FromName,
|
||||
string ToEmail
|
||||
) : IRequest<ServiceResult<Core.Unit>>;
|
||||
Reference in New Issue
Block a user