From e7af80d85766a3612b91ee3fa43088c2de903d88 Mon Sep 17 00:00:00 2001 From: Christian Ortner Date: Tue, 28 Apr 2020 11:10:11 +0200 Subject: [PATCH 1/3] Rename colorCode to color for color filters The schema didn't match reality, and as the property might be used in reality already with this name, modifying the schema is the safe option. --- example/response.json | 2 +- resources/schema.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/example/response.json b/example/response.json index 443c203..dc02707 100644 --- a/example/response.json +++ b/example/response.json @@ -134,7 +134,7 @@ "values": [ { "value": "Green", - "colorCode": "#00FF00" + "color": "#00FF00" } ] } diff --git a/resources/schema.json b/resources/schema.json index a101b84..58418cd 100644 --- a/resources/schema.json +++ b/resources/schema.json @@ -44,7 +44,7 @@ ], "description": "In case of a selected-filter, this property indicates whether the frequency is the number of additional products you'll get after selecting the filter (additive), or whether it's the total number of results you'll have after selecting the filter (absolute)." }, - "colorCode": { + "color": { "description": "For color filters, the hexadecimal code corresponding to the color. The filter's value is the configured color name in such a case.", "type": "string", "pattern": "^#[0-9A-Fa-f]{6}$" From c160a70e24bfb567166798d68f46e7ce9dbd05e4 Mon Sep 17 00:00:00 2001 From: Christian Ortner Date: Tue, 28 Apr 2020 12:11:55 +0200 Subject: [PATCH 2/3] Make requestId and userId optional --- resources/schema.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/resources/schema.json b/resources/schema.json index 58418cd..db2f0b9 100644 --- a/resources/schema.json +++ b/resources/schema.json @@ -259,7 +259,6 @@ "count", "serviceId", "usergroup", - "userId", "order" ] }, @@ -342,7 +341,6 @@ "landingpage", "promotion", "searchConcept", - "requestId", "effectiveQuery", "totalResults", "currencySymbol" From f37c3b7c7a96ae3bc3c51817a855306e0df64cd9 Mon Sep 17 00:00:00 2001 From: Christian Ortner Date: Tue, 28 Apr 2020 14:39:52 +0200 Subject: [PATCH 3/3] Make product placement name nullable --- resources/schema.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/schema.json b/resources/schema.json index db2f0b9..8ad0871 100644 --- a/resources/schema.json +++ b/resources/schema.json @@ -443,7 +443,7 @@ } }, "productPlacement": { - "type": "string", + "type": ["string", "null"], "minLength": 1, "description": "In case a Product Placement matches the product, this is its name." },