move models to shared, make new admin project

This commit is contained in:
Lapis
2026-06-16 18:32:28 -04:00
parent ee98c4c369
commit c20d215ee0
106 changed files with 60428 additions and 5 deletions
@@ -0,0 +1,16 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class Account
{
[JsonPropertyName("accountId")] public int? AccountId { get; set; }
[JsonPropertyName("profileImage")] public string? ProfileImage { get; set; }
[JsonPropertyName("isJunior")] public bool IsJunior { get; set; }
[JsonPropertyName("platforms")] public int? Platforms { get; set; }
[JsonPropertyName("personalPronouns")] public int? PersonalPronouns { get; set; }
[JsonPropertyName("identityFlags")] public int? IdentityFlags { get; set; }
[JsonPropertyName("username")] public string? Username { get; set; }
[JsonPropertyName("displayName")] public string? DisplayName { get; set; }
[JsonPropertyName("createdAt")] public DateTime CreatedAt { get; set; }
}
@@ -0,0 +1,28 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class AvatarItem
{
public int Id { get; set; }
[JsonPropertyName("avatarItemType")]
public int AvatarItemType { get; set; }
[JsonPropertyName("avatarItemDesc")]
public string AvatarItemDesc { get; set; } = "";
[JsonPropertyName("platformMask")]
public int PlatformMask { get; set; } = -1;
[JsonPropertyName("friendlyName")]
public string FriendlyName { get; set; } = "";
[JsonPropertyName("tooltip")]
public string Tooltip { get; set; } = "";
[JsonPropertyName("rarity")]
public int Rarity { get; set; } = 0;
public int OwnerAccountId { get; set; }
}
@@ -0,0 +1,24 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class CachedLogin
{
[JsonIgnore]
public int Id { get; set; }
[JsonPropertyName("accountId")]
public int AccountId { get; set; }
[JsonPropertyName("platform")]
public PlatformType Platform { get; set; }
[JsonPropertyName("platformId")]
public string PlatformID { get; set; }
[JsonPropertyName("lastLoginTime")]
public DateTime LastLoginTime { get; set; }
[JsonPropertyName("requirePassword")]
public bool RequirePassword { get; set; } = false;
}
@@ -0,0 +1,8 @@
namespace CannedNet;
public enum JuniorState
{
BasedOnBirthday = 0,
ModerationOverride = 1,
PendingOverride = 2
}
@@ -0,0 +1,15 @@
namespace CannedNet;
public enum PlatformType
{
All = -1,
Steam = 0,
Oculus = 1,
PlayStation = 2,
Xbox = 3,
RecNet = 4,
IOS = 5,
GooglePlay = 6,
Standalone = 7,
Pico = 8
}
@@ -0,0 +1,21 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class PlayerAvatar
{
public int Id { get; set; }
public int OwnerAccountId { get; set; }
[JsonPropertyName("OutfitSelections")]
public string OutfitSelections { get; set; } = "";
[JsonPropertyName("FaceFeatures")]
public string FaceFeatures { get; set; } = "{}";
[JsonPropertyName("SkinColor")]
public string SkinColor { get; set; } = "";
[JsonPropertyName("HairColor")]
public string HairColor { get; set; } = "";
}
@@ -0,0 +1,11 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class PlayerBio
{
[JsonPropertyName("accountId")]
public int accountId;
[JsonPropertyName("bio")]
public string bio;
}
@@ -0,0 +1,24 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class PlayerProgression
{
public int Id { get; set; }
[JsonPropertyName("playerId")]
public int PlayerId { get; set; }
[JsonPropertyName("level")]
public int Level { get; set; }
[JsonPropertyName("xp")]
public int Xp { get; set; }
}
public class PlayerProgressionBulkResponse
{
[JsonPropertyName("playerId")]
public int PlayerId { get; set; }
[JsonPropertyName("level")]
public int Level { get; set; }
[JsonPropertyName("xp")]
public int Xp { get; set; }
}
@@ -0,0 +1,15 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class PlayerSetting
{
public int Id { get; set; }
[JsonPropertyName("playerId")]
public int PlayerId { get; set; }
[JsonPropertyName("key")]
public string Key { get; set; } = "";
[JsonPropertyName("value")]
public string Value { get; set; } = "";
}
@@ -0,0 +1,9 @@
namespace CannedNet;
public enum RelationshipType
{
None,
FriendRequestSent,
FriendRequestReceived,
Friend
}
@@ -0,0 +1,21 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class SavedOutfit
{
public int Id { get; set; }
public int OwnerAccountId { get; set; }
[JsonPropertyName("Slot")]
public int Slot { get; set; }
[JsonPropertyName("PreviewImageName")]
public string PreviewImageName { get; set; }
[JsonPropertyName("OutfitSelections")]
public string OutfitSelections { get; set; }
[JsonPropertyName("HairColor")]
public string HairColor { get; set; }
[JsonPropertyName("SkinColor")]
public string SkinColor { get; set; }
[JsonPropertyName("FaceFeatures")]
public string FaceFeatures { get; set; }
}
@@ -0,0 +1,16 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class SelfAccount : Account
{
[JsonPropertyName("email")] public string? Email { get; set; }
[JsonPropertyName("phone")] public string? Phone { get; set; }
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("juniorState")] public JuniorState? JuniorState { get; set; }
[JsonPropertyName("birthday")] public DateTime? Birthday { get; set; }
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
[JsonPropertyName("parentAccountId")] public string? ParentAccountId { get; set; }
[JsonPropertyName("availableUsernameChanges")] public int? AvailableUsernameChanges { get; set; }
}
@@ -0,0 +1,7 @@
namespace CannedNet;
public class SettingPayload
{
public string Key { get; set; }
public string Value { get; set; }
}
@@ -0,0 +1,9 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class SubscriptionList
{
[JsonPropertyName("playerIds")]
public List<int>? PlayerIds { get; set; }
}
@@ -0,0 +1,16 @@
using System.Text.Json.Serialization;
namespace CannedNet;
public class TokenBalance
{
public int Id { get; set; }
[JsonPropertyName("Balance")]
public int Balance { get; set; }
[JsonPropertyName("CurrencyType")]
public int CurrencyType { get; set; }
[JsonPropertyName("BalanceType")]
public int BalanceType { get; set; }
[JsonPropertyName("Platform")]
public int Platform { get; set; }
}