YD_TrainingCompetition_Api/Models/DeviceTelemetry.cs

46 lines
1.2 KiB
C#
Raw Normal View History

2026-06-10 11:16:46 +08:00
using System.Text.Json.Serialization;
2026-06-02 10:30:05 +08:00
namespace YD_TrainingCompetition_Api.Models;
public sealed class DeviceTelemetry
{
[JsonPropertyName("deviceId")]
public string DeviceId { get; set; } = string.Empty;
[JsonPropertyName("counter")]
public int Counter { get; set; }
[JsonPropertyName("bsName")]
public string? BsName { get; set; }
[JsonPropertyName("athleteName")]
public string? AthleteName { get; set; }
[JsonPropertyName("school")]
public string? School { get; set; }
[JsonPropertyName("errorCount")]
public int? ErrorCount { get; set; }
[JsonPropertyName("battery")]
public int? Battery { get; set; }
2026-06-10 11:16:46 +08:00
[JsonPropertyName("mode")]
public int? Mode { get; set; }
[JsonPropertyName("remainingSeconds")]
public int? RemainingSeconds { get; set; }
2026-06-02 10:30:05 +08:00
[JsonPropertyName("rssi")]
public int? Rssi { get; set; }
[JsonPropertyName("gatewayId")]
public string? GatewayId { get; set; }
[JsonPropertyName("timestamp")]
public DateTimeOffset Timestamp { get; set; } = DateTimeOffset.UtcNow;
[JsonPropertyName("ingestedAt")]
public DateTimeOffset IngestedAt { get; set; } = DateTimeOffset.UtcNow;
}