@shushed/helpers 0.0.287 → 0.0.289

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -73,6 +73,10 @@
73
73
  "type": "string",
74
74
  "pattern": "^[a-z0-9-.]+$",
75
75
  "description": "The content type of the asset. Lowercase, dashes, no spaces"
76
+ },
77
+ "is_product": {
78
+ "type": "boolean",
79
+ "description": "Whether the asset is a product image or not"
76
80
  }
77
81
  },
78
82
  "required": [
@@ -538,6 +538,13 @@
538
538
  "null"
539
539
  ],
540
540
  "description": "Occasion - Example: Casual / Formal / Party"
541
+ },
542
+ "has_quantity_on_po": {
543
+ "type": [
544
+ "boolean",
545
+ "null"
546
+ ],
547
+ "description": "Whether this product has quantity on purchase order."
541
548
  }
542
549
  },
543
550
  "required": []
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" } }, "required": ["source_url", "content_type", "last_modified_at"], "$id": "https://shushed.example.com/asset.json" };
3
+ const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" }, "is_product": { "type": "boolean" } }, "required": ["source_url", "content_type", "last_modified_at"], "$id": "https://shushed.example.com/asset.json" };
4
4
  exports.default = schema;
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Development Colour", "type": "object", "additionalProperties": false, "properties": { "colour_id": { "type": "string" }, "name": { "type": ["string", "null"] }, "rgb": { "anyOf": [{ "type": "null" }, { "type": "array", "items": { "type": "number" } }] }, "cmyk": { "anyOf": [{ "type": "null" }, { "type": "array", "items": { "type": "number" } }] }, "pantone": { "anyOf": [{ "type": "null" }, { "type": "object", "properties": { "name": { "type": "string" }, "system": { "type": "string", "pattern": "^[A-Z0-9-]+$" }, "id": { "type": "string", "pattern": "^[A-Z0-9-]+$" } } }] }, "display_name": { "type": ["string", "null"], "pattern": "^[ a-z-]+$" }, "family_display_name": { "type": ["string", "null"], "pattern": "^[ a-z]+$" }, "source_asset": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" } }, "required": ["source_url", "content_type", "last_modified_at"] } }, "required": ["colour_id"], "$id": "https://shushed.example.com/development-colour.schema.json" };
3
+ const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Development Colour", "type": "object", "additionalProperties": false, "properties": { "colour_id": { "type": "string" }, "name": { "type": ["string", "null"] }, "rgb": { "anyOf": [{ "type": "null" }, { "type": "array", "items": { "type": "number" } }] }, "cmyk": { "anyOf": [{ "type": "null" }, { "type": "array", "items": { "type": "number" } }] }, "pantone": { "anyOf": [{ "type": "null" }, { "type": "object", "properties": { "name": { "type": "string" }, "system": { "type": "string", "pattern": "^[A-Z0-9-]+$" }, "id": { "type": "string", "pattern": "^[A-Z0-9-]+$" } } }] }, "display_name": { "type": ["string", "null"], "pattern": "^[ a-z-]+$" }, "family_display_name": { "type": ["string", "null"], "pattern": "^[ a-z]+$" }, "source_asset": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" }, "is_product": { "type": "boolean" } }, "required": ["source_url", "content_type", "last_modified_at"] } }, "required": ["colour_id"], "$id": "https://shushed.example.com/development-colour.schema.json" };
4
4
  exports.default = schema;
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "ProductChange", "additionalProperties": false, "allOf": [{ "$schema": "http://json-schema.org/draft-07/schema#", "title": "Product", "additionalProperties": false, "type": "object", "properties": { "product_id": { "type": "string" }, "slug": { "type": ["string"] }, "style_id": { "type": ["string"] }, "colour_id": { "type": "string" }, "style_name": { "type": "string" }, "display_name": { "type": ["string"] }, "buffer_quantity": { "type": "integer", "minimum": 0 }, "display_type": { "type": "string", "enum": ["Out-of-stock", "Permanently-unavailable"] }, "available_to_sell_from": { "type": ["string", "null"], "format": "date" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "colour_family_name": { "type": "string" }, "colour_name": { "type": "string" }, "display_tags": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" } }, "required": ["source_url", "content_type", "last_modified_at"] } }, "sizerange_code": { "type": "string" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "type": "string" }, "name": { "type": ["string"] }, "ean": { "type": ["string", "null"] } }, "required": ["code", "name"] } }, "vat_rate_uk": { "type": ["number", "null"], "minimum": 0 }, "supply_chain": { "type": "object", "properties": { "hs_code_us": { "type": ["string", "null"] }, "hs_code_uk": { "type": ["string", "null"] }, "mid_code": { "type": ["string", "null"] }, "country_of_origin": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Country", "type": "string", "enum": ["AF", "AX", "AL", "DZ", "AS", "AD", "AO", "AI", "AQ", "AG", "AR", "AM", "AW", "AU", "AT", "AZ", "BS", "BH", "BD", "BB", "BY", "BE", "BZ", "BJ", "BM", "BT", "BO", "BQ", "BA", "BW", "BV", "BR", "IO", "BN", "BG", "BF", "BI", "CV", "KH", "CM", "CA", "KY", "CF", "TD", "CL", "CN", "CX", "CC", "CO", "KM", "CD", "CG", "CK", "CR", "CI", "HR", "CU", "CW", "CY", "CZ", "DK", "DJ", "DM", "DO", "EC", "EG", "SV", "GQ", "ER", "EE", "SZ", "ET", "FK", "FO", "FJ", "FI", "FR", "GF", "PF", "TF", "GA", "GM", "GE", "DE", "GH", "GI", "GR", "GL", "GD", "GP", "GU", "GT", "GG", "GN", "GW", "GY", "HT", "HM", "VA", "HN", "HK", "HU", "IS", "IN", "ID", "IR", "IQ", "IE", "IM", "IL", "IT", "JM", "JP", "JE", "JO", "KZ", "KE", "KI", "KP", "KR", "KW", "KG", "LA", "LV", "LB", "LS", "LR", "LY", "LI", "LT", "LU", "MO", "MG", "MW", "MY", "MV", "ML", "MT", "MH", "MQ", "MR", "MU", "YT", "MX", "FM", "MD", "MC", "MN", "ME", "MS", "MA", "MZ", "MM", "NA", "NR", "NP", "NL", "NC", "NZ", "NI", "NE", "NG", "NU", "NF", "MK", "MP", "NO", "OM", "PK", "PW", "PS", "PA", "PG", "PY", "PE", "PH", "PN", "PL", "PT", "PR", "QA", "RE", "RO", "RU", "RW", "BL", "SH", "KN", "LC", "MF", "PM", "VC", "WS", "SM", "ST", "SA", "SN", "RS", "SC", "SL", "SG", "SX", "SK", "SI", "SB", "SO", "ZA", "GS", "SS", "ES", "LK", "SD", "SR", "SJ", "SE", "CH", "SY", "TW", "TJ", "TZ", "TH", "TL", "TG", "TK", "TO", "TT", "TN", "TR", "TM", "TC", "TV", "UG", "UA", "AE", "GB", "UM", "US", "UY", "UZ", "VU", "VE", "VN", "VG", "VI", "WF", "EH", "YE", "ZM", "ZW"] }, "port_of_origin": { "type": "string" }, "packing_method": { "type": ["string", "null"], "enum": ["Standard", "Hanging"] }, "is_bought_in_product": { "type": "boolean" } }, "required": [] }, "merch": { "type": "object", "properties": { "strategy_type": { "type": "string" }, "category": { "type": "string" }, "subcategory": { "type": "string" }, "seasons": { "type": ["array"], "items": { "type": "string" } }, "drops": { "type": ["array"], "items": { "type": "string" } }, "complete_the_look": { "type": ["array"], "items": { "type": "string" } } }, "required": [] }, "principal_category": { "type": ["string", "null"] }, "category_assignments": { "type": "array", "items": { "type": "object", "properties": { "display_path": { "type": "array", "items": { "type": "string" } }, "path": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "id": { "type": "string" } } } }, "attributes": { "type": "object", "properties": { "price": { "type": ["number", "null"] }, "rrp": { "type": ["number", "null"] }, "stock_quantity_score": { "type": "number" }, "stock_availability": { "type": "number" }, "measurement_chart": { "type": ["string", "null"] }, "markdown_price": { "type": ["number", "null"] }, "cost_price": { "type": ["number", "null"] }, "sizeguide_type": { "type": ["string", "null"] }, "brand": { "type": ["string", "null"] }, "shoes_type": { "type": ["string", "null"] }, "seo_url_name": { "type": "string", "pattern": "^[a-z0-9-]+$" }, "seo_title": { "type": ["string", "null"] }, "seo_description": { "type": ["string", "null"] }, "fit_description": { "type": ["string", "null"] }, "fabric_care": { "type": ["string", "null"] }, "weight": { "type": ["number", "null"] }, "average_weight": { "type": ["number", "null"] }, "main_fibre": { "type": ["string", "null"] }, "main_metal": { "type": ["string", "null"] }, "designer": { "type": ["string", "null"] }, "certificate_code": { "type": ["string", "null"] }, "pattern_name": { "type": ["string", "null"] }, "fit_type": { "type": ["string", "null"] }, "trousers_fit": { "type": ["string", "null"], "nullable": true }, "trousers_length": { "type": ["string", "null"] }, "dresses_skirts_length": { "type": ["string", "null"] }, "coats_jackets_type": { "type": ["string", "null"] }, "dresses_skirts_type": { "type": ["string", "null"] }, "bag_type": { "type": ["string", "null"] }, "product_category": { "type": ["string", "null"] }, "product_type": { "type": ["string", "null"] }, "metal": { "type": ["string", "null"] }, "care_instructions": { "type": "array", "items": { "type": "string" } }, "sleeve_length": { "type": ["string", "null"] }, "heel_height": { "type": ["string", "null"] }, "occasion": { "type": ["string", "null"] } }, "required": [] }, "markets": { "type": "array", "items": { "type": "string" } }, "markets_overrides": { "type": "object", "additionalProperties": false, "patternProperties": { ".*": { "type": "object", "additionalProperties": false, "properties": { "locale": { "type": "string", "pattern": "^[a-z]{2}-[A-Z]{2}$" }, "market": { "type": "string" }, "slug": { "$ref": "#/allOf/0/properties/slug" }, "style_name": { "$ref": "#/allOf/0/properties/style_name" }, "display_name": { "$ref": "#/allOf/0/properties/display_name" }, "display_type": { "$ref": "#/allOf/0/properties/display_type" }, "available_to_sell_from": { "$ref": "#/allOf/0/properties/available_to_sell_from" }, "colour_family_name": { "$ref": "#/allOf/0/properties/colour_family_name" }, "colour_name": { "$ref": "#/allOf/0/properties/colour_name" }, "display_tags": { "$ref": "#/allOf/0/properties/display_tags" }, "last_online_at": { "type": ["string", "null"], "format": "date-time" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "$ref": "#/allOf/0/properties/variants/items/properties/code" }, "name": { "$ref": "#/allOf/0/properties/variants/items/properties/name" } }, "required": ["code", "name"] } }, "attributes": { "$ref": "#/allOf/0/properties/attributes" } }, "required": ["locale", "market"] } } } }, "required": ["product_id", "style_id", "colour_id", "display_name"] }, { "type": "object", "additionalProperties": false, "required": ["product_id", "style_id", "variants", "images", "attributes", "created_at", "last_modified_at", "colour_family_name"] }], "$id": "https://shushed.example.com/messages/product-change.schema.json" };
3
+ const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "ProductChange", "additionalProperties": false, "allOf": [{ "$schema": "http://json-schema.org/draft-07/schema#", "title": "Product", "additionalProperties": false, "type": "object", "properties": { "product_id": { "type": "string" }, "slug": { "type": ["string"] }, "style_id": { "type": ["string"] }, "colour_id": { "type": "string" }, "style_name": { "type": "string" }, "display_name": { "type": ["string"] }, "buffer_quantity": { "type": "integer", "minimum": 0 }, "display_type": { "type": "string", "enum": ["Out-of-stock", "Permanently-unavailable"] }, "available_to_sell_from": { "type": ["string", "null"], "format": "date" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "colour_family_name": { "type": "string" }, "colour_name": { "type": "string" }, "display_tags": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" }, "is_product": { "type": "boolean" } }, "required": ["source_url", "content_type", "last_modified_at"] } }, "sizerange_code": { "type": "string" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "type": "string" }, "name": { "type": ["string"] }, "ean": { "type": ["string", "null"] } }, "required": ["code", "name"] } }, "vat_rate_uk": { "type": ["number", "null"], "minimum": 0 }, "supply_chain": { "type": "object", "properties": { "hs_code_us": { "type": ["string", "null"] }, "hs_code_uk": { "type": ["string", "null"] }, "mid_code": { "type": ["string", "null"] }, "country_of_origin": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Country", "type": "string", "enum": ["AF", "AX", "AL", "DZ", "AS", "AD", "AO", "AI", "AQ", "AG", "AR", "AM", "AW", "AU", "AT", "AZ", "BS", "BH", "BD", "BB", "BY", "BE", "BZ", "BJ", "BM", "BT", "BO", "BQ", "BA", "BW", "BV", "BR", "IO", "BN", "BG", "BF", "BI", "CV", "KH", "CM", "CA", "KY", "CF", "TD", "CL", "CN", "CX", "CC", "CO", "KM", "CD", "CG", "CK", "CR", "CI", "HR", "CU", "CW", "CY", "CZ", "DK", "DJ", "DM", "DO", "EC", "EG", "SV", "GQ", "ER", "EE", "SZ", "ET", "FK", "FO", "FJ", "FI", "FR", "GF", "PF", "TF", "GA", "GM", "GE", "DE", "GH", "GI", "GR", "GL", "GD", "GP", "GU", "GT", "GG", "GN", "GW", "GY", "HT", "HM", "VA", "HN", "HK", "HU", "IS", "IN", "ID", "IR", "IQ", "IE", "IM", "IL", "IT", "JM", "JP", "JE", "JO", "KZ", "KE", "KI", "KP", "KR", "KW", "KG", "LA", "LV", "LB", "LS", "LR", "LY", "LI", "LT", "LU", "MO", "MG", "MW", "MY", "MV", "ML", "MT", "MH", "MQ", "MR", "MU", "YT", "MX", "FM", "MD", "MC", "MN", "ME", "MS", "MA", "MZ", "MM", "NA", "NR", "NP", "NL", "NC", "NZ", "NI", "NE", "NG", "NU", "NF", "MK", "MP", "NO", "OM", "PK", "PW", "PS", "PA", "PG", "PY", "PE", "PH", "PN", "PL", "PT", "PR", "QA", "RE", "RO", "RU", "RW", "BL", "SH", "KN", "LC", "MF", "PM", "VC", "WS", "SM", "ST", "SA", "SN", "RS", "SC", "SL", "SG", "SX", "SK", "SI", "SB", "SO", "ZA", "GS", "SS", "ES", "LK", "SD", "SR", "SJ", "SE", "CH", "SY", "TW", "TJ", "TZ", "TH", "TL", "TG", "TK", "TO", "TT", "TN", "TR", "TM", "TC", "TV", "UG", "UA", "AE", "GB", "UM", "US", "UY", "UZ", "VU", "VE", "VN", "VG", "VI", "WF", "EH", "YE", "ZM", "ZW"] }, "port_of_origin": { "type": "string" }, "packing_method": { "type": ["string", "null"], "enum": ["Standard", "Hanging"] }, "is_bought_in_product": { "type": "boolean" } }, "required": [] }, "merch": { "type": "object", "properties": { "strategy_type": { "type": "string" }, "category": { "type": "string" }, "subcategory": { "type": "string" }, "seasons": { "type": ["array"], "items": { "type": "string" } }, "drops": { "type": ["array"], "items": { "type": "string" } }, "complete_the_look": { "type": ["array"], "items": { "type": "string" } } }, "required": [] }, "principal_category": { "type": ["string", "null"] }, "category_assignments": { "type": "array", "items": { "type": "object", "properties": { "display_path": { "type": "array", "items": { "type": "string" } }, "path": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "id": { "type": "string" } } } }, "attributes": { "type": "object", "properties": { "price": { "type": ["number", "null"] }, "rrp": { "type": ["number", "null"] }, "stock_quantity_score": { "type": "number" }, "stock_availability": { "type": "number" }, "measurement_chart": { "type": ["string", "null"] }, "markdown_price": { "type": ["number", "null"] }, "cost_price": { "type": ["number", "null"] }, "sizeguide_type": { "type": ["string", "null"] }, "brand": { "type": ["string", "null"] }, "shoes_type": { "type": ["string", "null"] }, "seo_url_name": { "type": "string", "pattern": "^[a-z0-9-]+$" }, "seo_title": { "type": ["string", "null"] }, "seo_description": { "type": ["string", "null"] }, "fit_description": { "type": ["string", "null"] }, "fabric_care": { "type": ["string", "null"] }, "weight": { "type": ["number", "null"] }, "average_weight": { "type": ["number", "null"] }, "main_fibre": { "type": ["string", "null"] }, "main_metal": { "type": ["string", "null"] }, "designer": { "type": ["string", "null"] }, "certificate_code": { "type": ["string", "null"] }, "pattern_name": { "type": ["string", "null"] }, "fit_type": { "type": ["string", "null"] }, "trousers_fit": { "type": ["string", "null"], "nullable": true }, "trousers_length": { "type": ["string", "null"] }, "dresses_skirts_length": { "type": ["string", "null"] }, "coats_jackets_type": { "type": ["string", "null"] }, "dresses_skirts_type": { "type": ["string", "null"] }, "bag_type": { "type": ["string", "null"] }, "product_category": { "type": ["string", "null"] }, "product_type": { "type": ["string", "null"] }, "metal": { "type": ["string", "null"] }, "care_instructions": { "type": "array", "items": { "type": "string" } }, "sleeve_length": { "type": ["string", "null"] }, "heel_height": { "type": ["string", "null"] }, "occasion": { "type": ["string", "null"] }, "has_quantity_on_po": { "type": ["boolean", "null"] } }, "required": [] }, "markets": { "type": "array", "items": { "type": "string" } }, "markets_overrides": { "type": "object", "additionalProperties": false, "patternProperties": { ".*": { "type": "object", "additionalProperties": false, "properties": { "locale": { "type": "string", "pattern": "^[a-z]{2}-[A-Z]{2}$" }, "market": { "type": "string" }, "slug": { "$ref": "#/allOf/0/properties/slug" }, "style_name": { "$ref": "#/allOf/0/properties/style_name" }, "display_name": { "$ref": "#/allOf/0/properties/display_name" }, "display_type": { "$ref": "#/allOf/0/properties/display_type" }, "available_to_sell_from": { "$ref": "#/allOf/0/properties/available_to_sell_from" }, "colour_family_name": { "$ref": "#/allOf/0/properties/colour_family_name" }, "colour_name": { "$ref": "#/allOf/0/properties/colour_name" }, "display_tags": { "$ref": "#/allOf/0/properties/display_tags" }, "last_online_at": { "type": ["string", "null"], "format": "date-time" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "$ref": "#/allOf/0/properties/variants/items/properties/code" }, "name": { "$ref": "#/allOf/0/properties/variants/items/properties/name" } }, "required": ["code", "name"] } }, "attributes": { "$ref": "#/allOf/0/properties/attributes" } }, "required": ["locale", "market"] } } } }, "required": ["product_id", "style_id", "colour_id", "display_name"] }, { "type": "object", "additionalProperties": false, "required": ["product_id", "style_id", "variants", "images", "attributes", "created_at", "last_modified_at", "colour_family_name"] }], "$id": "https://shushed.example.com/messages/product-change.schema.json" };
4
4
  exports.default = schema;
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Product", "additionalProperties": false, "type": "object", "properties": { "product_id": { "type": "string" }, "slug": { "type": ["string"] }, "style_id": { "type": ["string"] }, "colour_id": { "type": "string" }, "style_name": { "type": "string" }, "display_name": { "type": ["string"] }, "buffer_quantity": { "type": "integer", "minimum": 0 }, "display_type": { "type": "string", "enum": ["Out-of-stock", "Permanently-unavailable"] }, "available_to_sell_from": { "type": ["string", "null"], "format": "date" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "colour_family_name": { "type": "string" }, "colour_name": { "type": "string" }, "display_tags": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" } }, "required": ["source_url", "content_type", "last_modified_at"] } }, "sizerange_code": { "type": "string" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "type": "string" }, "name": { "type": ["string"] }, "ean": { "type": ["string", "null"] } }, "required": ["code", "name"] } }, "vat_rate_uk": { "type": ["number", "null"], "minimum": 0 }, "supply_chain": { "type": "object", "properties": { "hs_code_us": { "type": ["string", "null"] }, "hs_code_uk": { "type": ["string", "null"] }, "mid_code": { "type": ["string", "null"] }, "country_of_origin": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Country", "type": "string", "enum": ["AF", "AX", "AL", "DZ", "AS", "AD", "AO", "AI", "AQ", "AG", "AR", "AM", "AW", "AU", "AT", "AZ", "BS", "BH", "BD", "BB", "BY", "BE", "BZ", "BJ", "BM", "BT", "BO", "BQ", "BA", "BW", "BV", "BR", "IO", "BN", "BG", "BF", "BI", "CV", "KH", "CM", "CA", "KY", "CF", "TD", "CL", "CN", "CX", "CC", "CO", "KM", "CD", "CG", "CK", "CR", "CI", "HR", "CU", "CW", "CY", "CZ", "DK", "DJ", "DM", "DO", "EC", "EG", "SV", "GQ", "ER", "EE", "SZ", "ET", "FK", "FO", "FJ", "FI", "FR", "GF", "PF", "TF", "GA", "GM", "GE", "DE", "GH", "GI", "GR", "GL", "GD", "GP", "GU", "GT", "GG", "GN", "GW", "GY", "HT", "HM", "VA", "HN", "HK", "HU", "IS", "IN", "ID", "IR", "IQ", "IE", "IM", "IL", "IT", "JM", "JP", "JE", "JO", "KZ", "KE", "KI", "KP", "KR", "KW", "KG", "LA", "LV", "LB", "LS", "LR", "LY", "LI", "LT", "LU", "MO", "MG", "MW", "MY", "MV", "ML", "MT", "MH", "MQ", "MR", "MU", "YT", "MX", "FM", "MD", "MC", "MN", "ME", "MS", "MA", "MZ", "MM", "NA", "NR", "NP", "NL", "NC", "NZ", "NI", "NE", "NG", "NU", "NF", "MK", "MP", "NO", "OM", "PK", "PW", "PS", "PA", "PG", "PY", "PE", "PH", "PN", "PL", "PT", "PR", "QA", "RE", "RO", "RU", "RW", "BL", "SH", "KN", "LC", "MF", "PM", "VC", "WS", "SM", "ST", "SA", "SN", "RS", "SC", "SL", "SG", "SX", "SK", "SI", "SB", "SO", "ZA", "GS", "SS", "ES", "LK", "SD", "SR", "SJ", "SE", "CH", "SY", "TW", "TJ", "TZ", "TH", "TL", "TG", "TK", "TO", "TT", "TN", "TR", "TM", "TC", "TV", "UG", "UA", "AE", "GB", "UM", "US", "UY", "UZ", "VU", "VE", "VN", "VG", "VI", "WF", "EH", "YE", "ZM", "ZW"] }, "port_of_origin": { "type": "string" }, "packing_method": { "type": ["string", "null"], "enum": ["Standard", "Hanging"] }, "is_bought_in_product": { "type": "boolean" } }, "required": [] }, "merch": { "type": "object", "properties": { "strategy_type": { "type": "string" }, "category": { "type": "string" }, "subcategory": { "type": "string" }, "seasons": { "type": ["array"], "items": { "type": "string" } }, "drops": { "type": ["array"], "items": { "type": "string" } }, "complete_the_look": { "type": ["array"], "items": { "type": "string" } } }, "required": [] }, "principal_category": { "type": ["string", "null"] }, "category_assignments": { "type": "array", "items": { "type": "object", "properties": { "display_path": { "type": "array", "items": { "type": "string" } }, "path": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "id": { "type": "string" } } } }, "attributes": { "type": "object", "properties": { "price": { "type": ["number", "null"] }, "rrp": { "type": ["number", "null"] }, "stock_quantity_score": { "type": "number" }, "stock_availability": { "type": "number" }, "measurement_chart": { "type": ["string", "null"] }, "markdown_price": { "type": ["number", "null"] }, "cost_price": { "type": ["number", "null"] }, "sizeguide_type": { "type": ["string", "null"] }, "brand": { "type": ["string", "null"] }, "shoes_type": { "type": ["string", "null"] }, "seo_url_name": { "type": "string", "pattern": "^[a-z0-9-]+$" }, "seo_title": { "type": ["string", "null"] }, "seo_description": { "type": ["string", "null"] }, "fit_description": { "type": ["string", "null"] }, "fabric_care": { "type": ["string", "null"] }, "weight": { "type": ["number", "null"] }, "average_weight": { "type": ["number", "null"] }, "main_fibre": { "type": ["string", "null"] }, "main_metal": { "type": ["string", "null"] }, "designer": { "type": ["string", "null"] }, "certificate_code": { "type": ["string", "null"] }, "pattern_name": { "type": ["string", "null"] }, "fit_type": { "type": ["string", "null"] }, "trousers_fit": { "type": ["string", "null"], "nullable": true }, "trousers_length": { "type": ["string", "null"] }, "dresses_skirts_length": { "type": ["string", "null"] }, "coats_jackets_type": { "type": ["string", "null"] }, "dresses_skirts_type": { "type": ["string", "null"] }, "bag_type": { "type": ["string", "null"] }, "product_category": { "type": ["string", "null"] }, "product_type": { "type": ["string", "null"] }, "metal": { "type": ["string", "null"] }, "care_instructions": { "type": "array", "items": { "type": "string" } }, "sleeve_length": { "type": ["string", "null"] }, "heel_height": { "type": ["string", "null"] }, "occasion": { "type": ["string", "null"] } }, "required": [] }, "markets": { "type": "array", "items": { "type": "string" } }, "markets_overrides": { "type": "object", "additionalProperties": false, "patternProperties": { ".*": { "type": "object", "additionalProperties": false, "properties": { "locale": { "type": "string", "pattern": "^[a-z]{2}-[A-Z]{2}$" }, "market": { "type": "string" }, "slug": { "$ref": "#/properties/slug" }, "style_name": { "$ref": "#/properties/style_name" }, "display_name": { "$ref": "#/properties/display_name" }, "display_type": { "$ref": "#/properties/display_type" }, "available_to_sell_from": { "$ref": "#/properties/available_to_sell_from" }, "colour_family_name": { "$ref": "#/properties/colour_family_name" }, "colour_name": { "$ref": "#/properties/colour_name" }, "display_tags": { "$ref": "#/properties/display_tags" }, "last_online_at": { "type": ["string", "null"], "format": "date-time" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "$ref": "#/properties/variants/items/properties/code" }, "name": { "$ref": "#/properties/variants/items/properties/name" } }, "required": ["code", "name"] } }, "attributes": { "$ref": "#/properties/attributes" } }, "required": ["locale", "market"] } } } }, "required": ["product_id", "style_id", "colour_id", "display_name"], "$id": "https://shushed.example.com/product.schema.json" };
3
+ const schema = { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Product", "additionalProperties": false, "type": "object", "properties": { "product_id": { "type": "string" }, "slug": { "type": ["string"] }, "style_id": { "type": ["string"] }, "colour_id": { "type": "string" }, "style_name": { "type": "string" }, "display_name": { "type": ["string"] }, "buffer_quantity": { "type": "integer", "minimum": 0 }, "display_type": { "type": "string", "enum": ["Out-of-stock", "Permanently-unavailable"] }, "available_to_sell_from": { "type": ["string", "null"], "format": "date" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "colour_family_name": { "type": "string" }, "colour_name": { "type": "string" }, "display_tags": { "type": "array", "items": { "type": "string" } }, "images": { "type": "array", "items": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Asset", "type": "object", "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "dash_id": { "type": "string" }, "md5": { "type": "string", "pattern": "^[a-f0-9]{32}$" }, "dash_folder_path": { "type": "string" }, "source_url": { "type": "string" }, "created_at": { "type": "string", "format": "date-time" }, "last_modified_at": { "type": "string", "format": "date-time" }, "width": { "type": "integer", "minimum": 0 }, "height": { "type": "integer", "minimum": 0 }, "meta": { "type": "object", "additionalProperties": true }, "content_type": { "type": "string", "pattern": "^[a-z0-9-/]+$" }, "file_name": { "type": "string", "pattern": "^[a-z0-9-.]+$" }, "is_product": { "type": "boolean" } }, "required": ["source_url", "content_type", "last_modified_at"] } }, "sizerange_code": { "type": "string" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "type": "string" }, "name": { "type": ["string"] }, "ean": { "type": ["string", "null"] } }, "required": ["code", "name"] } }, "vat_rate_uk": { "type": ["number", "null"], "minimum": 0 }, "supply_chain": { "type": "object", "properties": { "hs_code_us": { "type": ["string", "null"] }, "hs_code_uk": { "type": ["string", "null"] }, "mid_code": { "type": ["string", "null"] }, "country_of_origin": { "$schema": "http://json-schema.org/draft-07/schema#", "title": "Country", "type": "string", "enum": ["AF", "AX", "AL", "DZ", "AS", "AD", "AO", "AI", "AQ", "AG", "AR", "AM", "AW", "AU", "AT", "AZ", "BS", "BH", "BD", "BB", "BY", "BE", "BZ", "BJ", "BM", "BT", "BO", "BQ", "BA", "BW", "BV", "BR", "IO", "BN", "BG", "BF", "BI", "CV", "KH", "CM", "CA", "KY", "CF", "TD", "CL", "CN", "CX", "CC", "CO", "KM", "CD", "CG", "CK", "CR", "CI", "HR", "CU", "CW", "CY", "CZ", "DK", "DJ", "DM", "DO", "EC", "EG", "SV", "GQ", "ER", "EE", "SZ", "ET", "FK", "FO", "FJ", "FI", "FR", "GF", "PF", "TF", "GA", "GM", "GE", "DE", "GH", "GI", "GR", "GL", "GD", "GP", "GU", "GT", "GG", "GN", "GW", "GY", "HT", "HM", "VA", "HN", "HK", "HU", "IS", "IN", "ID", "IR", "IQ", "IE", "IM", "IL", "IT", "JM", "JP", "JE", "JO", "KZ", "KE", "KI", "KP", "KR", "KW", "KG", "LA", "LV", "LB", "LS", "LR", "LY", "LI", "LT", "LU", "MO", "MG", "MW", "MY", "MV", "ML", "MT", "MH", "MQ", "MR", "MU", "YT", "MX", "FM", "MD", "MC", "MN", "ME", "MS", "MA", "MZ", "MM", "NA", "NR", "NP", "NL", "NC", "NZ", "NI", "NE", "NG", "NU", "NF", "MK", "MP", "NO", "OM", "PK", "PW", "PS", "PA", "PG", "PY", "PE", "PH", "PN", "PL", "PT", "PR", "QA", "RE", "RO", "RU", "RW", "BL", "SH", "KN", "LC", "MF", "PM", "VC", "WS", "SM", "ST", "SA", "SN", "RS", "SC", "SL", "SG", "SX", "SK", "SI", "SB", "SO", "ZA", "GS", "SS", "ES", "LK", "SD", "SR", "SJ", "SE", "CH", "SY", "TW", "TJ", "TZ", "TH", "TL", "TG", "TK", "TO", "TT", "TN", "TR", "TM", "TC", "TV", "UG", "UA", "AE", "GB", "UM", "US", "UY", "UZ", "VU", "VE", "VN", "VG", "VI", "WF", "EH", "YE", "ZM", "ZW"] }, "port_of_origin": { "type": "string" }, "packing_method": { "type": ["string", "null"], "enum": ["Standard", "Hanging"] }, "is_bought_in_product": { "type": "boolean" } }, "required": [] }, "merch": { "type": "object", "properties": { "strategy_type": { "type": "string" }, "category": { "type": "string" }, "subcategory": { "type": "string" }, "seasons": { "type": ["array"], "items": { "type": "string" } }, "drops": { "type": ["array"], "items": { "type": "string" } }, "complete_the_look": { "type": ["array"], "items": { "type": "string" } } }, "required": [] }, "principal_category": { "type": ["string", "null"] }, "category_assignments": { "type": "array", "items": { "type": "object", "properties": { "display_path": { "type": "array", "items": { "type": "string" } }, "path": { "type": "array", "items": { "type": "string" } }, "name": { "type": "string" }, "id": { "type": "string" } } } }, "attributes": { "type": "object", "properties": { "price": { "type": ["number", "null"] }, "rrp": { "type": ["number", "null"] }, "stock_quantity_score": { "type": "number" }, "stock_availability": { "type": "number" }, "measurement_chart": { "type": ["string", "null"] }, "markdown_price": { "type": ["number", "null"] }, "cost_price": { "type": ["number", "null"] }, "sizeguide_type": { "type": ["string", "null"] }, "brand": { "type": ["string", "null"] }, "shoes_type": { "type": ["string", "null"] }, "seo_url_name": { "type": "string", "pattern": "^[a-z0-9-]+$" }, "seo_title": { "type": ["string", "null"] }, "seo_description": { "type": ["string", "null"] }, "fit_description": { "type": ["string", "null"] }, "fabric_care": { "type": ["string", "null"] }, "weight": { "type": ["number", "null"] }, "average_weight": { "type": ["number", "null"] }, "main_fibre": { "type": ["string", "null"] }, "main_metal": { "type": ["string", "null"] }, "designer": { "type": ["string", "null"] }, "certificate_code": { "type": ["string", "null"] }, "pattern_name": { "type": ["string", "null"] }, "fit_type": { "type": ["string", "null"] }, "trousers_fit": { "type": ["string", "null"], "nullable": true }, "trousers_length": { "type": ["string", "null"] }, "dresses_skirts_length": { "type": ["string", "null"] }, "coats_jackets_type": { "type": ["string", "null"] }, "dresses_skirts_type": { "type": ["string", "null"] }, "bag_type": { "type": ["string", "null"] }, "product_category": { "type": ["string", "null"] }, "product_type": { "type": ["string", "null"] }, "metal": { "type": ["string", "null"] }, "care_instructions": { "type": "array", "items": { "type": "string" } }, "sleeve_length": { "type": ["string", "null"] }, "heel_height": { "type": ["string", "null"] }, "occasion": { "type": ["string", "null"] }, "has_quantity_on_po": { "type": ["boolean", "null"] } }, "required": [] }, "markets": { "type": "array", "items": { "type": "string" } }, "markets_overrides": { "type": "object", "additionalProperties": false, "patternProperties": { ".*": { "type": "object", "additionalProperties": false, "properties": { "locale": { "type": "string", "pattern": "^[a-z]{2}-[A-Z]{2}$" }, "market": { "type": "string" }, "slug": { "$ref": "#/properties/slug" }, "style_name": { "$ref": "#/properties/style_name" }, "display_name": { "$ref": "#/properties/display_name" }, "display_type": { "$ref": "#/properties/display_type" }, "available_to_sell_from": { "$ref": "#/properties/available_to_sell_from" }, "colour_family_name": { "$ref": "#/properties/colour_family_name" }, "colour_name": { "$ref": "#/properties/colour_name" }, "display_tags": { "$ref": "#/properties/display_tags" }, "last_online_at": { "type": ["string", "null"], "format": "date-time" }, "variants": { "type": "array", "items": { "type": "object", "properties": { "code": { "$ref": "#/properties/variants/items/properties/code" }, "name": { "$ref": "#/properties/variants/items/properties/name" } }, "required": ["code", "name"] } }, "attributes": { "$ref": "#/properties/attributes" } }, "required": ["locale", "market"] } } } }, "required": ["product_id", "style_id", "colour_id", "display_name"], "$id": "https://shushed.example.com/product.schema.json" };
4
4
  exports.default = schema;
@@ -48,6 +48,9 @@ declare const schema: {
48
48
  readonly type: "string";
49
49
  readonly pattern: "^[a-z0-9-.]+$";
50
50
  };
51
+ readonly is_product: {
52
+ readonly type: "boolean";
53
+ };
51
54
  };
52
55
  readonly required: readonly ["source_url", "content_type", "last_modified_at"];
53
56
  readonly $id: "https://shushed.example.com/asset.json";
@@ -108,6 +108,9 @@ declare const schema: {
108
108
  readonly type: "string";
109
109
  readonly pattern: "^[a-z0-9-.]+$";
110
110
  };
111
+ readonly is_product: {
112
+ readonly type: "boolean";
113
+ };
111
114
  };
112
115
  readonly required: readonly ["source_url", "content_type", "last_modified_at"];
113
116
  };
