aboutsummaryrefslogtreecommitdiff
path: root/src/Enmarcha.Backend/Types
diff options
context:
space:
mode:
authorAriel Costas Guerrero <ariel@costas.dev>2026-02-14 01:35:54 +0100
committerAriel Costas Guerrero <ariel@costas.dev>2026-02-14 01:36:09 +0100
commitac366d04cd54869c9a2b090aae24a276c32a85a6 (patch)
tree64a5c5903b07646a5c58b1b7e4c9704022549245 /src/Enmarcha.Backend/Types
parent3f8fb6fda07f97c9fd676cff67c637c0df0f7029 (diff)
feat: Implemen experimental bus stop usage display
Diffstat (limited to 'src/Enmarcha.Backend/Types')
-rw-r--r--src/Enmarcha.Backend/Types/Arrivals/BusStopUsagePoint.cs15
-rw-r--r--src/Enmarcha.Backend/Types/Arrivals/StopArrivalsResponse.cs3
2 files changed, 18 insertions, 0 deletions
diff --git a/src/Enmarcha.Backend/Types/Arrivals/BusStopUsagePoint.cs b/src/Enmarcha.Backend/Types/Arrivals/BusStopUsagePoint.cs
new file mode 100644
index 0000000..edb08f4
--- /dev/null
+++ b/src/Enmarcha.Backend/Types/Arrivals/BusStopUsagePoint.cs
@@ -0,0 +1,15 @@
+using System.Text.Json.Serialization;
+
+namespace Enmarcha.Backend.Types.Arrivals;
+
+public class BusStopUsagePoint
+{
+ [JsonPropertyName("h")]
+ public required int Hour { get; set; }
+
+ [JsonPropertyName("t")]
+ public required int Total { get; set; }
+
+ [JsonPropertyName("d")]
+ public required int DayOfWeek { get; set; }
+}
diff --git a/src/Enmarcha.Backend/Types/Arrivals/StopArrivalsResponse.cs b/src/Enmarcha.Backend/Types/Arrivals/StopArrivalsResponse.cs
index 4d2f481..ddc4535 100644
--- a/src/Enmarcha.Backend/Types/Arrivals/StopArrivalsResponse.cs
+++ b/src/Enmarcha.Backend/Types/Arrivals/StopArrivalsResponse.cs
@@ -18,4 +18,7 @@ public class StopArrivalsResponse
[JsonPropertyName("arrivals")]
public List<Arrival> Arrivals { get; set; } = [];
+
+ [JsonPropertyName("usage")]
+ public List<BusStopUsagePoint>? Usage { get; set; }
}