@epcc-sdk/sdks-shopper 0.0.4 → 0.0.6
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/client/@tanstack/react-query.gen.d.ts +65 -3
- package/dist/client/@tanstack/react-query.gen.js +41 -1
- package/dist/client/sdk.gen.d.ts +25 -10
- package/dist/client/sdk.gen.js +26 -0
- package/dist/client/transformers.gen.d.ts +2 -1
- package/dist/client/transformers.gen.js +16 -0
- package/dist/client/types.gen.d.ts +442 -156
- package/package.json +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Options } from "@hey-api/client-fetch";
|
|
2
2
|
import { type UseMutationOptions } from "@tanstack/react-query";
|
|
3
|
-
import type { GetByContextReleaseData, GetByContextAllHierarchiesData, GetByContextHierarchyData, GetByContextHierarchyNodesData, GetByContextHierarchyChildNodesData, GetByContextAllNodesData, GetByContextNodeData, GetByContextChildNodesData, GetByContextAllProductsData, GetByContextProductData, GetByContextComponentProductIdsData, GetByContextChildProductsData, GetByContextProductsForHierarchyData, GetByContextProductsForNodeData, ConfigureByContextProductData, GetCatalogsData, CreateCatalogData, DeleteCatalogByIdData, GetCatalogByIdData, UpdateCatalogData, DeleteReleasesData, GetReleasesData, PublishReleaseData, DeleteReleaseByIdData, GetReleaseByIdData, GetRulesData, CreateRuleData, DeleteRuleByIdData, GetRuleByIdData, UpdateRuleData, GetAllHierarchiesData, GetHierarchyData, GetHierarchyNodesData, GetHierarchyChildNodesData, GetAllNodesData, GetNodeData, GetChildNodesData, GetAllProductsData, GetProductData, GetComponentProductIdsData, GetChildProductsData, GetProductsForHierarchyData, GetProductsForNodeData, GetCartsData, CreateACartData, DeleteACartData, GetCartData, UpdateACartData, DeleteAllCartItemsData, GetCartItemsData, ManageCartsData, BulkUpdateItemsInCartData, DeleteACartItemData, UpdateACartItemData, DeleteAccountCartAssociationData, CreateAccountCartAssociationData, CreateAccountCartAssociationResponse, DeleteCustomerCartAssociationData, CreateCustomerCartAssociationData, DeleteAPromotionViaPromotionCodeData, AddTaxItemToCartData, BulkDeleteTaxItemsFromCartData, BulkAddTaxItemsToCartData, DeleteATaxItemData, UpdateATaxItemData, BulkDeleteCustomDiscountsFromCartData, BulkAddCustomDiscountsToCartData, DeleteCustomDiscountFromCartData, UpdateCustomDiscountForCartData, AddCustomDiscountToCartItemData, DeleteCustomDiscountFromCartItemData, UpdateCustomDiscountForCartItemData, CreateCartPaymentIntentData, CheckoutApiData, GetCustomerOrdersData, GetAnOrderData, UpdateAnOrderData, GetOrderItemsData, AnonymizeOrdersData, PaymentSetupData, ConfirmPaymentData, CaptureATransactionData, RefundATransactionData, GetOrderTransactionsData, GetATransactionData, CancelATransactionData, GetSubscriptionProductData, GetPlanData, ListOfferingsData, GetOfferingData, ListOfferingPlansData, ListOfferingFeaturesData, ListOfferingProductsData, GetFeatureData } from "../types.gen";
|
|
3
|
+
import type { GetByContextReleaseData, GetByContextAllHierarchiesData, GetByContextHierarchyData, GetByContextHierarchyNodesData, GetByContextHierarchyChildNodesData, GetByContextAllNodesData, GetByContextNodeData, GetByContextChildNodesData, GetByContextAllProductsData, GetByContextProductData, GetByContextComponentProductIdsData, GetByContextChildProductsData, GetByContextProductsForHierarchyData, GetByContextProductsForNodeData, ConfigureByContextProductData, GetCatalogsData, CreateCatalogData, DeleteCatalogByIdData, GetCatalogByIdData, UpdateCatalogData, DeleteReleasesData, GetReleasesData, PublishReleaseData, DeleteReleaseByIdData, GetReleaseByIdData, GetRulesData, CreateRuleData, DeleteRuleByIdData, GetRuleByIdData, UpdateRuleData, GetAllHierarchiesData, GetHierarchyData, GetHierarchyNodesData, GetHierarchyChildNodesData, GetAllNodesData, GetNodeData, GetChildNodesData, GetAllProductsData, GetProductData, GetComponentProductIdsData, GetChildProductsData, GetProductsForHierarchyData, GetProductsForNodeData, GetCartsData, CreateACartData, DeleteACartData, GetCartData, UpdateACartData, DeleteAllCartItemsData, GetCartItemsData, ManageCartsData, BulkUpdateItemsInCartData, DeleteACartItemData, UpdateACartItemData, DeleteAccountCartAssociationData, CreateAccountCartAssociationData, CreateAccountCartAssociationResponse, DeleteCustomerCartAssociationData, CreateCustomerCartAssociationData, DeleteAPromotionViaPromotionCodeData, AddTaxItemToCartData, BulkDeleteTaxItemsFromCartData, BulkAddTaxItemsToCartData, DeleteATaxItemData, UpdateATaxItemData, BulkDeleteCustomDiscountsFromCartData, BulkAddCustomDiscountsToCartData, DeleteCustomDiscountFromCartData, UpdateCustomDiscountForCartData, AddCustomDiscountToCartItemData, DeleteCustomDiscountFromCartItemData, UpdateCustomDiscountForCartItemData, CreateCartPaymentIntentData, CheckoutApiData, GetCustomerOrdersData, GetAnOrderData, UpdateAnOrderData, GetOrderItemsData, AnonymizeOrdersData, PaymentSetupData, ConfirmPaymentData, CaptureATransactionData, RefundATransactionData, GetOrderTransactionsData, GetATransactionData, CancelATransactionData, GetSubscriptionProductData, GetPlanData, ListOfferingsData, GetOfferingData, ListOfferingPlansData, ListOfferingFeaturesData, ListOfferingProductsData, GetFeatureData, GetStockData, ListLocationsData } from "../types.gen";
|
|
4
4
|
export declare const getByContextReleaseQueryKey: (options?: Options<GetByContextReleaseData>) => (Pick<Options<GetByContextReleaseData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
5
5
|
_id: string;
|
|
6
6
|
_infinite?: boolean;
|
|
@@ -858,11 +858,11 @@ export declare const createACartMutation: (options?: Partial<Options<CreateACart
|
|
|
858
858
|
data?: import("../types.gen").CartResponse;
|
|
859
859
|
}, import("../types.gen").ResponseError, Options<CreateACartData>, unknown>;
|
|
860
860
|
export declare const deleteACartMutation: (options?: Partial<Options<DeleteACartData>>) => UseMutationOptions<void, import("../types.gen").ResponseError, Options<DeleteACartData>, unknown>;
|
|
861
|
-
export declare const getCartQueryKey: (options
|
|
861
|
+
export declare const getCartQueryKey: (options?: Options<GetCartData>) => (Pick<Options<GetCartData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
862
862
|
_id: string;
|
|
863
863
|
_infinite?: boolean;
|
|
864
864
|
})[];
|
|
865
|
-
export declare const getCartOptions: (options
|
|
865
|
+
export declare const getCartOptions: (options?: Options<GetCartData>) => import("@tanstack/react-query").OmitKeyof<import("@tanstack/react-query").UseQueryOptions<import("../types.gen").ResponseData & {
|
|
866
866
|
data?: import("../types.gen").CartResponse;
|
|
867
867
|
}, Error, import("../types.gen").ResponseData & {
|
|
868
868
|
data?: import("../types.gen").CartResponse;
|
|
@@ -1764,3 +1764,65 @@ export declare const getFeatureOptions: (options: Options<GetFeatureData>) => im
|
|
|
1764
1764
|
[dataTagErrorSymbol]: Error;
|
|
1765
1765
|
};
|
|
1766
1766
|
};
|
|
1767
|
+
export declare const getStockQueryKey: (options: Options<GetStockData>) => (Pick<Options<GetStockData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1768
|
+
_id: string;
|
|
1769
|
+
_infinite?: boolean;
|
|
1770
|
+
})[];
|
|
1771
|
+
export declare const getStockOptions: (options: Options<GetStockData>) => import("@tanstack/react-query").OmitKeyof<import("@tanstack/react-query").UseQueryOptions<{
|
|
1772
|
+
data: import("../types.gen").StockResponse;
|
|
1773
|
+
}, Error, {
|
|
1774
|
+
data: import("../types.gen").StockResponse;
|
|
1775
|
+
}, (Pick<Options<GetStockData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1776
|
+
_id: string;
|
|
1777
|
+
_infinite?: boolean;
|
|
1778
|
+
})[]>, "queryFn"> & {
|
|
1779
|
+
queryFn?: import("@tanstack/react-query").QueryFunction<{
|
|
1780
|
+
data: import("../types.gen").StockResponse;
|
|
1781
|
+
}, (Pick<Options<GetStockData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1782
|
+
_id: string;
|
|
1783
|
+
_infinite?: boolean;
|
|
1784
|
+
})[], never> | undefined;
|
|
1785
|
+
} & {
|
|
1786
|
+
queryKey: (Pick<Options<GetStockData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1787
|
+
_id: string;
|
|
1788
|
+
_infinite?: boolean;
|
|
1789
|
+
})[] & {
|
|
1790
|
+
[dataTagSymbol]: {
|
|
1791
|
+
data: import("../types.gen").StockResponse;
|
|
1792
|
+
};
|
|
1793
|
+
[dataTagErrorSymbol]: Error;
|
|
1794
|
+
};
|
|
1795
|
+
};
|
|
1796
|
+
export declare const listLocationsQueryKey: (options?: Options<ListLocationsData>) => (Pick<Options<ListLocationsData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1797
|
+
_id: string;
|
|
1798
|
+
_infinite?: boolean;
|
|
1799
|
+
})[];
|
|
1800
|
+
export declare const listLocationsOptions: (options?: Options<ListLocationsData>) => import("@tanstack/react-query").OmitKeyof<import("@tanstack/react-query").UseQueryOptions<{
|
|
1801
|
+
data?: Array<import("../types.gen").Location>;
|
|
1802
|
+
links?: import("../types.gen").Links2;
|
|
1803
|
+
}, Error, {
|
|
1804
|
+
data?: Array<import("../types.gen").Location>;
|
|
1805
|
+
links?: import("../types.gen").Links2;
|
|
1806
|
+
}, (Pick<Options<ListLocationsData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1807
|
+
_id: string;
|
|
1808
|
+
_infinite?: boolean;
|
|
1809
|
+
})[]>, "queryFn"> & {
|
|
1810
|
+
queryFn?: import("@tanstack/react-query").QueryFunction<{
|
|
1811
|
+
data?: Array<import("../types.gen").Location>;
|
|
1812
|
+
links?: import("../types.gen").Links2;
|
|
1813
|
+
}, (Pick<Options<ListLocationsData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1814
|
+
_id: string;
|
|
1815
|
+
_infinite?: boolean;
|
|
1816
|
+
})[], never> | undefined;
|
|
1817
|
+
} & {
|
|
1818
|
+
queryKey: (Pick<Options<ListLocationsData>, "body" | "headers" | "path" | "query" | "baseUrl"> & {
|
|
1819
|
+
_id: string;
|
|
1820
|
+
_infinite?: boolean;
|
|
1821
|
+
})[] & {
|
|
1822
|
+
[dataTagSymbol]: {
|
|
1823
|
+
data?: Array<import("../types.gen").Location>;
|
|
1824
|
+
links?: import("../types.gen").Links2;
|
|
1825
|
+
};
|
|
1826
|
+
[dataTagErrorSymbol]: Error;
|
|
1827
|
+
};
|
|
1828
|
+
};
|
|
@@ -47,7 +47,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
47
47
|
}
|
|
48
48
|
};
|
|
49
49
|
import { queryOptions } from "@tanstack/react-query";
|
|
50
|
-
import { getByContextRelease, getByContextAllHierarchies, getByContextHierarchy, getByContextHierarchyNodes, getByContextHierarchyChildNodes, getByContextAllNodes, getByContextNode, getByContextChildNodes, getByContextAllProducts, getByContextProduct, getByContextComponentProductIds, getByContextChildProducts, getByContextProductsForHierarchy, getByContextProductsForNode, configureByContextProduct, getCatalogs, createCatalog, deleteCatalogById, getCatalogById, updateCatalog, deleteReleases, getReleases, publishRelease, deleteReleaseById, getReleaseById, getRules, createRule, deleteRuleById, getRuleById, updateRule, getAllHierarchies, getHierarchy, getHierarchyNodes, getHierarchyChildNodes, getAllNodes, getNode, getChildNodes, getAllProducts, getProduct, getComponentProductIds, getChildProducts, getProductsForHierarchy, getProductsForNode, getCarts, createACart, deleteACart, getCart, updateACart, deleteAllCartItems, getCartItems, manageCarts, bulkUpdateItemsInCart, deleteACartItem, updateACartItem, deleteAccountCartAssociation, createAccountCartAssociation, deleteCustomerCartAssociation, createCustomerCartAssociation, deleteAPromotionViaPromotionCode, addTaxItemToCart, bulkDeleteTaxItemsFromCart, bulkAddTaxItemsToCart, deleteATaxItem, updateATaxItem, bulkDeleteCustomDiscountsFromCart, bulkAddCustomDiscountsToCart, deleteCustomDiscountFromCart, updateCustomDiscountForCart, addCustomDiscountToCartItem, deleteCustomDiscountFromCartItem, updateCustomDiscountForCartItem, createCartPaymentIntent, checkoutApi, getCustomerOrders, getAnOrder, updateAnOrder, getOrderItems, anonymizeOrders, paymentSetup, confirmPayment, captureATransaction, refundATransaction, getOrderTransactions, getATransaction, cancelATransaction, getSubscriptionProduct, getPlan, listOfferings, getOffering, listOfferingPlans, listOfferingFeatures, listOfferingProducts, getFeature, client, } from "../sdk.gen";
|
|
50
|
+
import { getByContextRelease, getByContextAllHierarchies, getByContextHierarchy, getByContextHierarchyNodes, getByContextHierarchyChildNodes, getByContextAllNodes, getByContextNode, getByContextChildNodes, getByContextAllProducts, getByContextProduct, getByContextComponentProductIds, getByContextChildProducts, getByContextProductsForHierarchy, getByContextProductsForNode, configureByContextProduct, getCatalogs, createCatalog, deleteCatalogById, getCatalogById, updateCatalog, deleteReleases, getReleases, publishRelease, deleteReleaseById, getReleaseById, getRules, createRule, deleteRuleById, getRuleById, updateRule, getAllHierarchies, getHierarchy, getHierarchyNodes, getHierarchyChildNodes, getAllNodes, getNode, getChildNodes, getAllProducts, getProduct, getComponentProductIds, getChildProducts, getProductsForHierarchy, getProductsForNode, getCarts, createACart, deleteACart, getCart, updateACart, deleteAllCartItems, getCartItems, manageCarts, bulkUpdateItemsInCart, deleteACartItem, updateACartItem, deleteAccountCartAssociation, createAccountCartAssociation, deleteCustomerCartAssociation, createCustomerCartAssociation, deleteAPromotionViaPromotionCode, addTaxItemToCart, bulkDeleteTaxItemsFromCart, bulkAddTaxItemsToCart, deleteATaxItem, updateATaxItem, bulkDeleteCustomDiscountsFromCart, bulkAddCustomDiscountsToCart, deleteCustomDiscountFromCart, updateCustomDiscountForCart, addCustomDiscountToCartItem, deleteCustomDiscountFromCartItem, updateCustomDiscountForCartItem, createCartPaymentIntent, checkoutApi, getCustomerOrders, getAnOrder, updateAnOrder, getOrderItems, anonymizeOrders, paymentSetup, confirmPayment, captureATransaction, refundATransaction, getOrderTransactions, getATransaction, cancelATransaction, getSubscriptionProduct, getPlan, listOfferings, getOffering, listOfferingPlans, listOfferingFeatures, listOfferingProducts, getFeature, getStock, listLocations, client, } from "../sdk.gen";
|
|
51
51
|
var createQueryKey = function (id, options, infinite) {
|
|
52
52
|
var _a;
|
|
53
53
|
var params = {
|
|
@@ -2065,3 +2065,43 @@ export var getFeatureOptions = function (options) {
|
|
|
2065
2065
|
queryKey: getFeatureQueryKey(options),
|
|
2066
2066
|
});
|
|
2067
2067
|
};
|
|
2068
|
+
export var getStockQueryKey = function (options) { return [
|
|
2069
|
+
createQueryKey("getStock", options),
|
|
2070
|
+
]; };
|
|
2071
|
+
export var getStockOptions = function (options) {
|
|
2072
|
+
return queryOptions({
|
|
2073
|
+
queryFn: function (_a) { return __awaiter(void 0, [_a], void 0, function (_b) {
|
|
2074
|
+
var data;
|
|
2075
|
+
var queryKey = _b.queryKey, signal = _b.signal;
|
|
2076
|
+
return __generator(this, function (_c) {
|
|
2077
|
+
switch (_c.label) {
|
|
2078
|
+
case 0: return [4 /*yield*/, getStock(__assign(__assign(__assign({}, options), queryKey[0]), { signal: signal, throwOnError: true }))];
|
|
2079
|
+
case 1:
|
|
2080
|
+
data = (_c.sent()).data;
|
|
2081
|
+
return [2 /*return*/, data];
|
|
2082
|
+
}
|
|
2083
|
+
});
|
|
2084
|
+
}); },
|
|
2085
|
+
queryKey: getStockQueryKey(options),
|
|
2086
|
+
});
|
|
2087
|
+
};
|
|
2088
|
+
export var listLocationsQueryKey = function (options) { return [
|
|
2089
|
+
createQueryKey("listLocations", options),
|
|
2090
|
+
]; };
|
|
2091
|
+
export var listLocationsOptions = function (options) {
|
|
2092
|
+
return queryOptions({
|
|
2093
|
+
queryFn: function (_a) { return __awaiter(void 0, [_a], void 0, function (_b) {
|
|
2094
|
+
var data;
|
|
2095
|
+
var queryKey = _b.queryKey, signal = _b.signal;
|
|
2096
|
+
return __generator(this, function (_c) {
|
|
2097
|
+
switch (_c.label) {
|
|
2098
|
+
case 0: return [4 /*yield*/, listLocations(__assign(__assign(__assign({}, options), queryKey[0]), { signal: signal, throwOnError: true }))];
|
|
2099
|
+
case 1:
|
|
2100
|
+
data = (_c.sent()).data;
|
|
2101
|
+
return [2 /*return*/, data];
|
|
2102
|
+
}
|
|
2103
|
+
});
|
|
2104
|
+
}); },
|
|
2105
|
+
queryKey: listLocationsQueryKey(options),
|
|
2106
|
+
});
|
|
2107
|
+
};
|
package/dist/client/sdk.gen.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Options } from "@hey-api/client-fetch";
|
|
2
|
-
import type { GetByContextReleaseData, GetByContextAllHierarchiesData, GetByContextHierarchyData, GetByContextHierarchyNodesData, GetByContextHierarchyChildNodesData, GetByContextAllNodesData, GetByContextNodeData, GetByContextChildNodesData, GetByContextAllProductsData, GetByContextProductData, GetByContextComponentProductIdsData, GetByContextChildProductsData, GetByContextProductsForHierarchyData, GetByContextProductsForNodeData, ConfigureByContextProductData, GetCatalogsData, CreateCatalogData, DeleteCatalogByIdData, GetCatalogByIdData, UpdateCatalogData, DeleteReleasesData, GetReleasesData, PublishReleaseData, DeleteReleaseByIdData, GetReleaseByIdData, GetRulesData, CreateRuleData, DeleteRuleByIdData, GetRuleByIdData, UpdateRuleData, GetAllHierarchiesData, GetHierarchyData, GetHierarchyNodesData, GetHierarchyChildNodesData, GetAllNodesData, GetNodeData, GetChildNodesData, GetAllProductsData, GetProductData, GetComponentProductIdsData, GetChildProductsData, GetProductsForHierarchyData, GetProductsForNodeData, GetCartsData, CreateACartData, DeleteACartData, GetCartData, UpdateACartData, DeleteAllCartItemsData, GetCartItemsData, ManageCartsData, BulkUpdateItemsInCartData, DeleteACartItemData, UpdateACartItemData, DeleteAccountCartAssociationData, CreateAccountCartAssociationData, CreateAccountCartAssociationResponse, DeleteCustomerCartAssociationData, CreateCustomerCartAssociationData, DeleteAPromotionViaPromotionCodeData, AddTaxItemToCartData, BulkDeleteTaxItemsFromCartData, BulkAddTaxItemsToCartData, DeleteATaxItemData, UpdateATaxItemData, BulkDeleteCustomDiscountsFromCartData, BulkAddCustomDiscountsToCartData, DeleteCustomDiscountFromCartData, UpdateCustomDiscountForCartData, AddCustomDiscountToCartItemData, DeleteCustomDiscountFromCartItemData, UpdateCustomDiscountForCartItemData, CreateCartPaymentIntentData, CheckoutApiData, GetCustomerOrdersData, GetAnOrderData, UpdateAnOrderData, GetOrderItemsData, AnonymizeOrdersData, PaymentSetupData, ConfirmPaymentData, CaptureATransactionData, RefundATransactionData, GetOrderTransactionsData, GetATransactionData, CancelATransactionData, GetSubscriptionProductData, GetPlanData, ListOfferingsData, GetOfferingData, ListOfferingPlansData, ListOfferingFeaturesData, ListOfferingProductsData, GetFeatureData } from "./types.gen";
|
|
2
|
+
import type { GetByContextReleaseData, GetByContextAllHierarchiesData, GetByContextHierarchyData, GetByContextHierarchyNodesData, GetByContextHierarchyChildNodesData, GetByContextAllNodesData, GetByContextNodeData, GetByContextChildNodesData, GetByContextAllProductsData, GetByContextProductData, GetByContextComponentProductIdsData, GetByContextChildProductsData, GetByContextProductsForHierarchyData, GetByContextProductsForNodeData, ConfigureByContextProductData, GetCatalogsData, CreateCatalogData, DeleteCatalogByIdData, GetCatalogByIdData, UpdateCatalogData, DeleteReleasesData, GetReleasesData, PublishReleaseData, DeleteReleaseByIdData, GetReleaseByIdData, GetRulesData, CreateRuleData, DeleteRuleByIdData, GetRuleByIdData, UpdateRuleData, GetAllHierarchiesData, GetHierarchyData, GetHierarchyNodesData, GetHierarchyChildNodesData, GetAllNodesData, GetNodeData, GetChildNodesData, GetAllProductsData, GetProductData, GetComponentProductIdsData, GetChildProductsData, GetProductsForHierarchyData, GetProductsForNodeData, GetCartsData, CreateACartData, DeleteACartData, GetCartData, UpdateACartData, DeleteAllCartItemsData, GetCartItemsData, ManageCartsData, BulkUpdateItemsInCartData, DeleteACartItemData, UpdateACartItemData, DeleteAccountCartAssociationData, CreateAccountCartAssociationData, CreateAccountCartAssociationResponse, DeleteCustomerCartAssociationData, CreateCustomerCartAssociationData, DeleteAPromotionViaPromotionCodeData, AddTaxItemToCartData, BulkDeleteTaxItemsFromCartData, BulkAddTaxItemsToCartData, DeleteATaxItemData, UpdateATaxItemData, BulkDeleteCustomDiscountsFromCartData, BulkAddCustomDiscountsToCartData, DeleteCustomDiscountFromCartData, UpdateCustomDiscountForCartData, AddCustomDiscountToCartItemData, DeleteCustomDiscountFromCartItemData, UpdateCustomDiscountForCartItemData, CreateCartPaymentIntentData, CheckoutApiData, GetCustomerOrdersData, GetAnOrderData, UpdateAnOrderData, GetOrderItemsData, AnonymizeOrdersData, PaymentSetupData, ConfirmPaymentData, CaptureATransactionData, RefundATransactionData, GetOrderTransactionsData, GetATransactionData, CancelATransactionData, GetSubscriptionProductData, GetPlanData, ListOfferingsData, GetOfferingData, ListOfferingPlansData, ListOfferingFeaturesData, ListOfferingProductsData, GetFeatureData, GetStockData, ListLocationsData } from "./types.gen";
|
|
3
3
|
export declare const client: import("@hey-api/client-fetch").Client<Request, Response, unknown, import("@hey-api/client-fetch").RequestOptions<boolean, string>>;
|
|
4
4
|
/**
|
|
5
5
|
* Get the catalog release as shoppers
|
|
@@ -1147,7 +1147,7 @@ export declare const deleteACart: <ThrowOnError extends boolean = false>(options
|
|
|
1147
1147
|
* | `include` | Optional | `string` | Comma-delimited string of entities that can be included. The information included are `items`,`tax_items`, `custom_discounts`, or `promotions`. |
|
|
1148
1148
|
*
|
|
1149
1149
|
*/
|
|
1150
|
-
export declare const getCart: <ThrowOnError extends boolean = false>(options
|
|
1150
|
+
export declare const getCart: <ThrowOnError extends boolean = false>(options?: Options<GetCartData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").ResponseData & {
|
|
1151
1151
|
data?: import("./types.gen").CartResponse;
|
|
1152
1152
|
}, import("./types.gen").ResponseError, ThrowOnError>;
|
|
1153
1153
|
/**
|
|
@@ -2193,13 +2193,13 @@ export declare const cancelATransaction: <ThrowOnError extends boolean = false>(
|
|
|
2193
2193
|
*/
|
|
2194
2194
|
export declare const getSubscriptionProduct: <ThrowOnError extends boolean = false>(options: Options<GetSubscriptionProductData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2195
2195
|
data?: import("./types.gen").Product2;
|
|
2196
|
-
}, import("./types.gen").
|
|
2196
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2197
2197
|
/**
|
|
2198
2198
|
* Get plan
|
|
2199
2199
|
*/
|
|
2200
2200
|
export declare const getPlan: <ThrowOnError extends boolean = false>(options: Options<GetPlanData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2201
2201
|
data?: import("./types.gen").Plan;
|
|
2202
|
-
}, import("./types.gen").
|
|
2202
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2203
2203
|
/**
|
|
2204
2204
|
* List offerings
|
|
2205
2205
|
* Retrieves a list of all subscription offerings.
|
|
@@ -2220,38 +2220,53 @@ export declare const listOfferings: <ThrowOnError extends boolean = false>(optio
|
|
|
2220
2220
|
data?: Array<import("./types.gen").Offering>;
|
|
2221
2221
|
included?: import("./types.gen").OfferingIncludes;
|
|
2222
2222
|
links?: import("./types.gen").Links2;
|
|
2223
|
-
}, import("./types.gen").
|
|
2223
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2224
2224
|
/**
|
|
2225
2225
|
* Get offering
|
|
2226
2226
|
*/
|
|
2227
2227
|
export declare const getOffering: <ThrowOnError extends boolean = false>(options: Options<GetOfferingData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2228
2228
|
data?: import("./types.gen").Offering;
|
|
2229
2229
|
included?: import("./types.gen").OfferingIncludes;
|
|
2230
|
-
}, import("./types.gen").
|
|
2230
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2231
2231
|
/**
|
|
2232
2232
|
* List an offering's plans
|
|
2233
2233
|
*/
|
|
2234
2234
|
export declare const listOfferingPlans: <ThrowOnError extends boolean = false>(options: Options<ListOfferingPlansData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2235
2235
|
data?: Array<import("./types.gen").OfferingPlan>;
|
|
2236
2236
|
links?: import("./types.gen").Links2;
|
|
2237
|
-
}, import("./types.gen").
|
|
2237
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2238
2238
|
/**
|
|
2239
2239
|
* List an offering's features
|
|
2240
2240
|
*/
|
|
2241
2241
|
export declare const listOfferingFeatures: <ThrowOnError extends boolean = false>(options: Options<ListOfferingFeaturesData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2242
2242
|
data?: Array<import("./types.gen").OfferingFeature>;
|
|
2243
2243
|
links?: import("./types.gen").Links2;
|
|
2244
|
-
}, import("./types.gen").
|
|
2244
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2245
2245
|
/**
|
|
2246
2246
|
* List an offering's products
|
|
2247
2247
|
*/
|
|
2248
2248
|
export declare const listOfferingProducts: <ThrowOnError extends boolean = false>(options: Options<ListOfferingProductsData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2249
2249
|
data?: Array<import("./types.gen").OfferingProduct>;
|
|
2250
2250
|
links?: import("./types.gen").Links2;
|
|
2251
|
-
}, import("./types.gen").
|
|
2251
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2252
2252
|
/**
|
|
2253
2253
|
* Get feature
|
|
2254
2254
|
*/
|
|
2255
2255
|
export declare const getFeature: <ThrowOnError extends boolean = false>(options: Options<GetFeatureData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2256
2256
|
data?: import("./types.gen").Feature;
|
|
2257
|
-
}, import("./types.gen").
|
|
2257
|
+
}, import("./types.gen").SubscriptionsErrorResponse, ThrowOnError>;
|
|
2258
|
+
/**
|
|
2259
|
+
* Get Stock for Product
|
|
2260
|
+
* Gets the stock for the product matching the specified unique identifier.
|
|
2261
|
+
*/
|
|
2262
|
+
export declare const getStock: <ThrowOnError extends boolean = false>(options: Options<GetStockData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2263
|
+
data: import("./types.gen").StockResponse;
|
|
2264
|
+
}, import("./types.gen").InventoriesErrorResponse, ThrowOnError>;
|
|
2265
|
+
/**
|
|
2266
|
+
* List Locations
|
|
2267
|
+
* Lists all Inventory Locations
|
|
2268
|
+
*/
|
|
2269
|
+
export declare const listLocations: <ThrowOnError extends boolean = false>(options?: Options<ListLocationsData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
2270
|
+
data?: Array<import("./types.gen").Location>;
|
|
2271
|
+
links?: import("./types.gen").Links2;
|
|
2272
|
+
}, import("./types.gen").InventoriesErrorResponse, ThrowOnError>;
|
package/dist/client/sdk.gen.js
CHANGED
|
@@ -2940,3 +2940,29 @@ export var getFeature = function (options) {
|
|
|
2940
2940
|
},
|
|
2941
2941
|
], url: "/v2/subscriptions/features/{feature_uuid}" }));
|
|
2942
2942
|
};
|
|
2943
|
+
/**
|
|
2944
|
+
* Get Stock for Product
|
|
2945
|
+
* Gets the stock for the product matching the specified unique identifier.
|
|
2946
|
+
*/
|
|
2947
|
+
export var getStock = function (options) {
|
|
2948
|
+
var _a;
|
|
2949
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get(__assign(__assign({}, options), { security: [
|
|
2950
|
+
{
|
|
2951
|
+
scheme: "bearer",
|
|
2952
|
+
type: "http",
|
|
2953
|
+
},
|
|
2954
|
+
], url: "/v2/inventories/{product_uuid}" }));
|
|
2955
|
+
};
|
|
2956
|
+
/**
|
|
2957
|
+
* List Locations
|
|
2958
|
+
* Lists all Inventory Locations
|
|
2959
|
+
*/
|
|
2960
|
+
export var listLocations = function (options) {
|
|
2961
|
+
var _a;
|
|
2962
|
+
return ((_a = options === null || options === void 0 ? void 0 : options.client) !== null && _a !== void 0 ? _a : client).get(__assign(__assign({}, options), { security: [
|
|
2963
|
+
{
|
|
2964
|
+
scheme: "bearer",
|
|
2965
|
+
type: "http",
|
|
2966
|
+
},
|
|
2967
|
+
], url: "/v2/inventories/locations" }));
|
|
2968
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { GetByContextReleaseResponse, GetByContextAllHierarchiesResponse, GetByContextHierarchyResponse, GetByContextHierarchyNodesResponse, GetByContextHierarchyChildNodesResponse, GetByContextAllNodesResponse, GetByContextNodeResponse, GetByContextChildNodesResponse, GetByContextAllProductsResponse, GetByContextProductResponse, GetByContextComponentProductIdsResponse, GetByContextChildProductsResponse, GetByContextProductsForHierarchyResponse, GetByContextProductsForNodeResponse, ConfigureByContextProductResponse, GetCatalogsResponse, CreateCatalogResponse, GetCatalogByIdResponse, UpdateCatalogResponse, GetReleasesResponse, PublishReleaseResponse, GetReleaseByIdResponse, GetRulesResponse, CreateRuleResponse, GetRuleByIdResponse, UpdateRuleResponse, GetAllHierarchiesResponse, GetHierarchyResponse, GetHierarchyNodesResponse, GetHierarchyChildNodesResponse, GetAllNodesResponse, GetNodeResponse, GetChildNodesResponse, GetAllProductsResponse, GetProductResponse, GetComponentProductIdsResponse, GetChildProductsResponse, GetProductsForHierarchyResponse, GetProductsForNodeResponse, GetSubscriptionProductResponse, ListOfferingsResponse, GetOfferingResponse, ListOfferingProductsResponse } from "./types.gen";
|
|
1
|
+
import type { GetByContextReleaseResponse, GetByContextAllHierarchiesResponse, GetByContextHierarchyResponse, GetByContextHierarchyNodesResponse, GetByContextHierarchyChildNodesResponse, GetByContextAllNodesResponse, GetByContextNodeResponse, GetByContextChildNodesResponse, GetByContextAllProductsResponse, GetByContextProductResponse, GetByContextComponentProductIdsResponse, GetByContextChildProductsResponse, GetByContextProductsForHierarchyResponse, GetByContextProductsForNodeResponse, ConfigureByContextProductResponse, GetCatalogsResponse, CreateCatalogResponse, GetCatalogByIdResponse, UpdateCatalogResponse, GetReleasesResponse, PublishReleaseResponse, GetReleaseByIdResponse, GetRulesResponse, CreateRuleResponse, GetRuleByIdResponse, UpdateRuleResponse, GetAllHierarchiesResponse, GetHierarchyResponse, GetHierarchyNodesResponse, GetHierarchyChildNodesResponse, GetAllNodesResponse, GetNodeResponse, GetChildNodesResponse, GetAllProductsResponse, GetProductResponse, GetComponentProductIdsResponse, GetChildProductsResponse, GetProductsForHierarchyResponse, GetProductsForNodeResponse, GetSubscriptionProductResponse, ListOfferingsResponse, GetOfferingResponse, ListOfferingProductsResponse, GetStockResponse } from "./types.gen";
|
|
2
2
|
export declare const getByContextReleaseResponseTransformer: (data: any) => Promise<GetByContextReleaseResponse>;
|
|
3
3
|
export declare const getByContextAllHierarchiesResponseTransformer: (data: any) => Promise<GetByContextAllHierarchiesResponse>;
|
|
4
4
|
export declare const getByContextHierarchyResponseTransformer: (data: any) => Promise<GetByContextHierarchyResponse>;
|
|
@@ -42,3 +42,4 @@ export declare const getSubscriptionProductResponseTransformer: (data: any) => P
|
|
|
42
42
|
export declare const listOfferingsResponseTransformer: (data: any) => Promise<ListOfferingsResponse>;
|
|
43
43
|
export declare const getOfferingResponseTransformer: (data: any) => Promise<GetOfferingResponse>;
|
|
44
44
|
export declare const listOfferingProductsResponseTransformer: (data: any) => Promise<ListOfferingProductsResponse>;
|
|
45
|
+
export declare const getStockResponseTransformer: (data: any) => Promise<GetStockResponse>;
|
|
@@ -598,3 +598,19 @@ export var listOfferingProductsResponseTransformer = function (data) { return __
|
|
|
598
598
|
return [2 /*return*/, data];
|
|
599
599
|
});
|
|
600
600
|
}); };
|
|
601
|
+
var stockResponseAttributesSchemaResponseTransformer = function (data) {
|
|
602
|
+
data.available = BigInt(data.available.toString());
|
|
603
|
+
data.allocated = BigInt(data.allocated.toString());
|
|
604
|
+
data.total = BigInt(data.total.toString());
|
|
605
|
+
return data;
|
|
606
|
+
};
|
|
607
|
+
var stockResponseSchemaResponseTransformer = function (data) {
|
|
608
|
+
data.attributes = stockResponseAttributesSchemaResponseTransformer(data.attributes);
|
|
609
|
+
return data;
|
|
610
|
+
};
|
|
611
|
+
export var getStockResponseTransformer = function (data) { return __awaiter(void 0, void 0, void 0, function () {
|
|
612
|
+
return __generator(this, function (_a) {
|
|
613
|
+
data.data = stockResponseSchemaResponseTransformer(data.data);
|
|
614
|
+
return [2 /*return*/, data];
|
|
615
|
+
});
|
|
616
|
+
}); };
|