@@ -110,6 +110,9 @@ declare const schema: {
110
110
  readonly type: "string";
111
111
  readonly pattern: "^[a-z0-9-.]+$";
112
112
  };
113
+ readonly is_product: {
114
+ readonly type: "boolean";
115
+ };
113
116
  };
114
117
  readonly required: readonly ["source_url", "content_type", "last_modified_at"];
115
118
  };
@@ -348,6 +351,9 @@ declare const schema: {
348
351
  readonly occasion: {
349
352
  readonly type: readonly ["string", "null"];
350
353
  };
354
+ readonly has_quantity_on_po: {
355
+ readonly type: readonly ["boolean", "null"];
356
+ };
351
357
  };
352
358
  readonly required: readonly [];
353
359
  };
@@ -106,6 +106,9 @@ declare const schema: {
106
106
  readonly type: "string";
107
107
  readonly pattern: "^[a-z0-9-.]+$";
108
108
  };
109
+ readonly is_product: {
110
+ readonly type: "boolean";
111
+ };
109
112
  };
110
113
  readonly required: readonly ["source_url", "content_type", "last_modified_at"];
111
114
  };
@@ -344,6 +347,9 @@ declare const schema: {
344
347
  readonly occasion: {
345
348
  readonly type: readonly ["string", "null"];
346
349
  };
350
+ readonly has_quantity_on_po: {
351
+ readonly type: readonly ["boolean", "null"];
352
+ };
347
353
  };
