From 45dbc51eb134d8923a92c3063a503f7fe41cd67a Mon Sep 17 00:00:00 2001 From: Stephan Date: Sun, 26 May 2024 10:51:47 +0200 Subject: [PATCH] added ids to inventory class #3 --- BrickOwlSharp.Client/Inventory.cs | 3 +++ BrickOwlSharp.Client/Reference.cs | 17 +++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 BrickOwlSharp.Client/Reference.cs diff --git a/BrickOwlSharp.Client/Inventory.cs b/BrickOwlSharp.Client/Inventory.cs index f2f9eab..4d7dcbe 100644 --- a/BrickOwlSharp.Client/Inventory.cs +++ b/BrickOwlSharp.Client/Inventory.cs @@ -92,5 +92,8 @@ public class Inventory [JsonPropertyName("tier_price"), JsonConverter(typeof(TierPriceListConverter))] public List TierPrices { get; set; } + + [JsonPropertyName("ids")] + public List Ids { get; set; } = new List(); } } diff --git a/BrickOwlSharp.Client/Reference.cs b/BrickOwlSharp.Client/Reference.cs new file mode 100644 index 0000000..007ebe8 --- /dev/null +++ b/BrickOwlSharp.Client/Reference.cs @@ -0,0 +1,17 @@ +using BrickOwlSharp.Client.Json; +using System; +using System.Collections.Generic; +using System.Text; +using System.Text.Json.Serialization; + +namespace BrickOwlSharp.Client +{ + public class Reference + { + [JsonPropertyName("id")] + public string Id { get; set; } + + [JsonPropertyName("type"), JsonConverter(typeof(IdTypesStringConverter))] + public IdType Type { get; set; } + } +}