@epcc-sdk/sdks-shopper 0.0.40 → 0.0.41
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/README.md +3 -1
- package/dist/client/@tanstack/react-query.gen.cjs +34 -0
- package/dist/client/@tanstack/react-query.gen.cjs.map +1 -1
- package/dist/client/@tanstack/react-query.gen.d.cts +24 -2
- package/dist/client/@tanstack/react-query.gen.d.ts +24 -2
- package/dist/client/@tanstack/react-query.gen.mjs +32 -0
- package/dist/client/@tanstack/react-query.gen.mjs.map +1 -1
- package/dist/client/index.d.cts +2 -2
- package/dist/client/index.d.ts +2 -2
- package/dist/client/sdk.gen.cjs +18 -0
- package/dist/client/sdk.gen.cjs.map +1 -1
- package/dist/client/sdk.gen.d.cts +7 -2
- package/dist/client/sdk.gen.d.ts +7 -2
- package/dist/client/sdk.gen.mjs +17 -0
- package/dist/client/sdk.gen.mjs.map +1 -1
- package/dist/client/types.gen.cjs.map +1 -1
- package/dist/client/types.gen.d.cts +188 -1
- package/dist/client/types.gen.d.ts +188 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/react-query.d.cts +1 -1
- package/dist/react-query.d.ts +1 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -50,7 +50,7 @@ configureClient(config, {
|
|
|
50
50
|
For multiple stores or isolated instances:
|
|
51
51
|
|
|
52
52
|
```typescript
|
|
53
|
-
import { createShopperClient } from "@epcc-sdk/sdks-shopper
|
|
53
|
+
import { createShopperClient } from "@epcc-sdk/sdks-shopper";
|
|
54
54
|
|
|
55
55
|
const { client, auth } = createShopperClient(
|
|
56
56
|
{ baseUrl: "https://useast.api.elasticpath.com" },
|
|
@@ -589,6 +589,8 @@ const product = await getByContextProduct({
|
|
|
589
589
|
|
|
590
590
|
- **`getAFile`** (`GET /v2/files/{fileID}`)
|
|
591
591
|
|
|
592
|
+
- **`postMultiSearch`** (`POST /catalog/multi-search`)
|
|
593
|
+
|
|
592
594
|
|
|
593
595
|
|
|
594
596
|
|
|
@@ -266,6 +266,9 @@ __export(react_query_gen_exports, {
|
|
|
266
266
|
paymentSetupMutation: () => paymentSetupMutation,
|
|
267
267
|
paymentSetupOptions: () => paymentSetupOptions,
|
|
268
268
|
paymentSetupQueryKey: () => paymentSetupQueryKey,
|
|
269
|
+
postMultiSearchMutation: () => postMultiSearchMutation,
|
|
270
|
+
postMultiSearchOptions: () => postMultiSearchOptions,
|
|
271
|
+
postMultiSearchQueryKey: () => postMultiSearchQueryKey,
|
|
269
272
|
postV2AccountAddressMutation: () => postV2AccountAddressMutation,
|
|
270
273
|
postV2AccountAddressOptions: () => postV2AccountAddressOptions,
|
|
271
274
|
postV2AccountAddressQueryKey: () => postV2AccountAddressQueryKey,
|
|
@@ -2798,6 +2801,34 @@ const getAFileOptions = (options) => {
|
|
|
2798
2801
|
queryKey: getAFileQueryKey(options)
|
|
2799
2802
|
});
|
|
2800
2803
|
};
|
|
2804
|
+
const postMultiSearchQueryKey = (options) => [createQueryKey("postMultiSearch", options)];
|
|
2805
|
+
const postMultiSearchOptions = (options) => {
|
|
2806
|
+
return (0, import_react_query.queryOptions)({
|
|
2807
|
+
queryFn: async ({ queryKey, signal }) => {
|
|
2808
|
+
const { data } = await (0, import_sdk.postMultiSearch)({
|
|
2809
|
+
...options,
|
|
2810
|
+
...queryKey[0],
|
|
2811
|
+
signal,
|
|
2812
|
+
throwOnError: true
|
|
2813
|
+
});
|
|
2814
|
+
return data;
|
|
2815
|
+
},
|
|
2816
|
+
queryKey: postMultiSearchQueryKey(options)
|
|
2817
|
+
});
|
|
2818
|
+
};
|
|
2819
|
+
const postMultiSearchMutation = (options) => {
|
|
2820
|
+
const mutationOptions = {
|
|
2821
|
+
mutationFn: async (localOptions) => {
|
|
2822
|
+
const { data } = await (0, import_sdk.postMultiSearch)({
|
|
2823
|
+
...options,
|
|
2824
|
+
...localOptions,
|
|
2825
|
+
throwOnError: true
|
|
2826
|
+
});
|
|
2827
|
+
return data;
|
|
2828
|
+
}
|
|
2829
|
+
};
|
|
2830
|
+
return mutationOptions;
|
|
2831
|
+
};
|
|
2801
2832
|
// Annotate the CommonJS export names for ESM import in node:
|
|
2802
2833
|
0 && (module.exports = {
|
|
2803
2834
|
addCustomDiscountToCartItemMutation,
|
|
@@ -3048,6 +3079,9 @@ const getAFileOptions = (options) => {
|
|
|
3048
3079
|
paymentSetupMutation,
|
|
3049
3080
|
paymentSetupOptions,
|
|
3050
3081
|
paymentSetupQueryKey,
|
|
3082
|
+
postMultiSearchMutation,
|
|
3083
|
+
postMultiSearchOptions,
|
|
3084
|
+
postMultiSearchQueryKey,
|
|
3051
3085
|
postV2AccountAddressMutation,
|
|
3052
3086
|
postV2AccountAddressOptions,
|
|
3053
3087
|
postV2AccountAddressQueryKey,
|