public WebPushService(KillerContext context, IConfiguration configuration, WebPushClient webPushClient, ILogger <WebPushService> logger)
 {
     _context       = context;
     _configuration = configuration;
     _webPushClient = webPushClient;
     _logger        = logger;
 }
Ejemplo n.º 2
0
 public async Task SendNotificationAsync(PushSubscription subscription, string payload, VapidDetails vapidDetails)
 {
     WebPush.WebPushClient client = new WebPush.WebPushClient();
     await client.SendNotificationAsync(subscription, payload, vapidDetails);
 }