a web-based Rock Band 4 stats viewer and achievement tracker website
1using System.Text.Json.Serialization;
2
3namespace davesave_web
4{
5 public class ErrorResponse
6 {
7 [JsonPropertyName("source")] public string? ErrorSource { get; set; }
8 [JsonPropertyName("code")] public uint ErrorCode { get; set; }
9 [JsonPropertyName("message")] public string? Message { get; set; }
10 }
11
12 public class XboxProfileInformation
13 {
14 [JsonPropertyName("gamertag")] public string? Gamertag { get; set; }
15 [JsonPropertyName("xuid")] public string? XUID { get; set; }
16 [JsonPropertyName("picture")] public string? ProfilePictureURI { get; set; }
17 }
18
19 public class TicketInformation
20 {
21 [JsonPropertyName("jwt")] public string? JWT { get; set; }
22 [JsonPropertyName("expiry")] public DateTime Expiry { get; set; }
23 }
24
25 public class RedeemAuthResponse
26 {
27 [JsonPropertyName("profile")] public XboxProfileInformation? Profile { get; set; }
28 [JsonPropertyName("access")] public TicketInformation? AccessTicket { get; set; }
29 [JsonPropertyName("refresh")] public TicketInformation? RefreshTicket { get; set; }
30 }
31
32 public class StartAuthResponse
33 {
34 [JsonPropertyName("loginUri")] public string? LoginURI { get; set; }
35 [JsonPropertyName("state")] public string? State { get; set; }
36 }
37
38 public class SavegameMetaResponse
39 {
40 [JsonPropertyName("lastModified")] public DateTime LastModified { get; set; }
41 [JsonPropertyName("size")] public int FileSize { get; set; }
42 }
43}