@devite/shopware-client 1.3.1 → 1.3.3
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/dist/index.cjs +139 -134
- package/dist/index.d.cts +106 -69
- package/dist/index.d.mts +106 -69
- package/dist/index.d.ts +106 -69
- package/dist/index.mjs +135 -135
- package/dist/types/api/admin/product/Product.d.ts +1 -2
- package/dist/types/api/global/aggregation/Aggregation.d.ts +1 -1
- package/dist/types/api/global/aggregation/AggregationTerms.d.ts +2 -0
- package/dist/types/api/global/filter/EqualsFilter.d.ts +1 -1
- package/dist/types/api/global/filter/RangeFilter.d.ts +2 -2
- package/dist/types/api/global/query/Criteria.d.ts +1 -1
- package/dist/types/api/store/product/Product.d.ts +1 -2
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -99,7 +99,7 @@ interface SimpleFilter {
|
|
|
99
99
|
interface EqualsFilter {
|
|
100
100
|
type: "equals";
|
|
101
101
|
field: string;
|
|
102
|
-
value:
|
|
102
|
+
value: string | number | boolean | null;
|
|
103
103
|
}
|
|
104
104
|
|
|
105
105
|
interface MultiNotFilter {
|
|
@@ -111,12 +111,12 @@ interface MultiNotFilter {
|
|
|
111
111
|
interface RangeFilter {
|
|
112
112
|
type: "range";
|
|
113
113
|
field: string;
|
|
114
|
-
parameters:
|
|
114
|
+
parameters: {
|
|
115
115
|
gte?: number;
|
|
116
116
|
gt?: number;
|
|
117
117
|
lte?: number;
|
|
118
118
|
lt?: number;
|
|
119
|
-
}
|
|
119
|
+
};
|
|
120
120
|
}
|
|
121
121
|
|
|
122
122
|
type Filters = Array<SimpleFilter | EqualsFilter | MultiNotFilter | RangeFilter>;
|
|
@@ -175,19 +175,77 @@ interface AggregationRange {
|
|
|
175
175
|
}>;
|
|
176
176
|
}
|
|
177
177
|
|
|
178
|
+
interface Price {
|
|
179
|
+
currencyId: string;
|
|
180
|
+
gross: number;
|
|
181
|
+
net: number;
|
|
182
|
+
linked?: boolean;
|
|
183
|
+
listPrice?: {
|
|
184
|
+
currencyId?: string;
|
|
185
|
+
gross: number;
|
|
186
|
+
net: number;
|
|
187
|
+
linked?: boolean;
|
|
188
|
+
};
|
|
189
|
+
regulationPrice: {
|
|
190
|
+
currencyId?: string;
|
|
191
|
+
gross: number;
|
|
192
|
+
net: number;
|
|
193
|
+
linked?: boolean;
|
|
194
|
+
};
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
type ProductListingCriteria = Criteria & {
|
|
198
|
+
order?: string;
|
|
199
|
+
limit?: number;
|
|
200
|
+
p?: number;
|
|
201
|
+
manufacturer?: string;
|
|
202
|
+
"min-price"?: number;
|
|
203
|
+
"max-price"?: number;
|
|
204
|
+
rating?: number;
|
|
205
|
+
"shipping-free"?: boolean;
|
|
206
|
+
properties?: string;
|
|
207
|
+
"manufacturer-filter"?: boolean;
|
|
208
|
+
"price-filter"?: boolean;
|
|
209
|
+
"rating-filter"?: boolean;
|
|
210
|
+
"shipping-free-filter"?: boolean;
|
|
211
|
+
"property-filter"?: boolean;
|
|
212
|
+
"property-whitelist"?: string;
|
|
213
|
+
"reduce-aggregations"?: string | null;
|
|
214
|
+
} & {
|
|
215
|
+
filter?: Filters | SimpleFilter;
|
|
216
|
+
sort?: Array<Sort> | Sort;
|
|
217
|
+
"post-filter"?: Filters | SimpleFilter;
|
|
218
|
+
};
|
|
219
|
+
|
|
220
|
+
interface ProductListingFlags {
|
|
221
|
+
"no-aggregations"?: string | null;
|
|
222
|
+
"only-aggregations"?: string | null;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
type Includes = Record<string, Array<string>>;
|
|
226
|
+
|
|
227
|
+
type TotalCountMode = "none" | "exact" | "next-pages";
|
|
228
|
+
|
|
229
|
+
type GenericRecord = never | null | string | Array<string> | number | {
|
|
230
|
+
[key: string]: GenericRecord;
|
|
231
|
+
};
|
|
232
|
+
|
|
233
|
+
interface Rounding {
|
|
234
|
+
decimals: number;
|
|
235
|
+
interval: number;
|
|
236
|
+
roundForNet: boolean;
|
|
237
|
+
}
|
|
238
|
+
|
|
178
239
|
interface AggregationTerms {
|
|
179
240
|
name: string;
|
|
180
241
|
type: "terms";
|
|
181
242
|
field: string;
|
|
182
243
|
limit?: number;
|
|
183
244
|
sort?: Array<Sort>;
|
|
245
|
+
aggregation?: Aggregation;
|
|
184
246
|
}
|
|
185
247
|
|
|
186
|
-
type Aggregation =
|
|
187
|
-
|
|
188
|
-
type TotalCountMode = "none" | "exact" | "next-pages";
|
|
189
|
-
|
|
190
|
-
type Includes = Record<string, Array<string>>;
|
|
248
|
+
type Aggregation = AggregationEntity | AggregationFilter | AggregationHistogram | AggregationMetrics | AggregationRange | AggregationTerms;
|
|
191
249
|
|
|
192
250
|
interface Criteria {
|
|
193
251
|
page?: number;
|
|
@@ -199,7 +257,7 @@ interface Criteria {
|
|
|
199
257
|
associations?: Record<string, Criteria>;
|
|
200
258
|
"post-filter"?: Filters;
|
|
201
259
|
sort?: Array<Sort>;
|
|
202
|
-
aggregations?: Aggregation
|
|
260
|
+
aggregations?: Array<Aggregation>;
|
|
203
261
|
fields?: Array<string>;
|
|
204
262
|
grouping?: Array<string>;
|
|
205
263
|
/** @default "none" */
|
|
@@ -207,10 +265,6 @@ interface Criteria {
|
|
|
207
265
|
includes?: Includes;
|
|
208
266
|
}
|
|
209
267
|
|
|
210
|
-
type GenericRecord = never | null | string | Array<string> | number | {
|
|
211
|
-
[key: string]: GenericRecord;
|
|
212
|
-
};
|
|
213
|
-
|
|
214
268
|
interface Locale$1 {
|
|
215
269
|
id: string;
|
|
216
270
|
code: string;
|
|
@@ -262,12 +316,6 @@ interface SalesChannel$1 {
|
|
|
262
316
|
analyticsId?: string;
|
|
263
317
|
}
|
|
264
318
|
|
|
265
|
-
interface Rounding {
|
|
266
|
-
decimals: number;
|
|
267
|
-
interval: number;
|
|
268
|
-
roundForNet: boolean;
|
|
269
|
-
}
|
|
270
|
-
|
|
271
319
|
interface Currency$1 {
|
|
272
320
|
id: string;
|
|
273
321
|
factor: number;
|
|
@@ -487,25 +535,6 @@ interface Rule$1 {
|
|
|
487
535
|
extensions?: any;
|
|
488
536
|
}
|
|
489
537
|
|
|
490
|
-
interface Price {
|
|
491
|
-
currencyId: string;
|
|
492
|
-
gross: number;
|
|
493
|
-
net: number;
|
|
494
|
-
linked?: boolean;
|
|
495
|
-
listPrice?: {
|
|
496
|
-
currencyId?: string;
|
|
497
|
-
gross: number;
|
|
498
|
-
net: number;
|
|
499
|
-
linked?: boolean;
|
|
500
|
-
};
|
|
501
|
-
regulationPrice: {
|
|
502
|
-
currencyId?: string;
|
|
503
|
-
gross: number;
|
|
504
|
-
net: number;
|
|
505
|
-
linked?: boolean;
|
|
506
|
-
};
|
|
507
|
-
}
|
|
508
|
-
|
|
509
538
|
interface ShippingMethodPrice$1 {
|
|
510
539
|
id: string;
|
|
511
540
|
shippingMethodId: string;
|
|
@@ -1415,7 +1444,7 @@ interface Product$1 {
|
|
|
1415
1444
|
cover?: ProductMedia$1;
|
|
1416
1445
|
cmsPage?: CmsPage$1;
|
|
1417
1446
|
canonicalProduct?: Product$1;
|
|
1418
|
-
media?: Array<
|
|
1447
|
+
media?: Array<ProductMedia$1>;
|
|
1419
1448
|
crossSellings?: Array<ProductCrossSelling$1>;
|
|
1420
1449
|
configuratorSettings?: Array<ProductConfiguratorSetting$1>;
|
|
1421
1450
|
productReviews?: Array<ProductReview$1>;
|
|
@@ -2681,7 +2710,7 @@ type Product = Product$1 & {
|
|
|
2681
2710
|
featureSet?: ProductFeatureSet;
|
|
2682
2711
|
cmsPage?: CmsPage;
|
|
2683
2712
|
canonicalProduct?: Product;
|
|
2684
|
-
media?: Array<
|
|
2713
|
+
media?: Array<ProductMedia>;
|
|
2685
2714
|
crossSellings?: Array<ProductCrossSelling>;
|
|
2686
2715
|
crossSellingAssignedProducts?: Array<ProductCrossSellingAssignedProduct>;
|
|
2687
2716
|
configuratorSettings?: Array<ProductConfiguratorSetting>;
|
|
@@ -12042,29 +12071,6 @@ declare class CategoryClient extends Client {
|
|
|
12042
12071
|
getNavigationMenu(activeId: string, rootId: string, includeSeoUrls: boolean, request?: NavigationMenuRequest): Promise<NavigationMenuResponse>;
|
|
12043
12072
|
}
|
|
12044
12073
|
|
|
12045
|
-
type ProductListingCriteria = Criteria & {
|
|
12046
|
-
order?: string;
|
|
12047
|
-
limit?: number;
|
|
12048
|
-
p?: number;
|
|
12049
|
-
manufacturer?: string;
|
|
12050
|
-
"min-price"?: number;
|
|
12051
|
-
"max-price"?: number;
|
|
12052
|
-
rating?: number;
|
|
12053
|
-
"shipping-free"?: boolean;
|
|
12054
|
-
properties?: string;
|
|
12055
|
-
"manufacturer-filter"?: boolean;
|
|
12056
|
-
"price-filter"?: boolean;
|
|
12057
|
-
"rating-filter"?: boolean;
|
|
12058
|
-
"shipping-free-filter"?: boolean;
|
|
12059
|
-
"property-filter"?: boolean;
|
|
12060
|
-
"property-whitelist"?: string;
|
|
12061
|
-
"reduce-aggregations"?: string | null;
|
|
12062
|
-
} & {
|
|
12063
|
-
filter?: Filters | SimpleFilter;
|
|
12064
|
-
sort?: Array<Sort> | Sort;
|
|
12065
|
-
"post-filter"?: Filters | SimpleFilter;
|
|
12066
|
-
};
|
|
12067
|
-
|
|
12068
12074
|
type CMSPageResolveResponse = CmsPage$1;
|
|
12069
12075
|
interface ContactFormSubmitRequest {
|
|
12070
12076
|
salutationId: string;
|
|
@@ -12303,11 +12309,6 @@ declare class OrderClient extends Client {
|
|
|
12303
12309
|
createFromCart(request?: OrderFromCartRequest): Promise<OrderFromCartResponse>;
|
|
12304
12310
|
}
|
|
12305
12311
|
|
|
12306
|
-
interface ProductListingFlags {
|
|
12307
|
-
"no-aggregations"?: string | null;
|
|
12308
|
-
"only-aggregations"?: string | null;
|
|
12309
|
-
}
|
|
12310
|
-
|
|
12311
12312
|
type ProductListRequest = Criteria;
|
|
12312
12313
|
type ProductListResponse = EntitySearchResult & {
|
|
12313
12314
|
elements?: Array<Product$1>;
|
|
@@ -12550,4 +12551,40 @@ declare class ShopwareError extends Error {
|
|
|
12550
12551
|
constructor(message: string, response: ClientResponse);
|
|
12551
12552
|
}
|
|
12552
12553
|
|
|
12553
|
-
|
|
12554
|
+
declare class BinaryPayload extends Payload<Blob> {
|
|
12555
|
+
static CONTENT_TYPE: string;
|
|
12556
|
+
data?: Blob;
|
|
12557
|
+
constructor(data?: Blob);
|
|
12558
|
+
contentType(): string;
|
|
12559
|
+
/**
|
|
12560
|
+
* @throws {SyntaxError} if the data is not a valid JSON string
|
|
12561
|
+
*/
|
|
12562
|
+
deserialize(data: Blob): Promise<void>;
|
|
12563
|
+
serialize(): Blob | undefined;
|
|
12564
|
+
}
|
|
12565
|
+
|
|
12566
|
+
declare class HtmlPayload extends Payload<string> {
|
|
12567
|
+
static CONTENT_TYPE: string;
|
|
12568
|
+
data?: string;
|
|
12569
|
+
constructor(data?: string);
|
|
12570
|
+
contentType(): string;
|
|
12571
|
+
/**
|
|
12572
|
+
* @throws {SyntaxError} if the data is not a valid JSON string
|
|
12573
|
+
*/
|
|
12574
|
+
deserialize(data: Blob): Promise<void>;
|
|
12575
|
+
serialize(): string | undefined;
|
|
12576
|
+
}
|
|
12577
|
+
|
|
12578
|
+
declare class JsonPayload extends Payload<string> {
|
|
12579
|
+
static CONTENT_TYPE: string;
|
|
12580
|
+
data?: object;
|
|
12581
|
+
constructor(data?: object);
|
|
12582
|
+
contentType(): string;
|
|
12583
|
+
/**
|
|
12584
|
+
* @throws {SyntaxError} if the data is not a valid JSON string
|
|
12585
|
+
*/
|
|
12586
|
+
deserialize(data: Blob): Promise<void>;
|
|
12587
|
+
serialize(): string | undefined;
|
|
12588
|
+
}
|
|
12589
|
+
|
|
12590
|
+
export { AdminShopwareClient, BinaryPayload, type ClientRequestOptions, type ClientResponse, HTTPRequestMethod, HtmlPayload, JsonPayload, type OAuthResponseBody, type OAuthScope, Payload, type RequestCacheEntry, ShopwareClient, ShopwareError, StoreShopwareClient };
|