EmailAPI
static async Task SendMail(CrudAPI api, string subject, string message) { api.ForcePrimarySQL = true; var to = ""; var emailApi = new EmailAPI(api); var mailContent = new EmailAPI.EmailContent() { To = to, Subject = subject, Body = message.Replace(Environment.NewLine, $"<br>{Environment.NewLine}"), BodyIsHtml = true }; var smtpClient = await api.Query<CompanySMTPClient>(); var defaultClient = smtpClient.FirstOrDefault(x => x.Default); if (defaultClient == null) return; await emailApi.Send(defaultClient.KeyStr, mailContent); }
514900cookie-checkUniconta API’s (Email, Report, Utility)