348
354
  readonly required: readonly [];
349
355
  };
@@ -13,5 +13,6 @@ export interface __MainSchema {
13
13
  };
14
14
  content_type: string;
15
15
  file_name?: string;
16
+ is_product?: boolean;
16
17
  }
17
18
  export default __MainSchema;
@@ -28,5 +28,6 @@ export interface Asset {
28
28
  };
29
29
  content_type: string;
30
30
  file_name?: string;
31
+ is_product?: boolean;
31
32
  }
32
33
  export default __MainSchema;
@@ -91,6 +91,7 @@ export interface Asset {
91
91
  };
92
92
  content_type: string;
93
93
  file_name?: string;
94
+ is_product?: boolean;
94
95
  }
95
96
  export interface Attributes {
96
97
  price?: (number | null);
@@ -130,6 +131,7 @@ export interface Attributes {
130
131
  sleeve_length?: (string | null);
131
132
  heel_height?: (string | null);
132
133
  occasion?: (string | null);
134
+ has_quantity_on_po?: (boolean | null);
133
135
  [k: string]: unknown;
134
136
  }
135
137
  export default __MainSchema;
@@ -90,6 +90,7 @@ export interface Asset {
90
90
  };
91
91
  content_type: string;
92
92
  file_name?: string;
93
+ is_product?: boolean;
93
94
  }
94
95
  export interface Attributes {
95
96
  price?: (number | null);
@@ -129,6 +130,7 @@ export interface Attributes {
129
130
  sleeve_length?: (string | null);
130
131
  heel_height?: (string | null);
131
132
  occasion?: (string | null);
133
+ has_quantity_on_po?: (boolean | null);
132
134
  [k: string]: unknown;
133
135
  }
134
136
  export default __MainSchema;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shushed/helpers",
3
- "version": "0.0.287",
3
+ "version": "0.0.289",
4
4
  "author": "",
5
5
  "license": "UNLICENSED",
6
6
  "description": "",