@shipengine/alchemy 5.0.29 → 5.0.30
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/index.js +1 -33
- package/index.mjs +2 -33
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -13784,19 +13784,6 @@ class CarriersAPI {
|
|
|
13784
13784
|
`/v1/carriers/${carrierId}/auto_funding`
|
|
13785
13785
|
);
|
|
13786
13786
|
};
|
|
13787
|
-
/**
|
|
13788
|
-
* The `getWalletHistory` method retrieves the wallet transaction history for
|
|
13789
|
-
* a ShipEngine wallet account.
|
|
13790
|
-
*/
|
|
13791
|
-
this.getWalletHistory = (startDate, endDate, page) => {
|
|
13792
|
-
return this.client.get(`/v1/carriers/wallet_history`, {
|
|
13793
|
-
params: {
|
|
13794
|
-
endDate: endDate.toISOString(),
|
|
13795
|
-
page,
|
|
13796
|
-
startDate: startDate.toISOString()
|
|
13797
|
-
}
|
|
13798
|
-
});
|
|
13799
|
-
};
|
|
13800
13787
|
/**
|
|
13801
13788
|
* The `getServices` method retrieves a list of shipping services that a given carrier offers.
|
|
13802
13789
|
*/
|
|
@@ -17335,24 +17322,6 @@ const useGetServicesByCarrier = (carrierId) => {
|
|
|
17335
17322
|
});
|
|
17336
17323
|
};
|
|
17337
17324
|
|
|
17338
|
-
const useGetWalletHistory = ({
|
|
17339
|
-
enabled,
|
|
17340
|
-
page,
|
|
17341
|
-
range
|
|
17342
|
-
}) => {
|
|
17343
|
-
const { client } = useShipEngine();
|
|
17344
|
-
const [startDate, endDate] = range;
|
|
17345
|
-
return reactQuery.useQuery({
|
|
17346
|
-
enabled,
|
|
17347
|
-
keepPreviousData: true,
|
|
17348
|
-
// See https://react-query-v3.tanstack.com/guides/paginated-queries#better-paginated-queries-with-keeppreviousdata
|
|
17349
|
-
onError,
|
|
17350
|
-
queryFn: () => client.carriers.getWalletHistory(startDate, endDate, page),
|
|
17351
|
-
queryKey: ["useGetWalletHistory", startDate, endDate, page],
|
|
17352
|
-
select: (result) => result.data
|
|
17353
|
-
});
|
|
17354
|
-
};
|
|
17355
|
-
|
|
17356
17325
|
const useListCarriers = () => {
|
|
17357
17326
|
const { client } = useShipEngine();
|
|
17358
17327
|
return reactQuery.useQuery({
|
|
@@ -17595,8 +17564,8 @@ const useGetFundingSourceMetadata = () => {
|
|
|
17595
17564
|
const useGetFundingSourceTransactions = (fundingSourceId, params) => {
|
|
17596
17565
|
const { client } = useShipEngine();
|
|
17597
17566
|
return reactQuery.useQuery({
|
|
17567
|
+
enabled: !!fundingSourceId,
|
|
17598
17568
|
keepPreviousData: true,
|
|
17599
|
-
onError,
|
|
17600
17569
|
queryFn: () => client.fundingSources.transactions(fundingSourceId, params),
|
|
17601
17570
|
queryKey: ["useGetFundingSourceTransactions", fundingSourceId, params],
|
|
17602
17571
|
select: (result) => result.data
|
|
@@ -19869,7 +19838,6 @@ exports.useGetShipmentRates = useGetShipmentRates;
|
|
|
19869
19838
|
exports.useGetShippingRuleById = useGetShippingRuleById;
|
|
19870
19839
|
exports.useGetShippingRuleConditionsOptions = useGetShippingRuleConditionsOptions;
|
|
19871
19840
|
exports.useGetThemeById = useGetThemeById;
|
|
19872
|
-
exports.useGetWalletHistory = useGetWalletHistory;
|
|
19873
19841
|
exports.useGetZonesByCarrier = useGetZonesByCarrier;
|
|
19874
19842
|
exports.useI18n = useI18n;
|
|
19875
19843
|
exports.useListCarriers = useListCarriers;
|
package/index.mjs
CHANGED
|
@@ -13762,19 +13762,6 @@ class CarriersAPI {
|
|
|
13762
13762
|
`/v1/carriers/${carrierId}/auto_funding`
|
|
13763
13763
|
);
|
|
13764
13764
|
};
|
|
13765
|
-
/**
|
|
13766
|
-
* The `getWalletHistory` method retrieves the wallet transaction history for
|
|
13767
|
-
* a ShipEngine wallet account.
|
|
13768
|
-
*/
|
|
13769
|
-
this.getWalletHistory = (startDate, endDate, page) => {
|
|
13770
|
-
return this.client.get(`/v1/carriers/wallet_history`, {
|
|
13771
|
-
params: {
|
|
13772
|
-
endDate: endDate.toISOString(),
|
|
13773
|
-
page,
|
|
13774
|
-
startDate: startDate.toISOString()
|
|
13775
|
-
}
|
|
13776
|
-
});
|
|
13777
|
-
};
|
|
13778
13765
|
/**
|
|
13779
13766
|
* The `getServices` method retrieves a list of shipping services that a given carrier offers.
|
|
13780
13767
|
*/
|
|
@@ -17313,24 +17300,6 @@ const useGetServicesByCarrier = (carrierId) => {
|
|
|
17313
17300
|
});
|
|
17314
17301
|
};
|
|
17315
17302
|
|
|
17316
|
-
const useGetWalletHistory = ({
|
|
17317
|
-
enabled,
|
|
17318
|
-
page,
|
|
17319
|
-
range
|
|
17320
|
-
}) => {
|
|
17321
|
-
const { client } = useShipEngine();
|
|
17322
|
-
const [startDate, endDate] = range;
|
|
17323
|
-
return useQuery({
|
|
17324
|
-
enabled,
|
|
17325
|
-
keepPreviousData: true,
|
|
17326
|
-
// See https://react-query-v3.tanstack.com/guides/paginated-queries#better-paginated-queries-with-keeppreviousdata
|
|
17327
|
-
onError,
|
|
17328
|
-
queryFn: () => client.carriers.getWalletHistory(startDate, endDate, page),
|
|
17329
|
-
queryKey: ["useGetWalletHistory", startDate, endDate, page],
|
|
17330
|
-
select: (result) => result.data
|
|
17331
|
-
});
|
|
17332
|
-
};
|
|
17333
|
-
|
|
17334
17303
|
const useListCarriers = () => {
|
|
17335
17304
|
const { client } = useShipEngine();
|
|
17336
17305
|
return useQuery({
|
|
@@ -17573,8 +17542,8 @@ const useGetFundingSourceMetadata = () => {
|
|
|
17573
17542
|
const useGetFundingSourceTransactions = (fundingSourceId, params) => {
|
|
17574
17543
|
const { client } = useShipEngine();
|
|
17575
17544
|
return useQuery({
|
|
17545
|
+
enabled: !!fundingSourceId,
|
|
17576
17546
|
keepPreviousData: true,
|
|
17577
|
-
onError,
|
|
17578
17547
|
queryFn: () => client.fundingSources.transactions(fundingSourceId, params),
|
|
17579
17548
|
queryKey: ["useGetFundingSourceTransactions", fundingSourceId, params],
|
|
17580
17549
|
select: (result) => result.data
|
|
@@ -19760,4 +19729,4 @@ const alchemy = {
|
|
|
19760
19729
|
createElement
|
|
19761
19730
|
};
|
|
19762
19731
|
|
|
19763
|
-
export { AccountSettingsAPI, AddressesAPI, AlchemyContext, AlchemyProvider, AlchemyTestProvider, CarriersAPI, CodedError, ConfirmationType, CreditCardVendor, Currency, CustomPackagesAPI, CustomsContentsType, CustomsNonDeliveryType, Element, ErrorBoundary, FundingSourcesAPI, InsuranceAPI, InsuranceProviderType, LabelsAPI, MetadataCapability, MetadataRequirement, MetadataSatisfyingFormTypes, OrderSourcesAPI, RateCardStatus, RateCardsAPI, RatesAPI, types as SE, SalesOrderShipmentsAPI, SalesOrdersAPI, ShipEngine, ShipEngineAPI, ShipEngineContext, ShipmentsAPI, ShippingRulesAPI, ThemesAPI, WarehousesAPI, alchemy, alchemy as default, delay, getEmotionCache, getEndUserIpAddress, isCodedError, isCodedErrors, logger, onError, retryUntil, useAddFunds, useAlchemy, useCalculateRates, useConnectCarrier, useCreateAccountImage, useCreateFundingSource, useCreateLabel, useCreateRateCard, useCreateSalesOrderShipment, useCreateShipment, useCreateShippingRule, useCreateWarehouse, useDeleteAccountImage, useDeleteRateCard, useDeleteShippingRule, useDeleteWarehouse, useDownloadRateCard, useEditShippingRule, useFundingSourcesAddFunds, useGetAccountBillingPlan, useGetAccountImages, useGetAccountSettings, useGetAutoFundingConfiguration, useGetCarrierById, useGetCountriesByCarrier, useGetCurrenciesByCarrier, useGetFundingSourceById, useGetFundingSourceMetadata, useGetFundingSourceTransactions, useGetInsuranceAccount, useGetLabel, useGetPackageRatingGroupByCarrier, useGetRateCardById, useGetSalesOrder, useGetSalesOrderShipment, useGetServicesByCarrier, useGetShipment, useGetShipmentRates, useGetShippingRuleById, useGetShippingRuleConditionsOptions, useGetThemeById,
|
|
19732
|
+
export { AccountSettingsAPI, AddressesAPI, AlchemyContext, AlchemyProvider, AlchemyTestProvider, CarriersAPI, CodedError, ConfirmationType, CreditCardVendor, Currency, CustomPackagesAPI, CustomsContentsType, CustomsNonDeliveryType, Element, ErrorBoundary, FundingSourcesAPI, InsuranceAPI, InsuranceProviderType, LabelsAPI, MetadataCapability, MetadataRequirement, MetadataSatisfyingFormTypes, OrderSourcesAPI, RateCardStatus, RateCardsAPI, RatesAPI, types as SE, SalesOrderShipmentsAPI, SalesOrdersAPI, ShipEngine, ShipEngineAPI, ShipEngineContext, ShipmentsAPI, ShippingRulesAPI, ThemesAPI, WarehousesAPI, alchemy, alchemy as default, delay, getEmotionCache, getEndUserIpAddress, isCodedError, isCodedErrors, logger, onError, retryUntil, useAddFunds, useAlchemy, useCalculateRates, useConnectCarrier, useCreateAccountImage, useCreateFundingSource, useCreateLabel, useCreateRateCard, useCreateSalesOrderShipment, useCreateShipment, useCreateShippingRule, useCreateWarehouse, useDeleteAccountImage, useDeleteRateCard, useDeleteShippingRule, useDeleteWarehouse, useDownloadRateCard, useEditShippingRule, useFundingSourcesAddFunds, useGetAccountBillingPlan, useGetAccountImages, useGetAccountSettings, useGetAutoFundingConfiguration, useGetCarrierById, useGetCountriesByCarrier, useGetCurrenciesByCarrier, useGetFundingSourceById, useGetFundingSourceMetadata, useGetFundingSourceTransactions, useGetInsuranceAccount, useGetLabel, useGetPackageRatingGroupByCarrier, useGetRateCardById, useGetSalesOrder, useGetSalesOrderShipment, useGetServicesByCarrier, useGetShipment, useGetShipmentRates, useGetShippingRuleById, useGetShippingRuleConditionsOptions, useGetThemeById, useGetZonesByCarrier, useI18n, useListCarriers, useListCustomPackageTypes, useListFundingSources, useListLabels, useListOrderSources, useListRateCards, useListSalesOrderShipments, useListSalesOrders, useListShipments, useListShippingRules, useListWarehouses, useLoadIcons, useNotifySalesOrderShipped, useParseAddress, usePublishRateCard, useRefreshOrderSource, useRefreshOrderSourceAsync, useRegisterCarrier, useShipEngine, useUpdateAccountBillingPlan, useUpdateAccountImage, useUpdateAccountSettings, useUpdateAutoFunding, useUpdateFundingSource, useUpdateRateCard, useUpdateSalesOrderShipment, useUpdateWarehouse, useUploadRateCard, useValidateAddresses, useVoidLabel };
|