32 lines
1.1 KiB
C#
32 lines
1.1 KiB
C#
using System.Collections.Generic;
|
|
using DysonNetwork.Common.Models;
|
|
using NodaTime;
|
|
|
|
namespace DysonNetwork.Pass.Features.Account.Interfaces;
|
|
|
|
public interface INotificationService
|
|
{
|
|
Task UnsubscribePushNotifications(string deviceId);
|
|
Task<NotificationPushSubscription> SubscribePushNotification(
|
|
Models.Account account,
|
|
NotificationPushProvider provider,
|
|
string deviceId,
|
|
string deviceToken
|
|
);
|
|
Task<Notification> SendNotification(
|
|
Models.Account account,
|
|
string topic,
|
|
string? title = null,
|
|
string? subtitle = null,
|
|
string? content = null,
|
|
Dictionary<string, object>? meta = null,
|
|
string? actionUri = null,
|
|
bool isSilent = false,
|
|
bool save = true
|
|
);
|
|
Task DeliveryNotification(Notification notification);
|
|
Task MarkNotificationsViewed(ICollection<Notification> notifications);
|
|
Task BroadcastNotification(Notification notification, bool save = false);
|
|
Task SendNotificationBatch(Notification notification, List<Models.Account> accounts, bool save = false);
|
|
}
|