From 9cbc9b1729842d9fa251355c63108e63257a1c5e Mon Sep 17 00:00:00 2001 From: ppc Date: Thu, 15 Aug 2024 09:37:22 +0100 Subject: [PATCH] mirror amnet-native json responses --- AimeNet/AppJsonSerializerContext.cs | 6 +++--- AimeNet/DllMain.cs | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/AimeNet/AppJsonSerializerContext.cs b/AimeNet/AppJsonSerializerContext.cs index 88c11c3..41fc560 100644 --- a/AimeNet/AppJsonSerializerContext.cs +++ b/AimeNet/AppJsonSerializerContext.cs @@ -3,11 +3,11 @@ namespace AimeNet; public record SystemState( - [property: JsonPropertyName("api_ver")] int ApiVersion, - [property: JsonPropertyName("server_name")] string ServerName); + [property: JsonPropertyName("apiVersion")] int ApiVersion, + [property: JsonPropertyName("serverName")] string ServerName); public record CardReadRequest( - [property: JsonPropertyName("card_id")] string MatrixCode); + [property: JsonPropertyName("cardId")] string MatrixCode); [JsonSerializable(typeof(SystemState))] [JsonSerializable(typeof(CardReadRequest))] diff --git a/AimeNet/DllMain.cs b/AimeNet/DllMain.cs index ade2ed3..74e8300 100644 --- a/AimeNet/DllMain.cs +++ b/AimeNet/DllMain.cs @@ -19,7 +19,7 @@ namespace AimeNet; public static class DllMain { private const int ApiVersion = 1; - private const string WebAddress = "http://amnet.ppc.moe"; + private const string WebAddress = "http://card.ppc.moe"; private static ILogger _serverLogger;