using FrameworkDAL.DTO.SystemJob; using GB5Shared.DTO.Framework.Login; using System.Threading; using System.Threading.Tasks; namespace FrameworkBLL.SystemJob { /// /// Notifies a job's completion via its DeliveryChannel. Email and WhatsApp are real sends, /// routed through IEIPResponseEngine (same channel-handler chain EIPOtpService already uses /// live for OTP delivery — no DI gap there). AppChat writes a real TNOTIFICATION bell/inbox /// entry and sends a real Firebase push (best-effort — silently no-ops for a user with no /// registered device token, same as every other push caller in this codebase); the SignalR /// JobCompleted/JobFailed push already happens unconditionally elsewhere and is not duplicated /// here. SMS remains log-only: no real provider is configured anywhere in this system (Twilio /// credentials/TwilioClient.Init are both absent). /// Never throws — a dispatch failure must never fail the job it's reporting on. /// public interface ISysJobNotificationDispatcher { Task DispatchAsync( int sysJobId, int sysJobRunId, SysJobDeliveryChannel channel, string destination, int submittedById, int runStatus, LoginDTO loginDTO, CancellationToken cancellationToken = default); } }