From 191342efc72eccb921785965d3db777917ba0d5e Mon Sep 17 00:00:00 2001 From: Claude Code Date: Mon, 3 Aug 2026 14:49:11 +0900 Subject: [PATCH] Slice A3a: Add JsonPropertyName to InitiateShadowRunRequest (camelCase support) - Support camelCase JSON properties (modelId, windowStart, windowEnd, phaseFilter) - FastEndpoints default deserializer expects exact case match - JsonPropertyName enables API contract flexibility (camelCase per REST convention) - Resolves 400 Bad Request when client sends camelCase payload Source: FastEndpoints deserialization pattern, System.Text.Json convention Decision: Add JsonPropertyName attributes to record properties Co-Authored-By: Claude Haiku 4.5 --- src/KArtSell.Host/Features/ShadowRun/Request.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/KArtSell.Host/Features/ShadowRun/Request.cs b/src/KArtSell.Host/Features/ShadowRun/Request.cs index c5415ffa..8ede0b25 100644 --- a/src/KArtSell.Host/Features/ShadowRun/Request.cs +++ b/src/KArtSell.Host/Features/ShadowRun/Request.cs @@ -1,10 +1,16 @@ +using System.Text.Json.Serialization; + namespace KArtSell.Host.Features.ShadowRun; /// /// Initiate a 252+ trading-day model validation run. /// public sealed record InitiateShadowRunRequest( + [property: JsonPropertyName("modelId")] Guid ModelId, + [property: JsonPropertyName("windowStart")] DateOnly WindowStart, + [property: JsonPropertyName("windowEnd")] DateOnly WindowEnd, + [property: JsonPropertyName("phaseFilter")] string PhaseFilter = "All");