@shipengine/alchemy 5.1.5 → 5.1.7

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.
Files changed (3) hide show
  1. package/index.js +210 -140
  2. package/index.mjs +210 -142
  3. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { createContext, forwardRef, useContext, createElement as createElement$1, Fragment, useState, useCallback, useMemo, useRef } from 'react';
2
+ import { createContext, forwardRef, useContext, createElement as createElement$1, Fragment, useState, useEffect, useCallback, useMemo, useRef } from 'react';
3
3
  import { jsx as jsx$1 } from 'react/jsx-runtime';
4
4
  import { GigerProvider, GigerTestProvider, DefaultPortalRefProvider } from '@shipengine/giger';
5
5
  import { QueryClient, QueryClientProvider, useMutation, useQuery, useQueryClient } from '@tanstack/react-query';
@@ -10764,17 +10764,17 @@ var AccountBillingPlanChangeType = /* @__PURE__ */ ((AccountBillingPlanChangeTyp
10764
10764
  return AccountBillingPlanChangeType2;
10765
10765
  })(AccountBillingPlanChangeType || {});
10766
10766
 
10767
- var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
10768
- var __hasOwnProp$i = Object.prototype.hasOwnProperty;
10769
- var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
10770
- var __objRest$d = (source, exclude) => {
10767
+ var __getOwnPropSymbols$j = Object.getOwnPropertySymbols;
10768
+ var __hasOwnProp$j = Object.prototype.hasOwnProperty;
10769
+ var __propIsEnum$j = Object.prototype.propertyIsEnumerable;
10770
+ var __objRest$e = (source, exclude) => {
10771
10771
  var target = {};
10772
10772
  for (var prop in source)
10773
- if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0)
10773
+ if (__hasOwnProp$j.call(source, prop) && exclude.indexOf(prop) < 0)
10774
10774
  target[prop] = source[prop];
10775
- if (source != null && __getOwnPropSymbols$i)
10776
- for (var prop of __getOwnPropSymbols$i(source)) {
10777
- if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop))
10775
+ if (source != null && __getOwnPropSymbols$j)
10776
+ for (var prop of __getOwnPropSymbols$j(source)) {
10777
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$j.call(source, prop))
10778
10778
  target[prop] = source[prop];
10779
10779
  }
10780
10780
  return target;
@@ -10788,7 +10788,7 @@ class CodedError {
10788
10788
  this.message = message;
10789
10789
  }
10790
10790
  static fromObject(_a) {
10791
- var _b = _a, { message } = _b, options = __objRest$d(_b, ["message"]);
10791
+ var _b = _a, { message } = _b, options = __objRest$e(_b, ["message"]);
10792
10792
  return new CodedError(message, options);
10793
10793
  }
10794
10794
  }
@@ -10896,17 +10896,17 @@ const types = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
10896
10896
  RateCardStatus
10897
10897
  }, Symbol.toStringTag, { value: 'Module' }));
10898
10898
 
10899
- var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
10900
- var __hasOwnProp$h = Object.prototype.hasOwnProperty;
10901
- var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
10902
- var __objRest$c = (source, exclude) => {
10899
+ var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
10900
+ var __hasOwnProp$i = Object.prototype.hasOwnProperty;
10901
+ var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
10902
+ var __objRest$d = (source, exclude) => {
10903
10903
  var target = {};
10904
10904
  for (var prop in source)
10905
- if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)
10905
+ if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0)
10906
10906
  target[prop] = source[prop];
10907
- if (source != null && __getOwnPropSymbols$h)
10908
- for (var prop of __getOwnPropSymbols$h(source)) {
10909
- if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))
10907
+ if (source != null && __getOwnPropSymbols$i)
10908
+ for (var prop of __getOwnPropSymbols$i(source)) {
10909
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop))
10910
10910
  target[prop] = source[prop];
10911
10911
  }
10912
10912
  return target;
