44 lines
1.1 KiB
C#
44 lines
1.1 KiB
C#
namespace MiaoJiZhang.Api.Contracts;
|
|
|
|
public record PushPreferencesResponse(bool System, bool Budget, bool Operations);
|
|
public record UpdatePushPreferencesRequest(bool System, bool Budget, bool Operations);
|
|
|
|
public record RegisterPushDeviceRequest(
|
|
string Provider,
|
|
string Token,
|
|
string PackageName,
|
|
string Flavor,
|
|
string AppVersion,
|
|
int VersionCode,
|
|
bool NotificationsAllowed);
|
|
|
|
public record PushDeviceRegistrationResponse(
|
|
long DeviceId,
|
|
string InstallationId,
|
|
string Provider,
|
|
bool Active,
|
|
string UnbindToken);
|
|
|
|
public record CreatePushCampaignRequest(
|
|
string Title,
|
|
string Body,
|
|
string Category,
|
|
string Action = "none",
|
|
string? EntityId = null,
|
|
string Flavor = "production",
|
|
string? Provider = null,
|
|
int? MinVersionCode = null,
|
|
int? MaxVersionCode = null,
|
|
long? TargetUserId = null,
|
|
int? TtlSeconds = null);
|
|
|
|
public record SchedulePushCampaignRequest(DateTime? ScheduledAt = null);
|
|
|
|
public record TestPushRequest(
|
|
long DeviceId,
|
|
string Title,
|
|
string Body,
|
|
string Category = "system",
|
|
string Action = "none",
|
|
string? EntityId = null);
|