@asstio-dev/storefront 0.9.2 → 0.12.0

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.
package/src/schema.d.ts CHANGED
@@ -4,6 +4,40 @@
4
4
  */
5
5
 
6
6
  export interface paths {
7
+ "/v1/brands": {
8
+ parameters: {
9
+ query?: never;
10
+ header?: never;
11
+ path?: never;
12
+ cookie?: never;
13
+ };
14
+ /** Brands with a page on this market (some product of the brand is sold here), by name. Empty when the site has no brand facet or the market no brand URL pattern. productCount counts product families with a variant of the brand sold here. */
15
+ get: operations["ListBrands"];
16
+ put?: never;
17
+ post?: never;
18
+ delete?: never;
19
+ options?: never;
20
+ head?: never;
21
+ patch?: never;
22
+ trace?: never;
23
+ };
24
+ "/v1/brands/{slugOrId}": {
25
+ parameters: {
26
+ query?: never;
27
+ header?: never;
28
+ path?: never;
29
+ cookie?: never;
30
+ };
31
+ /** A brand page's data by current slug, historical slug or id: name, description, logo, website, the brand's default responsible parties and the facet link for its listing. redirectTo is set for a historical slug. */
32
+ get: operations["GetBrand"];
33
+ put?: never;
34
+ post?: never;
35
+ delete?: never;
36
+ options?: never;
37
+ head?: never;
38
+ patch?: never;
39
+ trace?: never;
40
+ };
7
41
  "/v1/cart": {
8
42
  parameters: {
9
43
  query?: never;
@@ -325,7 +359,7 @@ export interface paths {
325
359
  path?: never;
326
360
  cookie?: never;
327
361
  };
328
- /** Ids, slugs, URLs and lastmod for sitemap.xml and selective revalidation. type=product|collection, ?since= is inclusive. */
362
+ /** Ids, slugs, URLs and lastmod for sitemap.xml and selective revalidation. type=product|collection|brand, ?since= is inclusive. */
329
363
  get: operations["GetSitemap"];
330
364
  put?: never;
331
365
  post?: never;
@@ -368,9 +402,50 @@ export interface components {
368
402
  valueKeys: string[] | null;
369
403
  values: string[] | null;
370
404
  };
405
+ BrandDetailDto: {
406
+ alternateUrls: {
407
+ [key: string]: string;
408
+ };
409
+ description: null | components["schemas"]["DescriptionDto"];
410
+ facet: null | components["schemas"]["FacetLinkDto"];
411
+ id: string;
412
+ logo: null | components["schemas"]["MediaDescriptorDto"];
413
+ name: string;
414
+ /** Format: int64 */
415
+ productCount: number | string;
416
+ redirectTo: null | string;
417
+ responsible: components["schemas"]["ResponsibleDto"];
418
+ slug: string;
419
+ /** Format: date-time */
420
+ updatedAt: string;
421
+ url: string;
422
+ websiteUrl: null | string;
423
+ };
371
424
  BrandDto: {
372
425
  facet: null | components["schemas"]["FacetLinkDto"];
426
+ id?: null | string;
373
427
  label: string;
428
+ logo?: null | components["schemas"]["MediaDescriptorDto"];
429
+ slug?: null | string;
430
+ url?: null | string;
431
+ };
432
+ BrandListItemDto: {
433
+ id: string;
434
+ logo: null | components["schemas"]["MediaDescriptorDto"];
435
+ name: string;
436
+ /** Format: int64 */
437
+ productCount: number | string;
438
+ slug: string;
439
+ url: string;
440
+ };
441
+ BrandPageDto: {
442
+ items: components["schemas"]["BrandListItemDto"][];
443
+ /** Format: int32 */
444
+ page: number | string;
445
+ /** Format: int32 */
446
+ pageSize: number | string;
447
+ /** Format: int64 */
448
+ total: number | string;
374
449
  };
375
450
  BundleComponentDto: {
376
451
  product: components["schemas"]["ProductCardDto"];
@@ -731,6 +806,18 @@ export interface components {
731
806
  gross: string;
732
807
  vat: components["schemas"]["VatAmountDto"][];
733
808
  };
809
+ PartyDto: {
810
+ city: null | string;
811
+ countryCode: string;
812
+ email: null | string;
813
+ legalName: string;
814
+ name: string;
815
+ phone: null | string;
816
+ postalCode: null | string;
817
+ region: null | string;
818
+ street: null | string;
819
+ url: null | string;
820
+ };
734
821
  PriceDto: {
735
822
  amount: string;
736
823
  compareAt: null | string;
@@ -765,6 +852,8 @@ export interface components {
765
852
  collections: components["schemas"]["CollectionRefDto"][];
766
853
  description: null | components["schemas"]["DescriptionDto"];
767
854
  files: components["schemas"]["MediaDescriptorDto"][];
855
+ gtin: null | string;
856
+ gtins: string[];
768
857
  id: string;
769
858
  image: null | components["schemas"]["MediaDescriptorDto"];
770
859
  images: components["schemas"]["MediaDescriptorDto"][];
@@ -773,6 +862,7 @@ export interface components {
773
862
  options: components["schemas"]["OptionDto"][];
774
863
  redirectTo: null | string;
775
864
  related: components["schemas"]["RelatedGroupDto"][];
865
+ responsible: components["schemas"]["ResponsibleDto"];
776
866
  seo: components["schemas"]["SeoDto"];
777
867
  shortDescription: null | string;
778
868
  sku: string;
@@ -802,6 +892,11 @@ export interface components {
802
892
  label: string;
803
893
  products: components["schemas"]["ProductCardDto"][];
804
894
  };
895
+ ResponsibleDto: {
896
+ euResponsiblePerson: null | components["schemas"]["PartyDto"];
897
+ importer: null | components["schemas"]["PartyDto"];
898
+ manufacturer: null | components["schemas"]["PartyDto"];
899
+ };
805
900
  SeoDto: {
806
901
  description: null | string;
807
902
  title: string;
@@ -909,12 +1004,16 @@ export interface components {
909
1004
  product: string;
910
1005
  };
911
1006
  VariantDto: {
1007
+ brand: null | components["schemas"]["BrandDto"];
1008
+ gtin: null | string;
1009
+ gtins: string[];
912
1010
  hasOwnImages: boolean;
913
1011
  id: string;
914
1012
  image: null | components["schemas"]["MediaDescriptorDto"];
915
1013
  images: components["schemas"]["MediaDescriptorDto"][];
916
1014
  inStock: boolean;
917
1015
  price: null | components["schemas"]["PriceDto"];
1016
+ responsible: components["schemas"]["ResponsibleDto"];
918
1017
  selectedOptions: {
919
1018
  [key: string]: string;
920
1019
  };
@@ -958,6 +1057,175 @@ export interface components {
958
1057
  }
959
1058
  export type $defs = Record<string, never>;
960
1059
  export interface operations {
1060
+ ListBrands: {
1061
+ parameters: {
1062
+ query?: {
1063
+ /** @description 1-based page. page × pageSize must not exceed 10000 (default pageSize 100, max 1000). */
1064
+ page?: number;
1065
+ /** @description Items per page, 1–1000. Out of range is a 400 with code INVALID_PAGE. */
1066
+ pageSize?: number;
1067
+ };
1068
+ header: {
1069
+ /** @description Publishable, preview or secret site key. Required on every request; secret keys are server-side only. */
1070
+ "X-Site-Key": string;
1071
+ /** @description Market code (e.g. "se"). Omit for the site's default market. */
1072
+ "X-Market"?: string;
1073
+ /** @description BCP-47 language tag. Omit to use the market's language. */
1074
+ "Accept-Language"?: string;
1075
+ };
1076
+ path?: never;
1077
+ cookie?: never;
1078
+ };
1079
+ requestBody?: never;
1080
+ responses: {
1081
+ /** @description OK */
1082
+ 200: {
1083
+ headers: {
1084
+ [name: string]: unknown;
1085
+ };
1086
+ content: {
1087
+ "application/json": components["schemas"]["BrandPageDto"];
1088
+ };
1089
+ };
1090
+ /** @description problem+json. MARKET_UNKNOWN (no such market on this site) or INVALID_PAGE. */
1091
+ 400: {
1092
+ headers: {
1093
+ [name: string]: unknown;
1094
+ };
1095
+ content: {
1096
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1097
+ };
1098
+ };
1099
+ /** @description problem+json. SITE_KEY_MISSING or SITE_KEY_INVALID. */
1100
+ 401: {
1101
+ headers: {
1102
+ [name: string]: unknown;
1103
+ };
1104
+ content: {
1105
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1106
+ };
1107
+ };
1108
+ /** @description problem+json. SECRET_KEY_FROM_BROWSER: a secret key was sent from a browser. */
1109
+ 403: {
1110
+ headers: {
1111
+ [name: string]: unknown;
1112
+ };
1113
+ content: {
1114
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1115
+ };
1116
+ };
1117
+ /** @description problem+json. SITE_INACTIVE, or NOT_FOUND for an unrouted path. */
1118
+ 404: {
1119
+ headers: {
1120
+ [name: string]: unknown;
1121
+ };
1122
+ content: {
1123
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1124
+ };
1125
+ };
1126
+ /** @description problem+json. RATE_LIMITED; retryAfterSeconds and the Retry-After header say how long to wait. */
1127
+ 429: {
1128
+ headers: {
1129
+ [name: string]: unknown;
1130
+ };
1131
+ content: {
1132
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1133
+ };
1134
+ };
1135
+ /** @description problem+json. SITE_REGISTRY_WARMING or INDEX_UNAVAILABLE — retry, the request was not wrong. */
1136
+ 503: {
1137
+ headers: {
1138
+ [name: string]: unknown;
1139
+ };
1140
+ content: {
1141
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1142
+ };
1143
+ };
1144
+ };
1145
+ };
1146
+ GetBrand: {
1147
+ parameters: {
1148
+ query?: never;
1149
+ header: {
1150
+ /** @description Publishable, preview or secret site key. Required on every request; secret keys are server-side only. */
1151
+ "X-Site-Key": string;
1152
+ /** @description Market code (e.g. "se"). Omit for the site's default market. */
1153
+ "X-Market"?: string;
1154
+ /** @description BCP-47 language tag. Omit to use the market's language. */
1155
+ "Accept-Language"?: string;
1156
+ };
1157
+ path: {
1158
+ slugOrId: string;
1159
+ };
1160
+ cookie?: never;
1161
+ };
1162
+ requestBody?: never;
1163
+ responses: {
1164
+ /** @description OK */
1165
+ 200: {
1166
+ headers: {
1167
+ [name: string]: unknown;
1168
+ };
1169
+ content: {
1170
+ "application/json": components["schemas"]["BrandDetailDto"];
1171
+ };
1172
+ };
1173
+ /** @description problem+json. MARKET_UNKNOWN (no such market on this site) or INVALID_PAGE. */
1174
+ 400: {
1175
+ headers: {
1176
+ [name: string]: unknown;
1177
+ };
1178
+ content: {
1179
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1180
+ };
1181
+ };
1182
+ /** @description problem+json. SITE_KEY_MISSING or SITE_KEY_INVALID. */
1183
+ 401: {
1184
+ headers: {
1185
+ [name: string]: unknown;
1186
+ };
1187
+ content: {
1188
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1189
+ };
1190
+ };
1191
+ /** @description problem+json. SECRET_KEY_FROM_BROWSER: a secret key was sent from a browser. */
1192
+ 403: {
1193
+ headers: {
1194
+ [name: string]: unknown;
1195
+ };
1196
+ content: {
1197
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1198
+ };
1199
+ };
1200
+ /** @description problem+json. BRAND_NOT_FOUND, or SITE_INACTIVE when the site itself is not live. */
1201
+ 404: {
1202
+ headers: {
1203
+ [name: string]: unknown;
1204
+ };
1205
+ content: {
1206
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1207
+ };
1208
+ };
1209
+ /** @description problem+json. RATE_LIMITED; retryAfterSeconds and the Retry-After header say how long to wait. */
1210
+ 429: {
1211
+ headers: {
1212
+ [name: string]: unknown;
1213
+ };
1214
+ content: {
1215
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1216
+ };
1217
+ };
1218
+ /** @description problem+json. SITE_REGISTRY_WARMING or INDEX_UNAVAILABLE — retry, the request was not wrong. */
1219
+ 503: {
1220
+ headers: {
1221
+ [name: string]: unknown;
1222
+ };
1223
+ content: {
1224
+ "application/problem+json": components["schemas"]["StorefrontProblem"];
1225
+ };
1226
+ };
1227
+ };
1228
+ };
961
1229
  GetCart: {
962
1230
  parameters: {
963
1231
  query?: never;