@@ -10938,7 +10938,7 @@ class AccountSettingsAPI {
10938
10938
  * The `updateImage` method updates specific image data for a given image id.
10939
10939
  */
10940
10940
  this.updateImage = (_a) => {
10941
- var _b = _a, { labelImageId } = _b, data = __objRest$c(_b, ["labelImageId"]);
10941
+ var _b = _a, { labelImageId } = _b, data = __objRest$d(_b, ["labelImageId"]);
10942
10942
  return this.client.put(`/v1/account/settings/images/${labelImageId}`, data);
10943
10943
  };
10944
10944
  /**
@@ -10998,6 +10998,21 @@ const parseError = (err) => {
10998
10998
  return [new CodedError(err.message)];
10999
10999
  }
11000
11000
  };
11001
+ const nonTokenRelatedErrors = [
11002
+ "The JWT `scope` claim is invalid.",
11003
+ "Missing required scopes for this request.",
11004
+ "Your Stamps.com username or password are invalid",
11005
+ "Authorization has been denied for this request."
11006
+ ];
11007
+ const isInvalidTokenError = (err) => {
11008
+ var _a;
11009
+ const response = err.response;
11010
+ const responseData = (_a = err.response) == null ? void 0 : _a.data;
11011
+ if ((response == null ? void 0 : response.status) === 401 && responseData.errorSource === "shipengine" && responseData.errorType === "security" && !nonTokenRelatedErrors.includes(responseData.message)) {
11012
+ return true;
11013
+ }
11014
+ return false;
11015
+ };
11001
11016
 
11002
11017
  var axiosExports$1 = {};
11003
11018
  var axios$3 = {
@@ -13633,7 +13648,7 @@ var ipaddr = {
13633
13648
  }).call(commonjsGlobal);
13634
13649
  } (ipaddr));
13635
13650
 
13636
- var __async$D = (__this, __arguments, generator) => {
13651
+ var __async$E = (__this, __arguments, generator) => {
13637
13652
  return new Promise((resolve, reject) => {
13638
13653
  var fulfilled = (value) => {
13639
13654
  try {
@@ -13653,7 +13668,7 @@ var __async$D = (__this, __arguments, generator) => {
13653
13668
  step((generator = generator.apply(__this, __arguments)).next());
13654
13669
  });
13655
13670
  };
13656
- const getEndUserIpAddress = () => __async$D(void 0, null, function* () {
13671
+ const getEndUserIpAddress = () => __async$E(void 0, null, function* () {
13657
13672
  try {
13658
13673
  const response = yield axios.get("https://api.ipify.org/?format=json");
13659
13674
  if (response.data.ip && ipaddrExports.isValid(response.data.ip)) {
@@ -13668,35 +13683,35 @@ const getEndUserIpAddress = () => __async$D(void 0, null, function* () {
13668
13683
  var __defProp$6 = Object.defineProperty;
13669
13684
  var __defProps$3 = Object.defineProperties;
13670
13685
  var __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors;
13671
- var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
13672
- var __hasOwnProp$g = Object.prototype.hasOwnProperty;
13673
- var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
13686
+ var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
13687
+ var __hasOwnProp$h = Object.prototype.hasOwnProperty;
13688
+ var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
13674
13689
  var __defNormalProp$6 = (obj, key, value) => key in obj ? __defProp$6(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
13675
13690
  var __spreadValues$6 = (a, b) => {
13676
13691
  for (var prop in b || (b = {}))
13677
- if (__hasOwnProp$g.call(b, prop))
13692
+ if (__hasOwnProp$h.call(b, prop))
13678
13693
  __defNormalProp$6(a, prop, b[prop]);
13679
- if (__getOwnPropSymbols$g)
13680
- for (var prop of __getOwnPropSymbols$g(b)) {
13681
- if (__propIsEnum$g.call(b, prop))
13694
+ if (__getOwnPropSymbols$h)
13695
+ for (var prop of __getOwnPropSymbols$h(b)) {
13696
+ if (__propIsEnum$h.call(b, prop))
13682
13697
  __defNormalProp$6(a, prop, b[prop]);
13683
13698
  }
13684
13699
  return a;
13685
13700
  };
13686
13701
  var __spreadProps$3 = (a, b) => __defProps$3(a, __getOwnPropDescs$3(b));
13687
- var __objRest$b = (source, exclude) => {
13702
+ var __objRest$c = (source, exclude) => {
13688
13703
  var target = {};
13689
13704
  for (var prop in source)
13690
- if (__hasOwnProp$g.call(source, prop) && exclude.indexOf(prop) < 0)
13705
+ if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)
13691
13706
  target[prop] = source[prop];
13692
- if (source != null && __getOwnPropSymbols$g)
13693
- for (var prop of __getOwnPropSymbols$g(source)) {
13694
- if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source, prop))
13707
+ if (source != null && __getOwnPropSymbols$h)
13708
+ for (var prop of __getOwnPropSymbols$h(source)) {
13709
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))
13695
13710
  target[prop] = source[prop];
13696
13711
  }
13697
13712
  return target;
13698
13713
  };
13699
- var __async$C = (__this, __arguments, generator) => {
13714
+ var __async$D = (__this, __arguments, generator) => {
13700
13715
  return new Promise((resolve, reject) => {
13701
13716
  var fulfilled = (value) => {
13702
13717
  try {
@@ -13734,8 +13749,8 @@ class CarriersAPI {
13734
13749
  /**
13735
13750
  * The `connect` method connects a carrier account to a user's ShipEngine account.
13736
13751
  */
13737
- this.connect = (_a) => __async$C(this, null, function* () {
13738
- var _b = _a, { carrierCode } = _b, connection = __objRest$b(_b, ["carrierCode"]);
13752
+ this.connect = (_a) => __async$D(this, null, function* () {
13753
+ var _b = _a, { carrierCode } = _b, connection = __objRest$c(_b, ["carrierCode"]);
13739
13754
  const endUserIpAddress = yield getEndUserIpAddress();
13740
13755
  if (!endUserIpAddress)
13741
13756
  return Promise.reject([new CodedError("Unable to get IP address")]);
@@ -16051,22 +16066,22 @@ class CustomPackagesAPI {
16051
16066
  }
16052
16067
 
16053
16068
  var __defProp$5 = Object.defineProperty;
16054
- var __getOwnPropSymbols$f = Object.getOwnPropertySymbols;
16055
- var __hasOwnProp$f = Object.prototype.hasOwnProperty;
16056
- var __propIsEnum$f = Object.prototype.propertyIsEnumerable;
16069
+ var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
16070
+ var __hasOwnProp$g = Object.prototype.hasOwnProperty;
16071
+ var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
16057
16072
  var __defNormalProp$5 = (obj, key, value) => key in obj ? __defProp$5(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16058
16073
  var __spreadValues$5 = (a, b) => {
16059
16074
  for (var prop in b || (b = {}))
16060
- if (__hasOwnProp$f.call(b, prop))
16075
+ if (__hasOwnProp$g.call(b, prop))
16061
16076
  __defNormalProp$5(a, prop, b[prop]);
16062
- if (__getOwnPropSymbols$f)
16063
- for (var prop of __getOwnPropSymbols$f(b)) {
16064
- if (__propIsEnum$f.call(b, prop))
16077
+ if (__getOwnPropSymbols$g)
16078
+ for (var prop of __getOwnPropSymbols$g(b)) {
16079
+ if (__propIsEnum$g.call(b, prop))
16065
16080
  __defNormalProp$5(a, prop, b[prop]);
16066
16081
  }
16067
16082
  return a;
16068
16083
  };
16069
- var __async$B = (__this, __arguments, generator) => {
16084
+ var __async$C = (__this, __arguments, generator) => {
16070
16085
  return new Promise((resolve, reject) => {
16071
16086
  var fulfilled = (value) => {
16072
16087
  try {
@@ -16105,7 +16120,7 @@ class FundingSourcesAPI {
16105
16120
  * The `create` method creates a new funding source for a given user. This requires
16106
16121
  * payment information to be collected from the user.
16107
16122
  */
16108
- this.create = (createFundingSource) => __async$B(this, null, function* () {
16123
+ this.create = (createFundingSource) => __async$C(this, null, function* () {
16109
16124
  const endUserIpAddress = yield getEndUserIpAddress();
16110
16125
  if (!endUserIpAddress)
16111
16126
  return Promise.reject([new CodedError("Unable to get IP address")]);
@@ -16118,7 +16133,7 @@ class FundingSourcesAPI {
16118
16133
  * user to update the billing address or payment information associated with the
16119
16134
  * funding source.
16120
16135
  */
16121
- this.update = (billingInfo, creditCardInfo, fundingSourceId) => __async$B(this, null, function* () {
16136
+ this.update = (billingInfo, creditCardInfo, fundingSourceId) => __async$C(this, null, function* () {
16122
16137
  const endUserIpAddress = yield getEndUserIpAddress();
16123
16138
  if (!endUserIpAddress)
16124
16139
  return Promise.reject([new CodedError("Unable to get IP address")]);
@@ -16135,7 +16150,7 @@ class FundingSourcesAPI {
16135
16150
  * The `registerCarrier` method registers a carrier account and associates
16136
16151
  * it with a given funding source.
16137
16152
  */
16138
- this.registerCarrier = (carrier) => __async$B(this, null, function* () {
16153
+ this.registerCarrier = (carrier) => __async$C(this, null, function* () {
16139
16154
  const endUserIpAddress = yield getEndUserIpAddress();
16140
16155
  if (!endUserIpAddress)
16141
16156
  return Promise.reject([new CodedError("Unable to get IP address")]);
@@ -16146,7 +16161,7 @@ class FundingSourcesAPI {
16146
16161
  /**
16147
16162
  * The `addFunds` method allows you to add funds to a funding source.
16148
16163
  */
16149
- this.addFunds = (amount, fundingSourceId) => __async$B(this, null, function* () {
16164
+ this.addFunds = (amount, fundingSourceId) => __async$C(this, null, function* () {
16150
16165
  return yield this.client.put(
16151
16166
  `/v1/funding_sources/${fundingSourceId}/add_funds`,
16152
16167
  amount
@@ -16156,7 +16171,7 @@ class FundingSourcesAPI {
16156
16171
  * The `metadata` method returns seller-specific requirements for creating funding sources
16157
16172
  * and attaching carriers
16158
16173
  */
16159
- this.metadata = () => __async$B(this, null, function* () {
16174
+ this.metadata = () => __async$C(this, null, function* () {
16160
16175
  return yield this.client.get("/v1/funding_sources/metadata");
16161
16176
  });
16162
16177
  /**
@@ -16185,6 +16200,15 @@ class InsuranceAPI {
16185
16200
  this.get = (insuranceProvider) => {
16186
16201
  return this.client.get(`/v1/insurance/${insuranceProvider}/balance`);
16187
16202
  };
16203
+ /**
16204
+ * The `addFunds` method add funds to the account balance of the given `insuranceProvider`.
16205
+ */
16206
+ this.addFunds = (insuranceProvider, params) => {
16207
+ return this.client.patch(
16208
+ `/v1/insurance/${insuranceProvider}/add_funds`,
16209
+ params
16210
+ );
16211
+ };
16188
16212
  this.client = client;
16189
16213
  }
16190
16214
  }
@@ -16405,7 +16429,7 @@ class SalesOrdersAPI {
16405
16429
  }
16406
16430
  }
16407
16431
 
16408
- var __async$A = (__this, __arguments, generator) => {
16432
+ var __async$B = (__this, __arguments, generator) => {
16409
16433
  return new Promise((resolve, reject) => {
16410
16434
  var fulfilled = (value) => {
16411
16435
  try {
@@ -16448,7 +16472,7 @@ class ShipmentsAPI {
16448
16472
  * The `create` method allows for creating shipments based on a list of shipment
16449
16473
  * items passed into this method.
16450
16474
  */
16451
- this.create = (...shipments) => __async$A(this, null, function* () {
16475
+ this.create = (...shipments) => __async$B(this, null, function* () {
16452
16476
  return this.client.post("/v1/shipments", {
16453
16477
  shipments
16454
16478
  });
@@ -16555,23 +16579,23 @@ class WarehousesAPI {
16555
16579
  var __defProp$4 = Object.defineProperty;
16556
16580
  var __defProps$2 = Object.defineProperties;
16557
16581
  var __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors;
16558
- var __getOwnPropSymbols$e = Object.getOwnPropertySymbols;
16559
- var __hasOwnProp$e = Object.prototype.hasOwnProperty;
16560
- var __propIsEnum$e = Object.prototype.propertyIsEnumerable;
16582
+ var __getOwnPropSymbols$f = Object.getOwnPropertySymbols;
16583
+ var __hasOwnProp$f = Object.prototype.hasOwnProperty;
16584
+ var __propIsEnum$f = Object.prototype.propertyIsEnumerable;
16561
16585
  var __defNormalProp$4 = (obj, key, value) => key in obj ? __defProp$4(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16562
16586
  var __spreadValues$4 = (a, b) => {
16563
16587
  for (var prop in b || (b = {}))
16564
- if (__hasOwnProp$e.call(b, prop))
16588
+ if (__hasOwnProp$f.call(b, prop))
16565
16589
  __defNormalProp$4(a, prop, b[prop]);
16566
- if (__getOwnPropSymbols$e)
16567
- for (var prop of __getOwnPropSymbols$e(b)) {
16568
- if (__propIsEnum$e.call(b, prop))
16590
+ if (__getOwnPropSymbols$f)
16591
+ for (var prop of __getOwnPropSymbols$f(b)) {
16592
+ if (__propIsEnum$f.call(b, prop))
16569
16593
  __defNormalProp$4(a, prop, b[prop]);
16570
16594
  }
16571
16595
  return a;
16572
16596
  };
16573
16597
  var __spreadProps$2 = (a, b) => __defProps$2(a, __getOwnPropDescs$2(b));
16574
- var __async$z = (__this, __arguments, generator) => {
16598
+ var __async$A = (__this, __arguments, generator) => {
16575
16599
  return new Promise((resolve, reject) => {
16576
16600
  var fulfilled = (value) => {
16577
16601
  try {
@@ -16665,8 +16689,8 @@ class ShipEngineAPI {
16665
16689
  );
16666
16690
  return res;
16667
16691
  },
16668
- (err) => __async$z(this, null, function* () {
16669
- var _a, _b, _c, _d, _e, _f;
16692
+ (err) => __async$A(this, null, function* () {
16693
+ var _a, _b, _c, _d, _e;
16670
16694
  logger$1.error(
16671
16695
  { err, req: err.config, res: err.response },
16672
16696
  "%s %s: %s %s - %s",
@@ -16676,7 +16700,7 @@ class ShipEngineAPI {
16676
16700
  (_e = err.response) == null ? void 0 : _e.statusText,
16677
16701
  err.message
16678
16702
  );
16679
- if (((_f = err.response) == null ? void 0 : _f.status) === 401) {
16703
+ if (isInvalidTokenError(err)) {
16680
16704
  const token2 = yield getToken();
16681
16705
  const config = err.config;
16682
16706
  if (config) {
@@ -16867,28 +16891,24 @@ const ShipEngine = ({
16867
16891
  getToken,
16868
16892
  onApiError
16869
16893
  }) => {
16894
+ const [client, setClient] = useState();
16870
16895
  const [queryClient] = useState(() => new QueryClient());
16871
- const [client, setClient] = useState(() => {
16896
+ useEffect(() => {
16872
16897
  const token = getToken();
16873
- if (typeof token === "string")
16874
- return new ShipEngineAPI(token, {
16875
- baseURL,
16876
- getToken,
16877
- headers: headers != null ? headers : {},
16878
- onApiError
16898
+ const commonClientProps = {
16899
+ baseURL,
16900
+ getToken,
16901
+ headers: headers != null ? headers : {},
16902
+ onApiError
16903
+ };
16904
+ if (typeof token === "string") {
16905
+ setClient(new ShipEngineAPI(token, commonClientProps));
16906
+ } else {
16907
+ token.then((t) => {
16908
+ setClient(new ShipEngineAPI(t, commonClientProps));
16879
16909
  });
16880
- token.then(
16881
- (t) => setClient(
16882
- new ShipEngineAPI(t, {
16883
- baseURL,
16884
- getToken,
16885
- headers: headers != null ? headers : {},
16886
- onApiError
16887
- })
16888
- )
16889
- );
16890
- return void 0;
16891
- });
16910
+ }
16911
+ }, []);
16892
16912
  if (!client) {
16893
16913
  return /* @__PURE__ */ jsx$1(
16894
16914
  "div",
@@ -16923,17 +16943,17 @@ const onError = (_errors) => _default();
16923
16943
  var __defProp$3 = Object.defineProperty;
16924
16944
  var __defProps$1 = Object.defineProperties;
16925
16945
  var __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors;
16926
- var __getOwnPropSymbols$d = Object.getOwnPropertySymbols;
16927
- var __hasOwnProp$d = Object.prototype.hasOwnProperty;
16928
- var __propIsEnum$d = Object.prototype.propertyIsEnumerable;
16946
+ var __getOwnPropSymbols$e = Object.getOwnPropertySymbols;
16947
+ var __hasOwnProp$e = Object.prototype.hasOwnProperty;
16948
+ var __propIsEnum$e = Object.prototype.propertyIsEnumerable;
16929
16949
  var __defNormalProp$3 = (obj, key, value) => key in obj ? __defProp$3(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16930
16950
  var __spreadValues$3 = (a, b) => {
16931
16951
  for (var prop in b || (b = {}))
16932
- if (__hasOwnProp$d.call(b, prop))
16952
+ if (__hasOwnProp$e.call(b, prop))
16933
16953
  __defNormalProp$3(a, prop, b[prop]);
16934
- if (__getOwnPropSymbols$d)
16935
- for (var prop of __getOwnPropSymbols$d(b)) {
16936
- if (__propIsEnum$d.call(b, prop))
16954
+ if (__getOwnPropSymbols$e)
16955
+ for (var prop of __getOwnPropSymbols$e(b)) {
16956
+ if (__propIsEnum$e.call(b, prop))
16937
16957
  __defNormalProp$3(a, prop, b[prop]);
16938
16958
  }
16939
16959
  return a;
@@ -16972,7 +16992,7 @@ const retryUntil = (callbackFn, retries = 10, timeoutBetweenAttempts = 1e3) => P
16972
16992
  throw error;
16973
16993
  });
16974
16994
 
16975
- var __async$y = (__this, __arguments, generator) => {
16995
+ var __async$z = (__this, __arguments, generator) => {
16976
16996
  return new Promise((resolve, reject) => {
16977
16997
  var fulfilled = (value) => {
16978
16998
  try {
@@ -16995,7 +17015,7 @@ var __async$y = (__this, __arguments, generator) => {
16995
17015
  const useCreateAccountImage = () => {
16996
17016
  const { client } = useShipEngine();
16997
17017
  return useMutation({
16998
- mutationFn: (data) => __async$y(void 0, null, function* () {
17018
+ mutationFn: (data) => __async$z(void 0, null, function* () {
16999
17019
  const result = yield client.accountSettings.createImage(data);
17000
17020
  return result.data;
17001
17021
  }),
@@ -17004,7 +17024,7 @@ const useCreateAccountImage = () => {
17004
17024
  });
17005
17025
  };
17006
17026
 
17007
- var __async$x = (__this, __arguments, generator) => {
17027
+ var __async$y = (__this, __arguments, generator) => {
17008
17028
  return new Promise((resolve, reject) => {
17009
17029
  var fulfilled = (value) => {
17010
17030
  try {
@@ -17027,7 +17047,7 @@ var __async$x = (__this, __arguments, generator) => {
17027
17047
  const useDeleteAccountImage = () => {
17028
17048
  const { client } = useShipEngine();
17029
17049
  return useMutation({
17030
- mutationFn: (labelImageId) => __async$x(void 0, null, function* () {
17050
+ mutationFn: (labelImageId) => __async$y(void 0, null, function* () {
17031
17051
  const result = yield client.accountSettings.deleteImage(labelImageId);
17032
17052
  return result.data;
17033
17053
  }),
@@ -17056,7 +17076,7 @@ const useGetAccountSettings = () => {
17056
17076
  });
17057
17077
  };
17058
17078
 
17059
- var __async$w = (__this, __arguments, generator) => {
17079
+ var __async$x = (__this, __arguments, generator) => {
17060
17080
  return new Promise((resolve, reject) => {
17061
17081
  var fulfilled = (value) => {
17062
17082
  try {
@@ -17079,7 +17099,7 @@ var __async$w = (__this, __arguments, generator) => {
17079
17099
  const useUpdateAccountImage = () => {
17080
17100
  const { client } = useShipEngine();
17081
17101
  return useMutation({
17082
- mutationFn: (data) => __async$w(void 0, null, function* () {
17102
+ mutationFn: (data) => __async$x(void 0, null, function* () {
17083
17103
  const result = yield client.accountSettings.updateImage(data);
17084
17104
  return result.data;
17085
17105
  }),
@@ -17088,7 +17108,7 @@ const useUpdateAccountImage = () => {
17088
17108
  });
17089
17109
  };
17090
17110
 
17091
- var __async$v = (__this, __arguments, generator) => {
17111
+ var __async$w = (__this, __arguments, generator) => {
17092
17112
  return new Promise((resolve, reject) => {
17093
17113
  var fulfilled = (value) => {
17094
17114
  try {
@@ -17111,7 +17131,7 @@ var __async$v = (__this, __arguments, generator) => {
17111
17131
  const useUpdateAccountSettings = () => {
17112
17132
  const { client } = useShipEngine();
17113
17133
  return useMutation({
17114
- mutationFn: (settings) => __async$v(void 0, null, function* () {
17134
+ mutationFn: (settings) => __async$w(void 0, null, function* () {
17115
17135
  const result = yield client.accountSettings.update(settings);
17116
17136
  return result.data;
17117
17137
  }),
@@ -17120,7 +17140,7 @@ const useUpdateAccountSettings = () => {
17120
17140
  });
17121
17141
  };
17122
17142
 
17123
- var __async$u = (__this, __arguments, generator) => {
17143
+ var __async$v = (__this, __arguments, generator) => {
17124
17144
  return new Promise((resolve, reject) => {
17125
17145
  var fulfilled = (value) => {
17126
17146
  try {
@@ -17143,7 +17163,7 @@ var __async$u = (__this, __arguments, generator) => {
17143
17163
  const useParseAddress = () => {
17144
17164
  const { client } = useShipEngine();
17145
17165
  return useMutation({
17146
- mutationFn: (_0) => __async$u(void 0, [_0], function* ({ address, text }) {
17166
+ mutationFn: (_0) => __async$v(void 0, [_0], function* ({ address, text }) {
17147
17167
  const result = yield client.addresses.parse(text, address);
17148
17168
  return result.data;
17149
17169
  }),
@@ -17152,7 +17172,7 @@ const useParseAddress = () => {
17152
17172
  });
17153
17173
  };
17154
17174
 
17155
- var __async$t = (__this, __arguments, generator) => {
17175
+ var __async$u = (__this, __arguments, generator) => {
17156
17176
  return new Promise((resolve, reject) => {
17157
17177
  var fulfilled = (value) => {
17158
17178
  try {
@@ -17175,7 +17195,7 @@ var __async$t = (__this, __arguments, generator) => {
17175
17195
  const useValidateAddresses = () => {
17176
17196
  const { client } = useShipEngine();
17177
17197
  return useMutation({
17178
- mutationFn: (addresses) => __async$t(void 0, null, function* () {
17198
+ mutationFn: (addresses) => __async$u(void 0, null, function* () {
17179
17199
  const result = yield client.addresses.validate(addresses);
17180
17200
  return result.data;
17181
17201
  }),
@@ -17184,7 +17204,7 @@ const useValidateAddresses = () => {
17184
17204
  });
17185
17205
  };
17186
17206
 
17187
- var __async$s = (__this, __arguments, generator) => {
17207
+ var __async$t = (__this, __arguments, generator) => {
17188
17208
  return new Promise((resolve, reject) => {
17189
17209
  var fulfilled = (value) => {
17190
17210
  try {
@@ -17207,7 +17227,7 @@ var __async$s = (__this, __arguments, generator) => {
17207
17227
  const useAddFunds = () => {
17208
17228
  const { client } = useShipEngine();
17209
17229
  return useMutation({
17210
- mutationFn: (_0) => __async$s(void 0, [_0], function* ({ carrierId, funds }) {
17230
+ mutationFn: (_0) => __async$t(void 0, [_0], function* ({ carrierId, funds }) {
17211
17231
  const result = yield client.carriers.addFunds(carrierId, funds);
17212
17232
  return result.data;
17213
17233
  }),
@@ -17216,7 +17236,7 @@ const useAddFunds = () => {
17216
17236
  });
17217
17237
  };
17218
17238
 
17219
- var __async$r = (__this, __arguments, generator) => {
17239
+ var __async$s = (__this, __arguments, generator) => {
17220
17240
  return new Promise((resolve, reject) => {
17221
17241
  var fulfilled = (value) => {
17222
17242
  try {
@@ -17239,7 +17259,7 @@ var __async$r = (__this, __arguments, generator) => {
17239
17259
  const useConnectCarrier = () => {
17240
17260
  const { client } = useShipEngine();
17241
17261
  return useMutation({
17242
- mutationFn: (params) => __async$r(void 0, null, function* () {
17262
+ mutationFn: (params) => __async$s(void 0, null, function* () {
17243
17263
  const result = yield client.carriers.connect(params);
17244
17264
  return result.data;
17245
17265
  }),
@@ -17358,22 +17378,22 @@ const useListCarriers = () => {
17358
17378
  });
17359
17379
  };
17360
17380
 
17361
- var __getOwnPropSymbols$c = Object.getOwnPropertySymbols;
17362
- var __hasOwnProp$c = Object.prototype.hasOwnProperty;
17363
- var __propIsEnum$c = Object.prototype.propertyIsEnumerable;
17364
- var __objRest$a = (source, exclude) => {
17381
+ var __getOwnPropSymbols$d = Object.getOwnPropertySymbols;
17382
+ var __hasOwnProp$d = Object.prototype.hasOwnProperty;
17383
+ var __propIsEnum$d = Object.prototype.propertyIsEnumerable;
17384
+ var __objRest$b = (source, exclude) => {
17365
17385
  var target = {};
17366
17386
  for (var prop in source)
17367
- if (__hasOwnProp$c.call(source, prop) && exclude.indexOf(prop) < 0)
17387
+ if (__hasOwnProp$d.call(source, prop) && exclude.indexOf(prop) < 0)
17368
17388
  target[prop] = source[prop];
17369
- if (source != null && __getOwnPropSymbols$c)
17370
- for (var prop of __getOwnPropSymbols$c(source)) {
17371
- if (exclude.indexOf(prop) < 0 && __propIsEnum$c.call(source, prop))
17389
+ if (source != null && __getOwnPropSymbols$d)
17390
+ for (var prop of __getOwnPropSymbols$d(source)) {
17391
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$d.call(source, prop))
17372
17392
  target[prop] = source[prop];
17373
17393
  }
17374
17394
  return target;
17375
17395
  };
17376
- var __async$q = (__this, __arguments, generator) => {
17396
+ var __async$r = (__this, __arguments, generator) => {
17377
17397
  return new Promise((resolve, reject) => {
17378
17398
  var fulfilled = (value) => {
17379
17399
  try {
@@ -17397,8 +17417,8 @@ const useUpdateAutoFunding = () => {
17397
17417
  const { client } = useShipEngine();
17398
17418
  const queryClient = useQueryClient();
17399
17419
  return useMutation({
17400
- mutationFn: (_a) => __async$q(void 0, null, function* () {
17401
- var _b = _a, { carrierId } = _b, options = __objRest$a(_b, ["carrierId"]);
17420
+ mutationFn: (_a) => __async$r(void 0, null, function* () {
17421
+ var _b = _a, { carrierId } = _b, options = __objRest$b(_b, ["carrierId"]);
17402
17422
  const result = yield client.carriers.updateAutoFunding(carrierId, options);
17403
17423
  return result.data;
17404
17424
  }),
@@ -17427,24 +17447,24 @@ const useGetZonesByCarrier = (carrierId) => {
17427
17447
  });
17428
17448
  };
17429
17449
 
17430
- var __getOwnPropSymbols$b = Object.getOwnPropertySymbols;
17431
- var __hasOwnProp$b = Object.prototype.hasOwnProperty;
17432
- var __propIsEnum$b = Object.prototype.propertyIsEnumerable;
17433
- var __objRest$9 = (source, exclude) => {
17450
+ var __getOwnPropSymbols$c = Object.getOwnPropertySymbols;
17451
+ var __hasOwnProp$c = Object.prototype.hasOwnProperty;
17452
+ var __propIsEnum$c = Object.prototype.propertyIsEnumerable;
17453
+ var __objRest$a = (source, exclude) => {
17434
17454
  var target = {};
17435
17455
  for (var prop in source)
17436
- if (__hasOwnProp$b.call(source, prop) && exclude.indexOf(prop) < 0)
17456
+ if (__hasOwnProp$c.call(source, prop) && exclude.indexOf(prop) < 0)
17437
17457
  target[prop] = source[prop];
17438
- if (source != null && __getOwnPropSymbols$b)
17439
- for (var prop of __getOwnPropSymbols$b(source)) {
17440
- if (exclude.indexOf(prop) < 0 && __propIsEnum$b.call(source, prop))
17458
+ if (source != null && __getOwnPropSymbols$c)
17459
+ for (var prop of __getOwnPropSymbols$c(source)) {
17460
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$c.call(source, prop))
17441
17461
  target[prop] = source[prop];
17442
17462
  }
17443
17463
  return target;
17444
17464
  };
17445
17465
  const useGetCarrierConnectionForm = (_params) => {
17446
17466
  const { client } = useShipEngine();
17447
- const _a = _params || {}, { carrierName, enabled = true } = _a, params = __objRest$9(_a, ["carrierName", "enabled"]);
17467
+ const _a = _params || {}, { carrierName, enabled = true } = _a, params = __objRest$a(_a, ["carrierName", "enabled"]);
17448
17468
  return useQuery({
17449
17469
  enabled,
17450
17470
  onError,
@@ -17454,24 +17474,24 @@ const useGetCarrierConnectionForm = (_params) => {
17454
17474
  });
17455
17475
  };
17456
17476
 
17457
- var __getOwnPropSymbols$a = Object.getOwnPropertySymbols;
17458
- var __hasOwnProp$a = Object.prototype.hasOwnProperty;
17459
- var __propIsEnum$a = Object.prototype.propertyIsEnumerable;
17460
- var __objRest$8 = (source, exclude) => {
17477
+ var __getOwnPropSymbols$b = Object.getOwnPropertySymbols;
17478
+ var __hasOwnProp$b = Object.prototype.hasOwnProperty;
17479
+ var __propIsEnum$b = Object.prototype.propertyIsEnumerable;
17480
+ var __objRest$9 = (source, exclude) => {
17461
17481
  var target = {};
17462
17482
  for (var prop in source)
17463
- if (__hasOwnProp$a.call(source, prop) && exclude.indexOf(prop) < 0)
17483
+ if (__hasOwnProp$b.call(source, prop) && exclude.indexOf(prop) < 0)
17464
17484
  target[prop] = source[prop];
17465
- if (source != null && __getOwnPropSymbols$a)
17466
- for (var prop of __getOwnPropSymbols$a(source)) {
17467
- if (exclude.indexOf(prop) < 0 && __propIsEnum$a.call(source, prop))
17485
+ if (source != null && __getOwnPropSymbols$b)
17486
+ for (var prop of __getOwnPropSymbols$b(source)) {
17487
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$b.call(source, prop))
17468
17488
  target[prop] = source[prop];
17469
17489
  }
17470
17490
  return target;
17471
17491
  };
17472
17492
  const useListCarrierConnections = (_params) => {
17473
17493
  const { client } = useShipEngine();
17474
- const _a = _params || {}, { enabled = true } = _a, params = __objRest$8(_a, ["enabled"]);
17494
+ const _a = _params || {}, { enabled = true } = _a, params = __objRest$9(_a, ["enabled"]);
17475
17495
  return useQuery({
17476
17496
  enabled,
17477
17497
  onError,
@@ -17491,7 +17511,7 @@ const useListCustomPackageTypes = () => {
17491
17511
  });
17492
17512
  };
17493
17513
 
17494
- var __async$p = (__this, __arguments, generator) => {
17514
+ var __async$q = (__this, __arguments, generator) => {
17495
17515
  return new Promise((resolve, reject) => {
17496
17516
  var fulfilled = (value) => {
17497
17517
  try {
@@ -17514,7 +17534,7 @@ var __async$p = (__this, __arguments, generator) => {
17514
17534
  const useCreateFundingSource = () => {
17515
17535
  const { client } = useShipEngine();
17516
17536
  return useMutation({
17517
- mutationFn: (fundingSource) => __async$p(void 0, null, function* () {
17537
+ mutationFn: (fundingSource) => __async$q(void 0, null, function* () {
17518
17538
  const result = yield client.fundingSources.create(fundingSource);
17519
17539
  return result.data;
17520
17540
  }),
@@ -17523,7 +17543,7 @@ const useCreateFundingSource = () => {
17523
17543
  });
17524
17544
  };
17525
17545
 
17526
- var __async$o = (__this, __arguments, generator) => {
17546
+ var __async$p = (__this, __arguments, generator) => {
17527
17547
  return new Promise((resolve, reject) => {
17528
17548
  var fulfilled = (value) => {
17529
17549
  try {
@@ -17546,7 +17566,7 @@ var __async$o = (__this, __arguments, generator) => {
17546
17566
  const useFundingSourcesAddFunds = () => {
17547
17567
  const { client } = useShipEngine();
17548
17568
  return useMutation({
17549
- mutationFn: (_0) => __async$o(void 0, [_0], function* ({ funds, fundingSourceId }) {
17569
+ mutationFn: (_0) => __async$p(void 0, [_0], function* ({ funds, fundingSourceId }) {
17550
17570
  const result = yield client.fundingSources.addFunds(funds, fundingSourceId);
17551
17571
  return result.data;
17552
17572
  }),
@@ -17575,7 +17595,7 @@ const useListFundingSources = () => {
17575
17595
  });
17576
17596
  };
17577
17597
 
17578
- var __async$n = (__this, __arguments, generator) => {
17598
+ var __async$o = (__this, __arguments, generator) => {
17579
17599
  return new Promise((resolve, reject) => {
17580
17600
  var fulfilled = (value) => {
17581
17601
  try {
@@ -17598,7 +17618,7 @@ var __async$n = (__this, __arguments, generator) => {
17598
17618
  const useRegisterCarrier = () => {
17599
17619
  const { client } = useShipEngine();
17600
17620
  return useMutation({
17601
- mutationFn: (carrier) => __async$n(void 0, null, function* () {
17621
+ mutationFn: (carrier) => __async$o(void 0, null, function* () {
17602
17622
  const result = yield client.fundingSources.registerCarrier(carrier);
17603
17623
  return result.data;
17604
17624
  }),
@@ -17607,7 +17627,7 @@ const useRegisterCarrier = () => {
17607
17627
  });
17608
17628
  };
17609
17629
 
17610
- var __async$m = (__this, __arguments, generator) => {
17630
+ var __async$n = (__this, __arguments, generator) => {
17611
17631
  return new Promise((resolve, reject) => {
17612
17632
  var fulfilled = (value) => {
17613
17633
  try {
@@ -17630,7 +17650,7 @@ var __async$m = (__this, __arguments, generator) => {
17630
17650
  const useUpdateFundingSource = () => {
17631
17651
  const { client } = useShipEngine();
17632
17652
  return useMutation({
17633
- mutationFn: (_0) => __async$m(void 0, [_0], function* ({
17653
+ mutationFn: (_0) => __async$n(void 0, [_0], function* ({
17634
17654
  billingInfo,
17635
17655
  creditCardInfo,
17636
17656
  fundingSourceId
@@ -17684,6 +17704,54 @@ const useGetInsuranceAccount = (insuranceProvider) => {
17684
17704
  });
17685
17705
  };
17686
17706
 
17707
+ var __getOwnPropSymbols$a = Object.getOwnPropertySymbols;
17708
+ var __hasOwnProp$a = Object.prototype.hasOwnProperty;
17709
+ var __propIsEnum$a = Object.prototype.propertyIsEnumerable;
17710
+ var __objRest$8 = (source, exclude) => {
17711
+ var target = {};
17712
+ for (var prop in source)
17713
+ if (__hasOwnProp$a.call(source, prop) && exclude.indexOf(prop) < 0)
17714
+ target[prop] = source[prop];
17715
+ if (source != null && __getOwnPropSymbols$a)
17716
+ for (var prop of __getOwnPropSymbols$a(source)) {
17717
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$a.call(source, prop))
17718
+ target[prop] = source[prop];
17719
+ }
17720
+ return target;
17721
+ };
17722
+ var __async$m = (__this, __arguments, generator) => {
17723
+ return new Promise((resolve, reject) => {
17724
+ var fulfilled = (value) => {
17725
+ try {
17726
+ step(generator.next(value));
17727
+ } catch (e) {
17728
+ reject(e);
17729
+ }
17730
+ };
17731
+ var rejected = (value) => {
17732
+ try {
17733
+ step(generator.throw(value));
17734
+ } catch (e) {
17735
+ reject(e);
17736
+ }
17737
+ };
17738
+ var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
17739
+ step((generator = generator.apply(__this, __arguments)).next());
17740
+ });
17741
+ };
17742
+ const useAddInsuranceFunds = () => {
17743
+ const { client } = useShipEngine();
17744
+ return useMutation({
17745
+ mutationFn: (_a) => __async$m(void 0, null, function* () {
17746
+ var _b = _a, { insuranceProvider } = _b, rest = __objRest$8(_b, ["insuranceProvider"]);
17747
+ const result = yield client.insurance.addFunds(insuranceProvider, rest);
17748
+ return result.data;
17749
+ }),
17750
+ mutationKey: ["useAddInsuranceFunds"],
17751
+ onError
17752
+ });
17753
+ };
17754
+
17687
17755
  var __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;
17688
17756
  var __hasOwnProp$9 = Object.prototype.hasOwnProperty;
17689
17757
  var __propIsEnum$9 = Object.prototype.propertyIsEnumerable;
@@ -19882,4 +19950,4 @@ const alchemy = {
19882
19950
  createElement
19883
19951
  };
19884
19952
 
19885
- export { AccountSettingsAPI, AddressesAPI, AlchemyContext, AlchemyProvider, AlchemyTestProvider, CarriersAPI, CodedError, ConfirmationType, ConnectionsAPI, 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, isDataCodedErrors, logger, onError, parseError, retryUntil, useAddFunds, useAlchemy, useCalculateRates, useConnectCarrier, useCreateAccountImage, useCreateFundingSource, useCreateLabel, useCreateRateCard, useCreateSalesOrderShipment, useCreateShipment, useCreateShippingRule, useCreateWarehouse, useDeactivateOrderSource, useDeleteAccountImage, useDeleteRateCard, useDeleteShippingRule, useDeleteWarehouse, useDownloadRateCard, useEditShippingRule, useFundingSourcesAddFunds, useGetAccountBillingPlan, useGetAccountImages, useGetAccountSettings, useGetAutoFundingConfiguration, useGetCarrierById, useGetCarrierConnectionForm, useGetCountriesByCarrier, useGetCurrenciesByCarrier, useGetFundingSourceById, useGetFundingSourceMetadata, useGetFundingSourceTransactions, useGetInsuranceAccount, useGetLabel, useGetPackageRatingGroupByCarrier, useGetRateCardById, useGetSalesOrder, useGetSalesOrderShipment, useGetServicesByCarrier, useGetShipment, useGetShipmentRates, useGetShippingRuleById, useGetShippingRuleConditionsOptions, useGetThemeById, useGetZonesByCarrier, useI18n, useListCarrierConnections, 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 };
19953
+ export { AccountSettingsAPI, AddressesAPI, AlchemyContext, AlchemyProvider, AlchemyTestProvider, CarriersAPI, CodedError, ConfirmationType, ConnectionsAPI, 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, isDataCodedErrors, isInvalidTokenError, logger, onError, parseError, retryUntil, useAddFunds, useAddInsuranceFunds, useAlchemy, useCalculateRates, useConnectCarrier, useCreateAccountImage, useCreateFundingSource, useCreateLabel, useCreateRateCard, useCreateSalesOrderShipment, useCreateShipment, useCreateShippingRule, useCreateWarehouse, useDeactivateOrderSource, useDeleteAccountImage, useDeleteRateCard, useDeleteShippingRule, useDeleteWarehouse, useDownloadRateCard, useEditShippingRule, useFundingSourcesAddFunds, useGetAccountBillingPlan, useGetAccountImages, useGetAccountSettings, useGetAutoFundingConfiguration, useGetCarrierById, useGetCarrierConnectionForm, useGetCountriesByCarrier, useGetCurrenciesByCarrier, useGetFundingSourceById, useGetFundingSourceMetadata, useGetFundingSourceTransactions, useGetInsuranceAccount, useGetLabel, useGetPackageRatingGroupByCarrier, useGetRateCardById, useGetSalesOrder, useGetSalesOrderShipment, useGetServicesByCarrier, useGetShipment, useGetShipmentRates, useGetShippingRuleById, useGetShippingRuleConditionsOptions, useGetThemeById, useGetZonesByCarrier, useI18n, useListCarrierConnections, 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 };