@shipengine/alchemy 6.0.43 → 6.0.44

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 +628 -574
  2. package/index.mjs +628 -575
  3. package/package.json +1 -1
package/index.js CHANGED
@@ -10812,17 +10812,17 @@ var AccountBillingPlanChangeType = /* @__PURE__ */ ((AccountBillingPlanChangeTyp
10812
10812
  return AccountBillingPlanChangeType2;
10813
10813
  })(AccountBillingPlanChangeType || {});
10814
10814
 
10815
- var __getOwnPropSymbols$P = Object.getOwnPropertySymbols;
10816
- var __hasOwnProp$P = Object.prototype.hasOwnProperty;
10817
- var __propIsEnum$P = Object.prototype.propertyIsEnumerable;
10818
- var __objRest$t = (source, exclude) => {
10815
+ var __getOwnPropSymbols$Q = Object.getOwnPropertySymbols;
10816
+ var __hasOwnProp$Q = Object.prototype.hasOwnProperty;
10817
+ var __propIsEnum$Q = Object.prototype.propertyIsEnumerable;
10818
+ var __objRest$u = (source, exclude) => {
10819
10819
  var target = {};
10820
10820
  for (var prop in source)
10821
- if (__hasOwnProp$P.call(source, prop) && exclude.indexOf(prop) < 0)
10821
+ if (__hasOwnProp$Q.call(source, prop) && exclude.indexOf(prop) < 0)
10822
10822
  target[prop] = source[prop];
10823
- if (source != null && __getOwnPropSymbols$P)
10824
- for (var prop of __getOwnPropSymbols$P(source)) {
10825
- if (exclude.indexOf(prop) < 0 && __propIsEnum$P.call(source, prop))
10823
+ if (source != null && __getOwnPropSymbols$Q)
10824
+ for (var prop of __getOwnPropSymbols$Q(source)) {
10825
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$Q.call(source, prop))
10826
10826
  target[prop] = source[prop];
10827
10827
  }
10828
10828
  return target;
@@ -10836,7 +10836,7 @@ class CodedError {
10836
10836
  this.message = message;
10837
10837
  }
10838
10838
  static fromObject(_a) {
10839
- var _b = _a, { message } = _b, options = __objRest$t(_b, ["message"]);
10839
+ var _b = _a, { message } = _b, options = __objRest$u(_b, ["message"]);
10840
10840
  return new CodedError(message, options);
10841
10841
  }
10842
10842
  }
@@ -10957,17 +10957,17 @@ const types = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
10957
10957
  RateCardStatus
10958
10958
  }, Symbol.toStringTag, { value: 'Module' }));
10959
10959
 
10960
- var __getOwnPropSymbols$O = Object.getOwnPropertySymbols;
10961
- var __hasOwnProp$O = Object.prototype.hasOwnProperty;
10962
- var __propIsEnum$O = Object.prototype.propertyIsEnumerable;
10963
- var __objRest$s = (source, exclude) => {
10960
+ var __getOwnPropSymbols$P = Object.getOwnPropertySymbols;
10961
+ var __hasOwnProp$P = Object.prototype.hasOwnProperty;
10962
+ var __propIsEnum$P = Object.prototype.propertyIsEnumerable;
10963
+ var __objRest$t = (source, exclude) => {
10964
10964
  var target = {};
10965
10965
  for (var prop in source)
10966
- if (__hasOwnProp$O.call(source, prop) && exclude.indexOf(prop) < 0)
10966
+ if (__hasOwnProp$P.call(source, prop) && exclude.indexOf(prop) < 0)
10967
10967
  target[prop] = source[prop];
10968
- if (source != null && __getOwnPropSymbols$O)
10969
- for (var prop of __getOwnPropSymbols$O(source)) {
10970
- if (exclude.indexOf(prop) < 0 && __propIsEnum$O.call(source, prop))
10968
+ if (source != null && __getOwnPropSymbols$P)
10969
+ for (var prop of __getOwnPropSymbols$P(source)) {
10970
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$P.call(source, prop))
10971
10971
  target[prop] = source[prop];
10972
10972
  }
10973
10973
  return target;
@@ -10999,7 +10999,7 @@ class AccountSettingsAPI {
10999
10999
  * The `updateImage` method updates specific image data for a given image id.
11000
11000
  */
11001
11001
  this.updateImage = (_a) => {
11002
- var _b = _a, { labelImageId } = _b, data = __objRest$s(_b, ["labelImageId"]);
11002
+ var _b = _a, { labelImageId } = _b, data = __objRest$t(_b, ["labelImageId"]);
11003
11003
  return this.client.put(`/v1/account/settings/images/${labelImageId}`, data);
11004
11004
  };
11005
11005
  /**
@@ -13848,33 +13848,33 @@ const decamelizeKeys = (obj, separator = "_") => {
13848
13848
  return obj;
13849
13849
  };
13850
13850
 
13851
- var __defProp$D = Object.defineProperty;
13852
- var __defProps$x = Object.defineProperties;
13853
- var __getOwnPropDescs$x = Object.getOwnPropertyDescriptors;
13854
- var __getOwnPropSymbols$N = Object.getOwnPropertySymbols;
13855
- var __hasOwnProp$N = Object.prototype.hasOwnProperty;
13856
- var __propIsEnum$N = Object.prototype.propertyIsEnumerable;
13857
- var __defNormalProp$D = (obj, key, value) => key in obj ? __defProp$D(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
13858
- var __spreadValues$D = (a, b) => {
13851
+ var __defProp$E = Object.defineProperty;
13852
+ var __defProps$y = Object.defineProperties;
13853
+ var __getOwnPropDescs$y = Object.getOwnPropertyDescriptors;
13854
+ var __getOwnPropSymbols$O = Object.getOwnPropertySymbols;
13855
+ var __hasOwnProp$O = Object.prototype.hasOwnProperty;
13856
+ var __propIsEnum$O = Object.prototype.propertyIsEnumerable;
13857
+ var __defNormalProp$E = (obj, key, value) => key in obj ? __defProp$E(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
13858
+ var __spreadValues$E = (a, b) => {
13859
13859
  for (var prop in b || (b = {}))
13860
- if (__hasOwnProp$N.call(b, prop))
13861
- __defNormalProp$D(a, prop, b[prop]);
13862
- if (__getOwnPropSymbols$N)
13863
- for (var prop of __getOwnPropSymbols$N(b)) {
13864
- if (__propIsEnum$N.call(b, prop))
13865
- __defNormalProp$D(a, prop, b[prop]);
13860
+ if (__hasOwnProp$O.call(b, prop))
13861
+ __defNormalProp$E(a, prop, b[prop]);
13862
+ if (__getOwnPropSymbols$O)
13863
+ for (var prop of __getOwnPropSymbols$O(b)) {
13864
+ if (__propIsEnum$O.call(b, prop))
13865
+ __defNormalProp$E(a, prop, b[prop]);
13866
13866
  }
13867
13867
  return a;
13868
13868
  };
13869
- var __spreadProps$x = (a, b) => __defProps$x(a, __getOwnPropDescs$x(b));
13870
- var __objRest$r = (source, exclude) => {
13869
+ var __spreadProps$y = (a, b) => __defProps$y(a, __getOwnPropDescs$y(b));
13870
+ var __objRest$s = (source, exclude) => {
13871
13871
  var target = {};
13872
13872
  for (var prop in source)
13873
- if (__hasOwnProp$N.call(source, prop) && exclude.indexOf(prop) < 0)
13873
+ if (__hasOwnProp$O.call(source, prop) && exclude.indexOf(prop) < 0)
13874
13874
  target[prop] = source[prop];
13875
- if (source != null && __getOwnPropSymbols$N)
13876
- for (var prop of __getOwnPropSymbols$N(source)) {
13877
- if (exclude.indexOf(prop) < 0 && __propIsEnum$N.call(source, prop))
13875
+ if (source != null && __getOwnPropSymbols$O)
13876
+ for (var prop of __getOwnPropSymbols$O(source)) {
13877
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$O.call(source, prop))
13878
13878
  target[prop] = source[prop];
13879
13879
  }
13880
13880
  return target;
@@ -13920,11 +13920,11 @@ class CarriersAPI {
13920
13920
  * The `connect` method connects a carrier account to a user's ShipEngine account.
13921
13921
  */
13922
13922
  this.connect = (_a) => __async$$(this, null, function* () {
13923
- var _b = _a, { carrierCode } = _b, connection = __objRest$r(_b, ["carrierCode"]);
13923
+ var _b = _a, { carrierCode } = _b, connection = __objRest$s(_b, ["carrierCode"]);
13924
13924
  const endUserIpAddress = yield getEndUserIpAddress();
13925
13925
  if (!endUserIpAddress)
13926
13926
  return Promise.reject([new CodedError("Unable to get IP address")]);
13927
- return yield this.client.post(`/v1/registration/${carrierCode}`, __spreadProps$x(__spreadValues$D({}, connection), {
13927
+ return yield this.client.post(`/v1/registration/${carrierCode}`, __spreadProps$y(__spreadValues$E({}, connection), {
13928
13928
  endUserIpAddress
13929
13929
  }));
13930
13930
  });
@@ -16208,19 +16208,19 @@ class CustomPackagesAPI {
16208
16208
  }
16209
16209
  }
16210
16210
 
16211
- var __defProp$C = Object.defineProperty;
16212
- var __getOwnPropSymbols$M = Object.getOwnPropertySymbols;
16213
- var __hasOwnProp$M = Object.prototype.hasOwnProperty;
16214
- var __propIsEnum$M = Object.prototype.propertyIsEnumerable;
16215
- var __defNormalProp$C = (obj, key, value) => key in obj ? __defProp$C(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16216
- var __spreadValues$C = (a, b) => {
16211
+ var __defProp$D = Object.defineProperty;
16212
+ var __getOwnPropSymbols$N = Object.getOwnPropertySymbols;
16213
+ var __hasOwnProp$N = Object.prototype.hasOwnProperty;
16214
+ var __propIsEnum$N = Object.prototype.propertyIsEnumerable;
16215
+ var __defNormalProp$D = (obj, key, value) => key in obj ? __defProp$D(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16216
+ var __spreadValues$D = (a, b) => {
16217
16217
  for (var prop in b || (b = {}))
16218
- if (__hasOwnProp$M.call(b, prop))
16219
- __defNormalProp$C(a, prop, b[prop]);
16220
- if (__getOwnPropSymbols$M)
16221
- for (var prop of __getOwnPropSymbols$M(b)) {
16222
- if (__propIsEnum$M.call(b, prop))
16223
- __defNormalProp$C(a, prop, b[prop]);
16218
+ if (__hasOwnProp$N.call(b, prop))
16219
+ __defNormalProp$D(a, prop, b[prop]);
16220
+ if (__getOwnPropSymbols$N)
16221
+ for (var prop of __getOwnPropSymbols$N(b)) {
16222
+ if (__propIsEnum$N.call(b, prop))
16223
+ __defNormalProp$D(a, prop, b[prop]);
16224
16224
  }
16225
16225
  return a;
16226
16226
  };
@@ -16268,7 +16268,7 @@ class FundingSourcesAPI {
16268
16268
  if (!endUserIpAddress) {
16269
16269
  return Promise.reject([new CodedError("Unable to get IP address")]);
16270
16270
  }
16271
- return yield this.client.post("/v1/funding_sources", __spreadValues$C({
16271
+ return yield this.client.post("/v1/funding_sources", __spreadValues$D({
16272
16272
  endUserIpAddress
16273
16273
  }, createFundingSource));
16274
16274
  });
@@ -16287,7 +16287,7 @@ class FundingSourcesAPI {
16287
16287
  {
16288
16288
  billingInfo,
16289
16289
  endUserIpAddress,
16290
- paymentMethod: __spreadValues$C({
16290
+ paymentMethod: __spreadValues$D({
16291
16291
  creditCardInfo
16292
16292
  }, auctanePayInfo)
16293
16293
  }
@@ -16302,7 +16302,7 @@ class FundingSourcesAPI {
16302
16302
  if (!endUserIpAddress) {
16303
16303
  return Promise.reject([new CodedError("Unable to get IP address")]);
16304
16304
  }
16305
- return yield this.client.post("/v1/registration/funding_source", __spreadValues$C({
16305
+ return yield this.client.post("/v1/registration/funding_source", __spreadValues$D({
16306
16306
  endUserIpAddress
16307
16307
  }, carrier));
16308
16308
  });
@@ -16471,17 +16471,17 @@ class LabelsAPI {
16471
16471
  }
16472
16472
  }
16473
16473
 
16474
- var __getOwnPropSymbols$L = Object.getOwnPropertySymbols;
16475
- var __hasOwnProp$L = Object.prototype.hasOwnProperty;
16476
- var __propIsEnum$L = Object.prototype.propertyIsEnumerable;
16477
- var __objRest$q = (source, exclude) => {
16474
+ var __getOwnPropSymbols$M = Object.getOwnPropertySymbols;
16475
+ var __hasOwnProp$M = Object.prototype.hasOwnProperty;
16476
+ var __propIsEnum$M = Object.prototype.propertyIsEnumerable;
16477
+ var __objRest$r = (source, exclude) => {
16478
16478
  var target = {};
16479
16479
  for (var prop in source)
16480
- if (__hasOwnProp$L.call(source, prop) && exclude.indexOf(prop) < 0)
16480
+ if (__hasOwnProp$M.call(source, prop) && exclude.indexOf(prop) < 0)
16481
16481
  target[prop] = source[prop];
16482
- if (source != null && __getOwnPropSymbols$L)
16483
- for (var prop of __getOwnPropSymbols$L(source)) {
16484
- if (exclude.indexOf(prop) < 0 && __propIsEnum$L.call(source, prop))
16482
+ if (source != null && __getOwnPropSymbols$M)
16483
+ for (var prop of __getOwnPropSymbols$M(source)) {
16484
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$M.call(source, prop))
16485
16485
  target[prop] = source[prop];
16486
16486
  }
16487
16487
  return target;
@@ -16513,7 +16513,7 @@ class OrderSourcesAPI {
16513
16513
  * The `update` method will allow the user to update a connected Order Source
16514
16514
  */
16515
16515
  this.update = (_a) => {
16516
- var _b = _a, { orderSourceId } = _b, rest = __objRest$q(_b, ["orderSourceId"]);
16516
+ var _b = _a, { orderSourceId } = _b, rest = __objRest$r(_b, ["orderSourceId"]);
16517
16517
  return this.client.put(`/v-beta/order_sources/${orderSourceId}`, rest);
16518
16518
  };
16519
16519
  /**
@@ -16602,19 +16602,19 @@ class RateCardsAPI {
16602
16602
  }
16603
16603
  }
16604
16604
 
16605
- var __defProp$B = Object.defineProperty;
16606
- var __getOwnPropSymbols$K = Object.getOwnPropertySymbols;
16607
- var __hasOwnProp$K = Object.prototype.hasOwnProperty;
16608
- var __propIsEnum$K = Object.prototype.propertyIsEnumerable;
16609
- var __defNormalProp$B = (obj, key, value) => key in obj ? __defProp$B(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16610
- var __spreadValues$B = (a, b) => {
16605
+ var __defProp$C = Object.defineProperty;
16606
+ var __getOwnPropSymbols$L = Object.getOwnPropertySymbols;
16607
+ var __hasOwnProp$L = Object.prototype.hasOwnProperty;
16608
+ var __propIsEnum$L = Object.prototype.propertyIsEnumerable;
16609
+ var __defNormalProp$C = (obj, key, value) => key in obj ? __defProp$C(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16610
+ var __spreadValues$C = (a, b) => {
16611
16611
  for (var prop in b || (b = {}))
16612
- if (__hasOwnProp$K.call(b, prop))
16613
- __defNormalProp$B(a, prop, b[prop]);
16614
- if (__getOwnPropSymbols$K)
16615
- for (var prop of __getOwnPropSymbols$K(b)) {
16616
- if (__propIsEnum$K.call(b, prop))
16617
- __defNormalProp$B(a, prop, b[prop]);
16612
+ if (__hasOwnProp$L.call(b, prop))
16613
+ __defNormalProp$C(a, prop, b[prop]);
16614
+ if (__getOwnPropSymbols$L)
16615
+ for (var prop of __getOwnPropSymbols$L(b)) {
16616
+ if (__propIsEnum$L.call(b, prop))
16617
+ __defNormalProp$C(a, prop, b[prop]);
16618
16618
  }
16619
16619
  return a;
16620
16620
  };
@@ -16636,7 +16636,7 @@ class RatesAPI {
16636
16636
  * method.
16637
16637
  */
16638
16638
  this.estimate = (params) => {
16639
- return this.client.post("/v1/rates/estimate", __spreadValues$B({}, params));
16639
+ return this.client.post("/v1/rates/estimate", __spreadValues$C({}, params));
16640
16640
  };
16641
16641
  this.client = client;
16642
16642
  }
@@ -16820,19 +16820,19 @@ class SellersAPI {
16820
16820
  }
16821
16821
  }
16822
16822
 
16823
- var __defProp$A = Object.defineProperty;
16824
- var __getOwnPropSymbols$J = Object.getOwnPropertySymbols;
16825
- var __hasOwnProp$J = Object.prototype.hasOwnProperty;
16826
- var __propIsEnum$J = Object.prototype.propertyIsEnumerable;
16827
- var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16828
- var __spreadValues$A = (a, b) => {
16823
+ var __defProp$B = Object.defineProperty;
16824
+ var __getOwnPropSymbols$K = Object.getOwnPropertySymbols;
16825
+ var __hasOwnProp$K = Object.prototype.hasOwnProperty;
16826
+ var __propIsEnum$K = Object.prototype.propertyIsEnumerable;
16827
+ var __defNormalProp$B = (obj, key, value) => key in obj ? __defProp$B(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
16828
+ var __spreadValues$B = (a, b) => {
16829
16829
  for (var prop in b || (b = {}))
16830
- if (__hasOwnProp$J.call(b, prop))
16831
- __defNormalProp$A(a, prop, b[prop]);
16832
- if (__getOwnPropSymbols$J)
16833
- for (var prop of __getOwnPropSymbols$J(b)) {
16834
- if (__propIsEnum$J.call(b, prop))
16835
- __defNormalProp$A(a, prop, b[prop]);
16830
+ if (__hasOwnProp$K.call(b, prop))
16831
+ __defNormalProp$B(a, prop, b[prop]);
16832
+ if (__getOwnPropSymbols$K)
16833
+ for (var prop of __getOwnPropSymbols$K(b)) {
16834
+ if (__propIsEnum$K.call(b, prop))
16835
+ __defNormalProp$B(a, prop, b[prop]);
16836
16836
  }
16837
16837
  return a;
16838
16838
  };
@@ -16844,7 +16844,7 @@ class ServicePointsAPI {
16844
16844
  * Either an address, coordinates, or an address query
16845
16845
  */
16846
16846
  this.list = (options) => {
16847
- return this.client.post("/v1/service_points/list", __spreadValues$A({}, options));
16847
+ return this.client.post("/v1/service_points/list", __spreadValues$B({}, options));
16848
16848
  };
16849
16849
  /**
16850
16850
  * Get a specific service point by its carrier code, country code, and id
@@ -16927,6 +16927,18 @@ class ShipmentsAPI {
16927
16927
  this.cancel = (shipmentId) => {
16928
16928
  return this.client.put(`/v1/shipments/${shipmentId}/cancel`);
16929
16929
  };
16930
+ /**
16931
+ * The `download` method allows for downloading a CSV document of shipments based on the provided parameters.
16932
+ */
16933
+ this.download = (params) => {
16934
+ return this.client.get("/v1/shipments/downloads", {
16935
+ headers: {
16936
+ Accept: "text/csv"
16937
+ },
16938
+ params,
16939
+ responseType: "blob"
16940
+ });
16941
+ };
16930
16942
  this.client = client;
16931
16943
  }
16932
16944
  }
@@ -34303,25 +34315,25 @@ class WebhooksAPI {
34303
34315
  }
34304
34316
  }
34305
34317
 
34306
- var __defProp$z = Object.defineProperty;
34307
- var __defProps$w = Object.defineProperties;
34308
- var __getOwnPropDescs$w = Object.getOwnPropertyDescriptors;
34309
- var __getOwnPropSymbols$I = Object.getOwnPropertySymbols;
34310
- var __hasOwnProp$I = Object.prototype.hasOwnProperty;
34311
- var __propIsEnum$I = Object.prototype.propertyIsEnumerable;
34312
- var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
34313
- var __spreadValues$z = (a, b) => {
34318
+ var __defProp$A = Object.defineProperty;
34319
+ var __defProps$x = Object.defineProperties;
34320
+ var __getOwnPropDescs$x = Object.getOwnPropertyDescriptors;
34321
+ var __getOwnPropSymbols$J = Object.getOwnPropertySymbols;
34322
+ var __hasOwnProp$J = Object.prototype.hasOwnProperty;
34323
+ var __propIsEnum$J = Object.prototype.propertyIsEnumerable;
34324
+ var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
34325
+ var __spreadValues$A = (a, b) => {
34314
34326
  for (var prop in b || (b = {}))
34315
- if (__hasOwnProp$I.call(b, prop))
34316
- __defNormalProp$z(a, prop, b[prop]);
34317
- if (__getOwnPropSymbols$I)
34318
- for (var prop of __getOwnPropSymbols$I(b)) {
34319
- if (__propIsEnum$I.call(b, prop))
34320
- __defNormalProp$z(a, prop, b[prop]);
34327
+ if (__hasOwnProp$J.call(b, prop))
34328
+ __defNormalProp$A(a, prop, b[prop]);
34329
+ if (__getOwnPropSymbols$J)
34330
+ for (var prop of __getOwnPropSymbols$J(b)) {
34331
+ if (__propIsEnum$J.call(b, prop))
34332
+ __defNormalProp$A(a, prop, b[prop]);
34321
34333
  }
34322
34334
  return a;
34323
34335
  };
34324
- var __spreadProps$w = (a, b) => __defProps$w(a, __getOwnPropDescs$w(b));
34336
+ var __spreadProps$x = (a, b) => __defProps$x(a, __getOwnPropDescs$x(b));
34325
34337
  var __async$V = (__this, __arguments, generator) => {
34326
34338
  return new Promise((resolve, reject) => {
34327
34339
  var fulfilled = (value) => {
@@ -34345,7 +34357,7 @@ var __async$V = (__this, __arguments, generator) => {
34345
34357
  const logger$1 = E({
34346
34358
  level: process.env.NODE_ENV === "production" ? "fatal" : "info",
34347
34359
  name: "shipengine-api",
34348
- serializers: __spreadProps$w(__spreadValues$z({}, k), {
34360
+ serializers: __spreadProps$x(__spreadValues$A({}, k), {
34349
34361
  req: (req) => ({
34350
34362
  headers: req.headers,
34351
34363
  method: req.method,
@@ -34370,7 +34382,7 @@ class ShipEngineAPI {
34370
34382
  this.getSandboxToken = getSandboxToken;
34371
34383
  const client = axios.create({
34372
34384
  baseURL,
34373
- headers: __spreadProps$w(__spreadValues$z({}, headers), {
34385
+ headers: __spreadProps$x(__spreadValues$A({}, headers), {
34374
34386
  "Content-Type": "application/json"
34375
34387
  }),
34376
34388
  paramsSerializer: (params) => lib.stringify(decamelizeKeys(params), { arrayFormat: "brackets" }),
@@ -34774,25 +34786,25 @@ const delay = (ms) => new Promise((resolve) => {
34774
34786
 
34775
34787
  const onError = (_errors) => _default();
34776
34788
 
34777
- var __defProp$y = Object.defineProperty;
34778
- var __defProps$v = Object.defineProperties;
34779
- var __getOwnPropDescs$v = Object.getOwnPropertyDescriptors;
34780
- var __getOwnPropSymbols$H = Object.getOwnPropertySymbols;
34781
- var __hasOwnProp$H = Object.prototype.hasOwnProperty;
34782
- var __propIsEnum$H = Object.prototype.propertyIsEnumerable;
34783
- var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
34784
- var __spreadValues$y = (a, b) => {
34789
+ var __defProp$z = Object.defineProperty;
34790
+ var __defProps$w = Object.defineProperties;
34791
+ var __getOwnPropDescs$w = Object.getOwnPropertyDescriptors;
34792
+ var __getOwnPropSymbols$I = Object.getOwnPropertySymbols;
34793
+ var __hasOwnProp$I = Object.prototype.hasOwnProperty;
34794
+ var __propIsEnum$I = Object.prototype.propertyIsEnumerable;
34795
+ var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
34796
+ var __spreadValues$z = (a, b) => {
34785
34797
  for (var prop in b || (b = {}))
34786
- if (__hasOwnProp$H.call(b, prop))
34787
- __defNormalProp$y(a, prop, b[prop]);
34788
- if (__getOwnPropSymbols$H)
34789
- for (var prop of __getOwnPropSymbols$H(b)) {
34790
- if (__propIsEnum$H.call(b, prop))
34791
- __defNormalProp$y(a, prop, b[prop]);
34798
+ if (__hasOwnProp$I.call(b, prop))
34799
+ __defNormalProp$z(a, prop, b[prop]);
34800
+ if (__getOwnPropSymbols$I)
34801
+ for (var prop of __getOwnPropSymbols$I(b)) {
34802
+ if (__propIsEnum$I.call(b, prop))
34803
+ __defNormalProp$z(a, prop, b[prop]);
34792
34804
  }
34793
34805
  return a;
34794
34806
  };
34795
- var __spreadProps$v = (a, b) => __defProps$v(a, __getOwnPropDescs$v(b));
34807
+ var __spreadProps$w = (a, b) => __defProps$w(a, __getOwnPropDescs$w(b));
34796
34808
  const streams = [];
34797
34809
  if (process.env.NODE_ENV === "production") {
34798
34810
  streams.push({
@@ -34801,7 +34813,7 @@ if (process.env.NODE_ENV === "production") {
34801
34813
  }
34802
34814
  const logger = E({
34803
34815
  name: "shipengine",
34804
- serializers: __spreadProps$v(__spreadValues$y({}, k), {
34816
+ serializers: __spreadProps$w(__spreadValues$z({}, k), {
34805
34817
  req: (req) => ({
34806
34818
  headers: req.headers,
34807
34819
  method: req.method,
@@ -35038,25 +35050,25 @@ const useValidateAddresses = () => {
35038
35050
  });
35039
35051
  };
35040
35052
 
35041
- var __defProp$x = Object.defineProperty;
35042
- var __defProps$u = Object.defineProperties;
35043
- var __getOwnPropDescs$u = Object.getOwnPropertyDescriptors;
35044
- var __getOwnPropSymbols$G = Object.getOwnPropertySymbols;
35045
- var __hasOwnProp$G = Object.prototype.hasOwnProperty;
35046
- var __propIsEnum$G = Object.prototype.propertyIsEnumerable;
35047
- var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35048
- var __spreadValues$x = (a, b) => {
35053
+ var __defProp$y = Object.defineProperty;
35054
+ var __defProps$v = Object.defineProperties;
35055
+ var __getOwnPropDescs$v = Object.getOwnPropertyDescriptors;
35056
+ var __getOwnPropSymbols$H = Object.getOwnPropertySymbols;
35057
+ var __hasOwnProp$H = Object.prototype.hasOwnProperty;
35058
+ var __propIsEnum$H = Object.prototype.propertyIsEnumerable;
35059
+ var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35060
+ var __spreadValues$y = (a, b) => {
35049
35061
  for (var prop in b || (b = {}))
35050
- if (__hasOwnProp$G.call(b, prop))
35051
- __defNormalProp$x(a, prop, b[prop]);
35052
- if (__getOwnPropSymbols$G)
35053
- for (var prop of __getOwnPropSymbols$G(b)) {
35054
- if (__propIsEnum$G.call(b, prop))
35055
- __defNormalProp$x(a, prop, b[prop]);
35062
+ if (__hasOwnProp$H.call(b, prop))
35063
+ __defNormalProp$y(a, prop, b[prop]);
35064
+ if (__getOwnPropSymbols$H)
35065
+ for (var prop of __getOwnPropSymbols$H(b)) {
35066
+ if (__propIsEnum$H.call(b, prop))
35067
+ __defNormalProp$y(a, prop, b[prop]);
35056
35068
  }
35057
35069
  return a;
35058
35070
  };
35059
- var __spreadProps$u = (a, b) => __defProps$u(a, __getOwnPropDescs$u(b));
35071
+ var __spreadProps$v = (a, b) => __defProps$v(a, __getOwnPropDescs$v(b));
35060
35072
  var __async$O = (__this, __arguments, generator) => {
35061
35073
  return new Promise((resolve, reject) => {
35062
35074
  var fulfilled = (value) => {
@@ -35079,7 +35091,7 @@ var __async$O = (__this, __arguments, generator) => {
35079
35091
  };
35080
35092
  const useCreateAuctanePaySession = (params) => {
35081
35093
  const { client } = useShipEngine();
35082
- return reactQuery.useMutation(__spreadProps$u(__spreadValues$x({}, params), {
35094
+ return reactQuery.useMutation(__spreadProps$v(__spreadValues$y({}, params), {
35083
35095
  mutationFn: (request) => __async$O(void 0, null, function* () {
35084
35096
  const result = yield client.auctanePay.createSession(request);
35085
35097
  return result.data;
@@ -35089,29 +35101,29 @@ const useCreateAuctanePaySession = (params) => {
35089
35101
  }));
35090
35102
  };
35091
35103
 
35092
- var __defProp$w = Object.defineProperty;
35093
- var __defProps$t = Object.defineProperties;
35094
- var __getOwnPropDescs$t = Object.getOwnPropertyDescriptors;
35095
- var __getOwnPropSymbols$F = Object.getOwnPropertySymbols;
35096
- var __hasOwnProp$F = Object.prototype.hasOwnProperty;
35097
- var __propIsEnum$F = Object.prototype.propertyIsEnumerable;
35098
- var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35099
- var __spreadValues$w = (a, b) => {
35104
+ var __defProp$x = Object.defineProperty;
35105
+ var __defProps$u = Object.defineProperties;
35106
+ var __getOwnPropDescs$u = Object.getOwnPropertyDescriptors;
35107
+ var __getOwnPropSymbols$G = Object.getOwnPropertySymbols;
35108
+ var __hasOwnProp$G = Object.prototype.hasOwnProperty;
35109
+ var __propIsEnum$G = Object.prototype.propertyIsEnumerable;
35110
+ var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35111
+ var __spreadValues$x = (a, b) => {
35100
35112
  for (var prop in b || (b = {}))
35101
- if (__hasOwnProp$F.call(b, prop))
35102
- __defNormalProp$w(a, prop, b[prop]);
35103
- if (__getOwnPropSymbols$F)
35104
- for (var prop of __getOwnPropSymbols$F(b)) {
35105
- if (__propIsEnum$F.call(b, prop))
35106
- __defNormalProp$w(a, prop, b[prop]);
35113
+ if (__hasOwnProp$G.call(b, prop))
35114
+ __defNormalProp$x(a, prop, b[prop]);
35115
+ if (__getOwnPropSymbols$G)
35116
+ for (var prop of __getOwnPropSymbols$G(b)) {
35117
+ if (__propIsEnum$G.call(b, prop))
35118
+ __defNormalProp$x(a, prop, b[prop]);
35107
35119
  }
35108
35120
  return a;
35109
35121
  };
35110
- var __spreadProps$t = (a, b) => __defProps$t(a, __getOwnPropDescs$t(b));
35122
+ var __spreadProps$u = (a, b) => __defProps$u(a, __getOwnPropDescs$u(b));
35111
35123
  const useGetAuctanePayConfig = (params) => {
35112
35124
  const { client } = useShipEngine();
35113
- const queryParams = __spreadValues$w({}, params);
35114
- return reactQuery.useQuery(__spreadProps$t(__spreadValues$w({}, queryParams), {
35125
+ const queryParams = __spreadValues$x({}, params);
35126
+ return reactQuery.useQuery(__spreadProps$u(__spreadValues$x({}, queryParams), {
35115
35127
  onError,
35116
35128
  queryFn: () => client.auctanePay.getConfig(),
35117
35129
  queryKey: ["useGetAuctanePayConfig"],
@@ -35283,41 +35295,41 @@ const useGetServicesByCarrier = (carrierId) => {
35283
35295
  });
35284
35296
  };
35285
35297
 
35286
- var __defProp$v = Object.defineProperty;
35287
- var __defProps$s = Object.defineProperties;
35288
- var __getOwnPropDescs$s = Object.getOwnPropertyDescriptors;
35289
- var __getOwnPropSymbols$E = Object.getOwnPropertySymbols;
35290
- var __hasOwnProp$E = Object.prototype.hasOwnProperty;
35291
- var __propIsEnum$E = Object.prototype.propertyIsEnumerable;
35292
- var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35293
- var __spreadValues$v = (a, b) => {
35298
+ var __defProp$w = Object.defineProperty;
35299
+ var __defProps$t = Object.defineProperties;
35300
+ var __getOwnPropDescs$t = Object.getOwnPropertyDescriptors;
35301
+ var __getOwnPropSymbols$F = Object.getOwnPropertySymbols;
35302
+ var __hasOwnProp$F = Object.prototype.hasOwnProperty;
35303
+ var __propIsEnum$F = Object.prototype.propertyIsEnumerable;
35304
+ var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35305
+ var __spreadValues$w = (a, b) => {
35294
35306
  for (var prop in b || (b = {}))
35295
- if (__hasOwnProp$E.call(b, prop))
35296
- __defNormalProp$v(a, prop, b[prop]);
35297
- if (__getOwnPropSymbols$E)
35298
- for (var prop of __getOwnPropSymbols$E(b)) {
35299
- if (__propIsEnum$E.call(b, prop))
35300
- __defNormalProp$v(a, prop, b[prop]);
35307
+ if (__hasOwnProp$F.call(b, prop))
35308
+ __defNormalProp$w(a, prop, b[prop]);
35309
+ if (__getOwnPropSymbols$F)
35310
+ for (var prop of __getOwnPropSymbols$F(b)) {
35311
+ if (__propIsEnum$F.call(b, prop))
35312
+ __defNormalProp$w(a, prop, b[prop]);
35301
35313
  }
35302
35314
  return a;
35303
35315
  };
35304
- var __spreadProps$s = (a, b) => __defProps$s(a, __getOwnPropDescs$s(b));
35305
- var __objRest$p = (source, exclude) => {
35316
+ var __spreadProps$t = (a, b) => __defProps$t(a, __getOwnPropDescs$t(b));
35317
+ var __objRest$q = (source, exclude) => {
35306
35318
  var target = {};
35307
35319
  for (var prop in source)
35308
- if (__hasOwnProp$E.call(source, prop) && exclude.indexOf(prop) < 0)
35320
+ if (__hasOwnProp$F.call(source, prop) && exclude.indexOf(prop) < 0)
35309
35321
  target[prop] = source[prop];
35310
- if (source != null && __getOwnPropSymbols$E)
35311
- for (var prop of __getOwnPropSymbols$E(source)) {
35312
- if (exclude.indexOf(prop) < 0 && __propIsEnum$E.call(source, prop))
35322
+ if (source != null && __getOwnPropSymbols$F)
35323
+ for (var prop of __getOwnPropSymbols$F(source)) {
35324
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$F.call(source, prop))
35313
35325
  target[prop] = source[prop];
35314
35326
  }
35315
35327
  return target;
35316
35328
  };
35317
35329
  const useListCarriers = (params) => {
35318
35330
  const { client } = useShipEngine();
35319
- const _a = __spreadValues$v({}, params), { queryFnParams } = _a, rest = __objRest$p(_a, ["queryFnParams"]);
35320
- return reactQuery.useQuery(__spreadProps$s(__spreadValues$v({}, rest), {
35331
+ const _a = __spreadValues$w({}, params), { queryFnParams } = _a, rest = __objRest$q(_a, ["queryFnParams"]);
35332
+ return reactQuery.useQuery(__spreadProps$t(__spreadValues$w({}, rest), {
35321
35333
  onError,
35322
35334
  queryFn: () => client.carriers.list(queryFnParams),
35323
35335
  queryKey: ["useListCarriers", queryFnParams],
@@ -35325,17 +35337,17 @@ const useListCarriers = (params) => {
35325
35337
  }));
35326
35338
  };
35327
35339
 
35328
- var __getOwnPropSymbols$D = Object.getOwnPropertySymbols;
35329
- var __hasOwnProp$D = Object.prototype.hasOwnProperty;
35330
- var __propIsEnum$D = Object.prototype.propertyIsEnumerable;
35331
- var __objRest$o = (source, exclude) => {
35340
+ var __getOwnPropSymbols$E = Object.getOwnPropertySymbols;
35341
+ var __hasOwnProp$E = Object.prototype.hasOwnProperty;
35342
+ var __propIsEnum$E = Object.prototype.propertyIsEnumerable;
35343
+ var __objRest$p = (source, exclude) => {
35332
35344
  var target = {};
35333
35345
  for (var prop in source)
35334
- if (__hasOwnProp$D.call(source, prop) && exclude.indexOf(prop) < 0)
35346
+ if (__hasOwnProp$E.call(source, prop) && exclude.indexOf(prop) < 0)
35335
35347
  target[prop] = source[prop];
35336
- if (source != null && __getOwnPropSymbols$D)
35337
- for (var prop of __getOwnPropSymbols$D(source)) {
35338
- if (exclude.indexOf(prop) < 0 && __propIsEnum$D.call(source, prop))
35348
+ if (source != null && __getOwnPropSymbols$E)
35349
+ for (var prop of __getOwnPropSymbols$E(source)) {
35350
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$E.call(source, prop))
35339
35351
  target[prop] = source[prop];
35340
35352
  }
35341
35353
  return target;
@@ -35365,7 +35377,7 @@ const useUpdateAutoFunding = () => {
35365
35377
  const queryClient = reactQuery.useQueryClient();
35366
35378
  return reactQuery.useMutation({
35367
35379
  mutationFn: (_a) => __async$L(void 0, null, function* () {
35368
- var _b = _a, { carrierId } = _b, options = __objRest$o(_b, ["carrierId"]);
35380
+ var _b = _a, { carrierId } = _b, options = __objRest$p(_b, ["carrierId"]);
35369
35381
  const result = yield client.carriers.updateAutoFunding(carrierId, options);
35370
35382
  return result.data;
35371
35383
  }),
@@ -35426,24 +35438,24 @@ const useDeleteCarrier = () => {
35426
35438
  });
35427
35439
  };
35428
35440
 
35429
- var __getOwnPropSymbols$C = Object.getOwnPropertySymbols;
35430
- var __hasOwnProp$C = Object.prototype.hasOwnProperty;
35431
- var __propIsEnum$C = Object.prototype.propertyIsEnumerable;
35432
- var __objRest$n = (source, exclude) => {
35441
+ var __getOwnPropSymbols$D = Object.getOwnPropertySymbols;
35442
+ var __hasOwnProp$D = Object.prototype.hasOwnProperty;
35443
+ var __propIsEnum$D = Object.prototype.propertyIsEnumerable;
35444
+ var __objRest$o = (source, exclude) => {
35433
35445
  var target = {};
35434
35446
  for (var prop in source)
35435
- if (__hasOwnProp$C.call(source, prop) && exclude.indexOf(prop) < 0)
35447
+ if (__hasOwnProp$D.call(source, prop) && exclude.indexOf(prop) < 0)
35436
35448
  target[prop] = source[prop];
35437
- if (source != null && __getOwnPropSymbols$C)
35438
- for (var prop of __getOwnPropSymbols$C(source)) {
35439
- if (exclude.indexOf(prop) < 0 && __propIsEnum$C.call(source, prop))
35449
+ if (source != null && __getOwnPropSymbols$D)
35450
+ for (var prop of __getOwnPropSymbols$D(source)) {
35451
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$D.call(source, prop))
35440
35452
  target[prop] = source[prop];
35441
35453
  }
35442
35454
  return target;
35443
35455
  };
35444
35456
  const useGetCarrierConnectionForm = (_params) => {
35445
35457
  const { client } = useShipEngine();
35446
- const _a = _params || {}, { carrierName, enabled = true } = _a, params = __objRest$n(_a, ["carrierName", "enabled"]);
35458
+ const _a = _params || {}, { carrierName, enabled = true } = _a, params = __objRest$o(_a, ["carrierName", "enabled"]);
35447
35459
  return reactQuery.useQuery({
35448
35460
  enabled,
35449
35461
  onError,
@@ -35453,24 +35465,24 @@ const useGetCarrierConnectionForm = (_params) => {
35453
35465
  });
35454
35466
  };
35455
35467
 
35456
- var __getOwnPropSymbols$B = Object.getOwnPropertySymbols;
35457
- var __hasOwnProp$B = Object.prototype.hasOwnProperty;
35458
- var __propIsEnum$B = Object.prototype.propertyIsEnumerable;
35459
- var __objRest$m = (source, exclude) => {
35468
+ var __getOwnPropSymbols$C = Object.getOwnPropertySymbols;
35469
+ var __hasOwnProp$C = Object.prototype.hasOwnProperty;
35470
+ var __propIsEnum$C = Object.prototype.propertyIsEnumerable;
35471
+ var __objRest$n = (source, exclude) => {
35460
35472
  var target = {};
35461
35473
  for (var prop in source)
35462
- if (__hasOwnProp$B.call(source, prop) && exclude.indexOf(prop) < 0)
35474
+ if (__hasOwnProp$C.call(source, prop) && exclude.indexOf(prop) < 0)
35463
35475
  target[prop] = source[prop];
35464
- if (source != null && __getOwnPropSymbols$B)
35465
- for (var prop of __getOwnPropSymbols$B(source)) {
35466
- if (exclude.indexOf(prop) < 0 && __propIsEnum$B.call(source, prop))
35476
+ if (source != null && __getOwnPropSymbols$C)
35477
+ for (var prop of __getOwnPropSymbols$C(source)) {
35478
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$C.call(source, prop))
35467
35479
  target[prop] = source[prop];
35468
35480
  }
35469
35481
  return target;
35470
35482
  };
35471
35483
  const useListCarrierConnections = (_params) => {
35472
35484
  const { client } = useShipEngine();
35473
- const _a = _params || {}, { enabled = true } = _a, params = __objRest$m(_a, ["enabled"]);
35485
+ const _a = _params || {}, { enabled = true } = _a, params = __objRest$n(_a, ["enabled"]);
35474
35486
  return reactQuery.useQuery({
35475
35487
  enabled,
35476
35488
  onError,
@@ -35523,33 +35535,33 @@ const useCarrierConnectionsServicesList = (carrierCode) => {
35523
35535
  });
35524
35536
  };
35525
35537
 
35526
- var __defProp$u = Object.defineProperty;
35527
- var __defProps$r = Object.defineProperties;
35528
- var __getOwnPropDescs$r = Object.getOwnPropertyDescriptors;
35529
- var __getOwnPropSymbols$A = Object.getOwnPropertySymbols;
35530
- var __hasOwnProp$A = Object.prototype.hasOwnProperty;
35531
- var __propIsEnum$A = Object.prototype.propertyIsEnumerable;
35532
- var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35533
- var __spreadValues$u = (a, b) => {
35538
+ var __defProp$v = Object.defineProperty;
35539
+ var __defProps$s = Object.defineProperties;
35540
+ var __getOwnPropDescs$s = Object.getOwnPropertyDescriptors;
35541
+ var __getOwnPropSymbols$B = Object.getOwnPropertySymbols;
35542
+ var __hasOwnProp$B = Object.prototype.hasOwnProperty;
35543
+ var __propIsEnum$B = Object.prototype.propertyIsEnumerable;
35544
+ var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35545
+ var __spreadValues$v = (a, b) => {
35534
35546
  for (var prop in b || (b = {}))
35535
- if (__hasOwnProp$A.call(b, prop))
35536
- __defNormalProp$u(a, prop, b[prop]);
35537
- if (__getOwnPropSymbols$A)
35538
- for (var prop of __getOwnPropSymbols$A(b)) {
35539
- if (__propIsEnum$A.call(b, prop))
35540
- __defNormalProp$u(a, prop, b[prop]);
35547
+ if (__hasOwnProp$B.call(b, prop))
35548
+ __defNormalProp$v(a, prop, b[prop]);
35549
+ if (__getOwnPropSymbols$B)
35550
+ for (var prop of __getOwnPropSymbols$B(b)) {
35551
+ if (__propIsEnum$B.call(b, prop))
35552
+ __defNormalProp$v(a, prop, b[prop]);
35541
35553
  }
35542
35554
  return a;
35543
35555
  };
35544
- var __spreadProps$r = (a, b) => __defProps$r(a, __getOwnPropDescs$r(b));
35545
- var __objRest$l = (source, exclude) => {
35556
+ var __spreadProps$s = (a, b) => __defProps$s(a, __getOwnPropDescs$s(b));
35557
+ var __objRest$m = (source, exclude) => {
35546
35558
  var target = {};
35547
35559
  for (var prop in source)
35548
- if (__hasOwnProp$A.call(source, prop) && exclude.indexOf(prop) < 0)
35560
+ if (__hasOwnProp$B.call(source, prop) && exclude.indexOf(prop) < 0)
35549
35561
  target[prop] = source[prop];
35550
- if (source != null && __getOwnPropSymbols$A)
35551
- for (var prop of __getOwnPropSymbols$A(source)) {
35552
- if (exclude.indexOf(prop) < 0 && __propIsEnum$A.call(source, prop))
35562
+ if (source != null && __getOwnPropSymbols$B)
35563
+ for (var prop of __getOwnPropSymbols$B(source)) {
35564
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$B.call(source, prop))
35553
35565
  target[prop] = source[prop];
35554
35566
  }
35555
35567
  return target;
@@ -35557,12 +35569,12 @@ var __objRest$l = (source, exclude) => {
35557
35569
  const useGetConnectionsCarrierSettings = (_a) => {
35558
35570
  var _b = _a, {
35559
35571
  queryFnParams
35560
- } = _b, params = __objRest$l(_b, [
35572
+ } = _b, params = __objRest$m(_b, [
35561
35573
  "queryFnParams"
35562
35574
  ]);
35563
35575
  const { client } = useShipEngine();
35564
35576
  const { carrierName, carrierId } = queryFnParams;
35565
- return reactQuery.useQuery(__spreadProps$r(__spreadValues$u({}, params), {
35577
+ return reactQuery.useQuery(__spreadProps$s(__spreadValues$v({}, params), {
35566
35578
  onError,
35567
35579
  queryFn: () => client.connections.getCarrierSettings(carrierName, carrierId),
35568
35580
  queryKey: ["useGetConnectionsCarrierSettings", carrierName, carrierId],
@@ -35570,25 +35582,25 @@ const useGetConnectionsCarrierSettings = (_a) => {
35570
35582
  }));
35571
35583
  };
35572
35584
 
35573
- var __defProp$t = Object.defineProperty;
35574
- var __defProps$q = Object.defineProperties;
35575
- var __getOwnPropDescs$q = Object.getOwnPropertyDescriptors;
35576
- var __getOwnPropSymbols$z = Object.getOwnPropertySymbols;
35577
- var __hasOwnProp$z = Object.prototype.hasOwnProperty;
35578
- var __propIsEnum$z = Object.prototype.propertyIsEnumerable;
35579
- var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35580
- var __spreadValues$t = (a, b) => {
35585
+ var __defProp$u = Object.defineProperty;
35586
+ var __defProps$r = Object.defineProperties;
35587
+ var __getOwnPropDescs$r = Object.getOwnPropertyDescriptors;
35588
+ var __getOwnPropSymbols$A = Object.getOwnPropertySymbols;
35589
+ var __hasOwnProp$A = Object.prototype.hasOwnProperty;
35590
+ var __propIsEnum$A = Object.prototype.propertyIsEnumerable;
35591
+ var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35592
+ var __spreadValues$u = (a, b) => {
35581
35593
  for (var prop in b || (b = {}))
35582
- if (__hasOwnProp$z.call(b, prop))
35583
- __defNormalProp$t(a, prop, b[prop]);
35584
- if (__getOwnPropSymbols$z)
35585
- for (var prop of __getOwnPropSymbols$z(b)) {
35586
- if (__propIsEnum$z.call(b, prop))
35587
- __defNormalProp$t(a, prop, b[prop]);
35594
+ if (__hasOwnProp$A.call(b, prop))
35595
+ __defNormalProp$u(a, prop, b[prop]);
35596
+ if (__getOwnPropSymbols$A)
35597
+ for (var prop of __getOwnPropSymbols$A(b)) {
35598
+ if (__propIsEnum$A.call(b, prop))
35599
+ __defNormalProp$u(a, prop, b[prop]);
35588
35600
  }
35589
35601
  return a;
35590
35602
  };
35591
- var __spreadProps$q = (a, b) => __defProps$q(a, __getOwnPropDescs$q(b));
35603
+ var __spreadProps$r = (a, b) => __defProps$r(a, __getOwnPropDescs$r(b));
35592
35604
  var __async$I = (__this, __arguments, generator) => {
35593
35605
  return new Promise((resolve, reject) => {
35594
35606
  var fulfilled = (value) => {
@@ -35611,7 +35623,7 @@ var __async$I = (__this, __arguments, generator) => {
35611
35623
  };
35612
35624
  const useUpdateConnectionsCarrierSettings = (params) => {
35613
35625
  const { client } = useShipEngine();
35614
- return reactQuery.useMutation(__spreadProps$q(__spreadValues$t({}, params), {
35626
+ return reactQuery.useMutation(__spreadProps$r(__spreadValues$u({}, params), {
35615
35627
  mutationFn: (_0) => __async$I(void 0, [_0], function* ({
35616
35628
  carrierName,
35617
35629
  carrierId,
@@ -35819,29 +35831,29 @@ const useGetFundingSourceTransactions = (fundingSourceId, params) => {
35819
35831
  });
35820
35832
  };
35821
35833
 
35822
- var __defProp$s = Object.defineProperty;
35823
- var __defProps$p = Object.defineProperties;
35824
- var __getOwnPropDescs$p = Object.getOwnPropertyDescriptors;
35825
- var __getOwnPropSymbols$y = Object.getOwnPropertySymbols;
35826
- var __hasOwnProp$y = Object.prototype.hasOwnProperty;
35827
- var __propIsEnum$y = Object.prototype.propertyIsEnumerable;
35828
- var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35829
- var __spreadValues$s = (a, b) => {
35834
+ var __defProp$t = Object.defineProperty;
35835
+ var __defProps$q = Object.defineProperties;
35836
+ var __getOwnPropDescs$q = Object.getOwnPropertyDescriptors;
35837
+ var __getOwnPropSymbols$z = Object.getOwnPropertySymbols;
35838
+ var __hasOwnProp$z = Object.prototype.hasOwnProperty;
35839
+ var __propIsEnum$z = Object.prototype.propertyIsEnumerable;
35840
+ var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35841
+ var __spreadValues$t = (a, b) => {
35830
35842
  for (var prop in b || (b = {}))
35831
- if (__hasOwnProp$y.call(b, prop))
35832
- __defNormalProp$s(a, prop, b[prop]);
35833
- if (__getOwnPropSymbols$y)
35834
- for (var prop of __getOwnPropSymbols$y(b)) {
35835
- if (__propIsEnum$y.call(b, prop))
35836
- __defNormalProp$s(a, prop, b[prop]);
35843
+ if (__hasOwnProp$z.call(b, prop))
35844
+ __defNormalProp$t(a, prop, b[prop]);
35845
+ if (__getOwnPropSymbols$z)
35846
+ for (var prop of __getOwnPropSymbols$z(b)) {
35847
+ if (__propIsEnum$z.call(b, prop))
35848
+ __defNormalProp$t(a, prop, b[prop]);
35837
35849
  }
35838
35850
  return a;
35839
35851
  };
35840
- var __spreadProps$p = (a, b) => __defProps$p(a, __getOwnPropDescs$p(b));
35852
+ var __spreadProps$q = (a, b) => __defProps$q(a, __getOwnPropDescs$q(b));
35841
35853
  const useGetInsuranceFundingSourceAcceptedTerms = (params) => {
35842
35854
  const { client } = useShipEngine();
35843
- const queryParams = __spreadValues$s({}, params);
35844
- return reactQuery.useQuery(__spreadProps$p(__spreadValues$s({}, queryParams), {
35855
+ const queryParams = __spreadValues$t({}, params);
35856
+ return reactQuery.useQuery(__spreadProps$q(__spreadValues$t({}, queryParams), {
35845
35857
  onError,
35846
35858
  queryFn: () => client.fundingSources.insuranceAcceptedTerms(),
35847
35859
  queryKey: ["useGetInsuranceFundingSourceAcceptedTerms"],
@@ -35864,17 +35876,17 @@ const useGetInsuranceAccount = (insuranceProvider) => {
35864
35876
  });
35865
35877
  };
35866
35878
 
35867
- var __getOwnPropSymbols$x = Object.getOwnPropertySymbols;
35868
- var __hasOwnProp$x = Object.prototype.hasOwnProperty;
35869
- var __propIsEnum$x = Object.prototype.propertyIsEnumerable;
35870
- var __objRest$k = (source, exclude) => {
35879
+ var __getOwnPropSymbols$y = Object.getOwnPropertySymbols;
35880
+ var __hasOwnProp$y = Object.prototype.hasOwnProperty;
35881
+ var __propIsEnum$y = Object.prototype.propertyIsEnumerable;
35882
+ var __objRest$l = (source, exclude) => {
35871
35883
  var target = {};
35872
35884
  for (var prop in source)
35873
- if (__hasOwnProp$x.call(source, prop) && exclude.indexOf(prop) < 0)
35885
+ if (__hasOwnProp$y.call(source, prop) && exclude.indexOf(prop) < 0)
35874
35886
  target[prop] = source[prop];
35875
- if (source != null && __getOwnPropSymbols$x)
35876
- for (var prop of __getOwnPropSymbols$x(source)) {
35877
- if (exclude.indexOf(prop) < 0 && __propIsEnum$x.call(source, prop))
35887
+ if (source != null && __getOwnPropSymbols$y)
35888
+ for (var prop of __getOwnPropSymbols$y(source)) {
35889
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$y.call(source, prop))
35878
35890
  target[prop] = source[prop];
35879
35891
  }
35880
35892
  return target;
@@ -35903,7 +35915,7 @@ const useAddInsuranceFunds = () => {
35903
35915
  const { client } = useShipEngine();
35904
35916
  return reactQuery.useMutation({
35905
35917
  mutationFn: (_a) => __async$D(void 0, null, function* () {
35906
- var _b = _a, { insuranceProvider } = _b, rest = __objRest$k(_b, ["insuranceProvider"]);
35918
+ var _b = _a, { insuranceProvider } = _b, rest = __objRest$l(_b, ["insuranceProvider"]);
35907
35919
  const result = yield client.insurance.addFunds(insuranceProvider, rest);
35908
35920
  return result.data;
35909
35921
  }),
@@ -35912,25 +35924,25 @@ const useAddInsuranceFunds = () => {
35912
35924
  });
35913
35925
  };
35914
35926
 
35915
- var __defProp$r = Object.defineProperty;
35916
- var __defProps$o = Object.defineProperties;
35917
- var __getOwnPropDescs$o = Object.getOwnPropertyDescriptors;
35918
- var __getOwnPropSymbols$w = Object.getOwnPropertySymbols;
35919
- var __hasOwnProp$w = Object.prototype.hasOwnProperty;
35920
- var __propIsEnum$w = Object.prototype.propertyIsEnumerable;
35921
- var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35922
- var __spreadValues$r = (a, b) => {
35927
+ var __defProp$s = Object.defineProperty;
35928
+ var __defProps$p = Object.defineProperties;
35929
+ var __getOwnPropDescs$p = Object.getOwnPropertyDescriptors;
35930
+ var __getOwnPropSymbols$x = Object.getOwnPropertySymbols;
35931
+ var __hasOwnProp$x = Object.prototype.hasOwnProperty;
35932
+ var __propIsEnum$x = Object.prototype.propertyIsEnumerable;
35933
+ var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35934
+ var __spreadValues$s = (a, b) => {
35923
35935
  for (var prop in b || (b = {}))
35924
- if (__hasOwnProp$w.call(b, prop))
35925
- __defNormalProp$r(a, prop, b[prop]);
35926
- if (__getOwnPropSymbols$w)
35927
- for (var prop of __getOwnPropSymbols$w(b)) {
35928
- if (__propIsEnum$w.call(b, prop))
35929
- __defNormalProp$r(a, prop, b[prop]);
35936
+ if (__hasOwnProp$x.call(b, prop))
35937
+ __defNormalProp$s(a, prop, b[prop]);
35938
+ if (__getOwnPropSymbols$x)
35939
+ for (var prop of __getOwnPropSymbols$x(b)) {
35940
+ if (__propIsEnum$x.call(b, prop))
35941
+ __defNormalProp$s(a, prop, b[prop]);
35930
35942
  }
35931
35943
  return a;
35932
35944
  };
35933
- var __spreadProps$o = (a, b) => __defProps$o(a, __getOwnPropDescs$o(b));
35945
+ var __spreadProps$p = (a, b) => __defProps$p(a, __getOwnPropDescs$p(b));
35934
35946
  var __async$C = (__this, __arguments, generator) => {
35935
35947
  return new Promise((resolve, reject) => {
35936
35948
  var fulfilled = (value) => {
@@ -35953,7 +35965,7 @@ var __async$C = (__this, __arguments, generator) => {
35953
35965
  };
35954
35966
  const useCreateInvoiceAddress = (params) => {
35955
35967
  const { client } = useShipEngine();
35956
- return reactQuery.useMutation(__spreadProps$o(__spreadValues$r({}, params), {
35968
+ return reactQuery.useMutation(__spreadProps$p(__spreadValues$s({}, params), {
35957
35969
  mutationFn: (invoiceAddress) => __async$C(void 0, null, function* () {
35958
35970
  const result = yield client.invoiceAddress.create(invoiceAddress);
35959
35971
  return result.data;
@@ -35963,25 +35975,25 @@ const useCreateInvoiceAddress = (params) => {
35963
35975
  }));
35964
35976
  };
35965
35977
 
35966
- var __defProp$q = Object.defineProperty;
35967
- var __defProps$n = Object.defineProperties;
35968
- var __getOwnPropDescs$n = Object.getOwnPropertyDescriptors;
35969
- var __getOwnPropSymbols$v = Object.getOwnPropertySymbols;
35970
- var __hasOwnProp$v = Object.prototype.hasOwnProperty;
35971
- var __propIsEnum$v = Object.prototype.propertyIsEnumerable;
35972
- var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35973
- var __spreadValues$q = (a, b) => {
35978
+ var __defProp$r = Object.defineProperty;
35979
+ var __defProps$o = Object.defineProperties;
35980
+ var __getOwnPropDescs$o = Object.getOwnPropertyDescriptors;
35981
+ var __getOwnPropSymbols$w = Object.getOwnPropertySymbols;
35982
+ var __hasOwnProp$w = Object.prototype.hasOwnProperty;
35983
+ var __propIsEnum$w = Object.prototype.propertyIsEnumerable;
35984
+ var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
35985
+ var __spreadValues$r = (a, b) => {
35974
35986
  for (var prop in b || (b = {}))
35975
- if (__hasOwnProp$v.call(b, prop))
35976
- __defNormalProp$q(a, prop, b[prop]);
35977
- if (__getOwnPropSymbols$v)
35978
- for (var prop of __getOwnPropSymbols$v(b)) {
35979
- if (__propIsEnum$v.call(b, prop))
35980
- __defNormalProp$q(a, prop, b[prop]);
35987
+ if (__hasOwnProp$w.call(b, prop))
35988
+ __defNormalProp$r(a, prop, b[prop]);
35989
+ if (__getOwnPropSymbols$w)
35990
+ for (var prop of __getOwnPropSymbols$w(b)) {
35991
+ if (__propIsEnum$w.call(b, prop))
35992
+ __defNormalProp$r(a, prop, b[prop]);
35981
35993
  }
35982
35994
  return a;
35983
35995
  };
35984
- var __spreadProps$n = (a, b) => __defProps$n(a, __getOwnPropDescs$n(b));
35996
+ var __spreadProps$o = (a, b) => __defProps$o(a, __getOwnPropDescs$o(b));
35985
35997
  var __async$B = (__this, __arguments, generator) => {
35986
35998
  return new Promise((resolve, reject) => {
35987
35999
  var fulfilled = (value) => {
@@ -36004,7 +36016,7 @@ var __async$B = (__this, __arguments, generator) => {
36004
36016
  };
36005
36017
  const useUpdateInvoiceAddress = (params) => {
36006
36018
  const { client } = useShipEngine();
36007
- return reactQuery.useMutation(__spreadProps$n(__spreadValues$q({}, params), {
36019
+ return reactQuery.useMutation(__spreadProps$o(__spreadValues$r({}, params), {
36008
36020
  mutationFn: (invoiceAddress) => __async$B(void 0, null, function* () {
36009
36021
  const result = yield client.invoiceAddress.update(invoiceAddress);
36010
36022
  return result.data;
@@ -36014,6 +36026,35 @@ const useUpdateInvoiceAddress = (params) => {
36014
36026
  }));
36015
36027
  };
36016
36028
 
36029
+ var __defProp$q = Object.defineProperty;
36030
+ var __defProps$n = Object.defineProperties;
36031
+ var __getOwnPropDescs$n = Object.getOwnPropertyDescriptors;
36032
+ var __getOwnPropSymbols$v = Object.getOwnPropertySymbols;
36033
+ var __hasOwnProp$v = Object.prototype.hasOwnProperty;
36034
+ var __propIsEnum$v = Object.prototype.propertyIsEnumerable;
36035
+ var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
36036
+ var __spreadValues$q = (a, b) => {
36037
+ for (var prop in b || (b = {}))
36038
+ if (__hasOwnProp$v.call(b, prop))
36039
+ __defNormalProp$q(a, prop, b[prop]);
36040
+ if (__getOwnPropSymbols$v)
36041
+ for (var prop of __getOwnPropSymbols$v(b)) {
36042
+ if (__propIsEnum$v.call(b, prop))
36043
+ __defNormalProp$q(a, prop, b[prop]);
36044
+ }
36045
+ return a;
36046
+ };
36047
+ var __spreadProps$n = (a, b) => __defProps$n(a, __getOwnPropDescs$n(b));
36048
+ const useGetInvoiceAddress = (params) => {
36049
+ const { client } = useShipEngine();
36050
+ return reactQuery.useQuery(__spreadProps$n(__spreadValues$q({}, params), {
36051
+ onError,
36052
+ queryFn: () => client.invoiceAddress.get(),
36053
+ queryKey: ["useGetInvoiceAddress"],
36054
+ select: (result) => result.data
36055
+ }));
36056
+ };
36057
+
36017
36058
  var __defProp$p = Object.defineProperty;
36018
36059
  var __defProps$m = Object.defineProperties;
36019
36060
  var __getOwnPropDescs$m = Object.getOwnPropertyDescriptors;
@@ -36033,13 +36074,48 @@ var __spreadValues$p = (a, b) => {
36033
36074
  return a;
36034
36075
  };
36035
36076
  var __spreadProps$m = (a, b) => __defProps$m(a, __getOwnPropDescs$m(b));
36036
- const useGetInvoiceAddress = (params) => {
36077
+ var __objRest$k = (source, exclude) => {
36078
+ var target = {};
36079
+ for (var prop in source)
36080
+ if (__hasOwnProp$u.call(source, prop) && exclude.indexOf(prop) < 0)
36081
+ target[prop] = source[prop];
36082
+ if (source != null && __getOwnPropSymbols$u)
36083
+ for (var prop of __getOwnPropSymbols$u(source)) {
36084
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$u.call(source, prop))
36085
+ target[prop] = source[prop];
36086
+ }
36087
+ return target;
36088
+ };
36089
+ var __async$A = (__this, __arguments, generator) => {
36090
+ return new Promise((resolve, reject) => {
36091
+ var fulfilled = (value) => {
36092
+ try {
36093
+ step(generator.next(value));
36094
+ } catch (e) {
36095
+ reject(e);
36096
+ }
36097
+ };
36098
+ var rejected = (value) => {
36099
+ try {
36100
+ step(generator.throw(value));
36101
+ } catch (e) {
36102
+ reject(e);
36103
+ }
36104
+ };
36105
+ var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
36106
+ step((generator = generator.apply(__this, __arguments)).next());
36107
+ });
36108
+ };
36109
+ const useCreateLabelByRateId = (params) => {
36037
36110
  const { client } = useShipEngine();
36038
- return reactQuery.useQuery(__spreadProps$m(__spreadValues$p({}, params), {
36039
- onError,
36040
- queryFn: () => client.invoiceAddress.get(),
36041
- queryKey: ["useGetInvoiceAddress"],
36042
- select: (result) => result.data
36111
+ return reactQuery.useMutation(__spreadProps$m(__spreadValues$p({}, params), {
36112
+ mutationFn: (_a) => __async$A(void 0, null, function* () {
36113
+ var _b = _a, { rateId } = _b, options = __objRest$k(_b, ["rateId"]);
36114
+ const result = yield client.labels.createByRateId(rateId, options);
36115
+ return result.data;
36116
+ }),
36117
+ mutationKey: ["useCreateLabelByRateId"],
36118
+ onError
36043
36119
  }));
36044
36120
  };
36045
36121
 
@@ -36074,7 +36150,7 @@ var __objRest$j = (source, exclude) => {
36074
36150
  }
36075
36151
  return target;
36076
36152
  };
36077
- var __async$A = (__this, __arguments, generator) => {
36153
+ var __async$z = (__this, __arguments, generator) => {
36078
36154
  return new Promise((resolve, reject) => {
36079
36155
  var fulfilled = (value) => {
36080
36156
  try {
@@ -36094,15 +36170,15 @@ var __async$A = (__this, __arguments, generator) => {
36094
36170
  step((generator = generator.apply(__this, __arguments)).next());
36095
36171
  });
36096
36172
  };
36097
- const useCreateLabelByRateId = (params) => {
36173
+ const useCreateLabelByShipmentId = (params) => {
36098
36174
  const { client } = useShipEngine();
36099
36175
  return reactQuery.useMutation(__spreadProps$l(__spreadValues$o({}, params), {
36100
- mutationFn: (_a) => __async$A(void 0, null, function* () {
36101
- var _b = _a, { rateId } = _b, options = __objRest$j(_b, ["rateId"]);
36102
- const result = yield client.labels.createByRateId(rateId, options);
36176
+ mutationFn: (_a) => __async$z(void 0, null, function* () {
36177
+ var _b = _a, { shipmentId } = _b, options = __objRest$j(_b, ["shipmentId"]);
36178
+ const result = yield client.labels.createByShipmentId(shipmentId, options);
36103
36179
  return result.data;
36104
36180
  }),
36105
- mutationKey: ["useCreateLabelByRateId"],
36181
+ mutationKey: ["useCreateLabelByShipmentId"],
36106
36182
  onError
36107
36183
  }));
36108
36184
  };
@@ -36138,7 +36214,7 @@ var __objRest$i = (source, exclude) => {
36138
36214
  }
36139
36215
  return target;
36140
36216
  };
36141
- var __async$z = (__this, __arguments, generator) => {
36217
+ var __async$y = (__this, __arguments, generator) => {
36142
36218
  return new Promise((resolve, reject) => {
36143
36219
  var fulfilled = (value) => {
36144
36220
  try {
@@ -36158,19 +36234,34 @@ var __async$z = (__this, __arguments, generator) => {
36158
36234
  step((generator = generator.apply(__this, __arguments)).next());
36159
36235
  });
36160
36236
  };
36161
- const useCreateLabelByShipmentId = (params) => {
36237
+ const useCreateLabel = (params) => {
36162
36238
  const { client } = useShipEngine();
36163
36239
  return reactQuery.useMutation(__spreadProps$k(__spreadValues$n({}, params), {
36164
- mutationFn: (_a) => __async$z(void 0, null, function* () {
36165
- var _b = _a, { shipmentId } = _b, options = __objRest$i(_b, ["shipmentId"]);
36166
- const result = yield client.labels.createByShipmentId(shipmentId, options);
36240
+ mutationFn: (_a) => __async$y(void 0, null, function* () {
36241
+ var _b = _a, { rateId } = _b, options = __objRest$i(_b, ["rateId"]);
36242
+ const result = yield client.labels.createByRateId(rateId, options);
36167
36243
  return result.data;
36168
36244
  }),
36169
- mutationKey: ["useCreateLabelByShipmentId"],
36245
+ mutationKey: ["useCreateLabel"],
36170
36246
  onError
36171
36247
  }));
36172
36248
  };
36173
36249
 
36250
+ const useGetLabel = (labelId) => {
36251
+ const { client } = useShipEngine();
36252
+ return reactQuery.useQuery({
36253
+ enabled: labelId !== void 0,
36254
+ onError,
36255
+ queryFn: () => {
36256
+ if (labelId)
36257
+ return client.labels.get(labelId);
36258
+ return Promise.reject(new Error("labelId is require"));
36259
+ },
36260
+ queryKey: ["useGetLabel", labelId],
36261
+ select: (result) => result.data
36262
+ });
36263
+ };
36264
+
36174
36265
  var __defProp$m = Object.defineProperty;
36175
36266
  var __defProps$j = Object.defineProperties;
36176
36267
  var __getOwnPropDescs$j = Object.getOwnPropertyDescriptors;
@@ -36202,7 +36293,18 @@ var __objRest$h = (source, exclude) => {
36202
36293
  }
36203
36294
  return target;
36204
36295
  };
36205
- var __async$y = (__this, __arguments, generator) => {
36296
+ const useListLabels = (params) => {
36297
+ const { client } = useShipEngine();
36298
+ const _a = __spreadValues$m({}, params), { queryFnParams } = _a, rest = __objRest$h(_a, ["queryFnParams"]);
36299
+ return reactQuery.useQuery(__spreadProps$j(__spreadValues$m({}, rest), {
36300
+ onError,
36301
+ queryFn: () => client.labels.list(queryFnParams),
36302
+ queryKey: ["useListLabels", params],
36303
+ select: (result) => result.data
36304
+ }));
36305
+ };
36306
+
36307
+ var __async$x = (__this, __arguments, generator) => {
36206
36308
  return new Promise((resolve, reject) => {
36207
36309
  var fulfilled = (value) => {
36208
36310
  try {
@@ -36222,31 +36324,15 @@ var __async$y = (__this, __arguments, generator) => {
36222
36324
  step((generator = generator.apply(__this, __arguments)).next());
36223
36325
  });
36224
36326
  };
36225
- const useCreateLabel = (params) => {
36327
+ const useVoidLabel = () => {
36226
36328
  const { client } = useShipEngine();
36227
- return reactQuery.useMutation(__spreadProps$j(__spreadValues$m({}, params), {
36228
- mutationFn: (_a) => __async$y(void 0, null, function* () {
36229
- var _b = _a, { rateId } = _b, options = __objRest$h(_b, ["rateId"]);
36230
- const result = yield client.labels.createByRateId(rateId, options);
36329
+ return reactQuery.useMutation({
36330
+ mutationFn: (labelId) => __async$x(void 0, null, function* () {
36331
+ const result = yield client.labels.void(labelId);
36231
36332
  return result.data;
36232
36333
  }),
36233
- mutationKey: ["useCreateLabel"],
36334
+ mutationKey: ["useVoidLabel"],
36234
36335
  onError
36235
- }));
36236
- };
36237
-
36238
- const useGetLabel = (labelId) => {
36239
- const { client } = useShipEngine();
36240
- return reactQuery.useQuery({
36241
- enabled: labelId !== void 0,
36242
- onError,
36243
- queryFn: () => {
36244
- if (labelId)
36245
- return client.labels.get(labelId);
36246
- return Promise.reject(new Error("labelId is require"));
36247
- },
36248
- queryKey: ["useGetLabel", labelId],
36249
- select: (result) => result.data
36250
36336
  });
36251
36337
  };
36252
36338
 
@@ -36281,80 +36367,6 @@ var __objRest$g = (source, exclude) => {
36281
36367
  }
36282
36368
  return target;
36283
36369
  };
36284
- const useListLabels = (params) => {
36285
- const { client } = useShipEngine();
36286
- const _a = __spreadValues$l({}, params), { queryFnParams } = _a, rest = __objRest$g(_a, ["queryFnParams"]);
36287
- return reactQuery.useQuery(__spreadProps$i(__spreadValues$l({}, rest), {
36288
- onError,
36289
- queryFn: () => client.labels.list(queryFnParams),
36290
- queryKey: ["useListLabels", params],
36291
- select: (result) => result.data
36292
- }));
36293
- };
36294
-
36295
- var __async$x = (__this, __arguments, generator) => {
36296
- return new Promise((resolve, reject) => {
36297
- var fulfilled = (value) => {
36298
- try {
36299
- step(generator.next(value));
36300
- } catch (e) {
36301
- reject(e);
36302
- }
36303
- };
36304
- var rejected = (value) => {
36305
- try {
36306
- step(generator.throw(value));
36307
- } catch (e) {
36308
- reject(e);
36309
- }
36310
- };
36311
- var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
36312
- step((generator = generator.apply(__this, __arguments)).next());
36313
- });
36314
- };
36315
- const useVoidLabel = () => {
36316
- const { client } = useShipEngine();
36317
- return reactQuery.useMutation({
36318
- mutationFn: (labelId) => __async$x(void 0, null, function* () {
36319
- const result = yield client.labels.void(labelId);
36320
- return result.data;
36321
- }),
36322
- mutationKey: ["useVoidLabel"],
36323
- onError
36324
- });
36325
- };
36326
-
36327
- var __defProp$k = Object.defineProperty;
36328
- var __defProps$h = Object.defineProperties;
36329
- var __getOwnPropDescs$h = Object.getOwnPropertyDescriptors;
36330
- var __getOwnPropSymbols$p = Object.getOwnPropertySymbols;
36331
- var __hasOwnProp$p = Object.prototype.hasOwnProperty;
36332
- var __propIsEnum$p = Object.prototype.propertyIsEnumerable;
36333
- var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
36334
- var __spreadValues$k = (a, b) => {
36335
- for (var prop in b || (b = {}))
36336
- if (__hasOwnProp$p.call(b, prop))
36337
- __defNormalProp$k(a, prop, b[prop]);
36338
- if (__getOwnPropSymbols$p)
36339
- for (var prop of __getOwnPropSymbols$p(b)) {
36340
- if (__propIsEnum$p.call(b, prop))
36341
- __defNormalProp$k(a, prop, b[prop]);
36342
- }
36343
- return a;
36344
- };
36345
- var __spreadProps$h = (a, b) => __defProps$h(a, __getOwnPropDescs$h(b));
36346
- var __objRest$f = (source, exclude) => {
36347
- var target = {};
36348
- for (var prop in source)
36349
- if (__hasOwnProp$p.call(source, prop) && exclude.indexOf(prop) < 0)
36350
- target[prop] = source[prop];
36351
- if (source != null && __getOwnPropSymbols$p)
36352
- for (var prop of __getOwnPropSymbols$p(source)) {
36353
- if (exclude.indexOf(prop) < 0 && __propIsEnum$p.call(source, prop))
36354
- target[prop] = source[prop];
36355
- }
36356
- return target;
36357
- };
36358
36370
  var __async$w = (__this, __arguments, generator) => {
36359
36371
  return new Promise((resolve, reject) => {
36360
36372
  var fulfilled = (value) => {
@@ -36377,8 +36389,8 @@ var __async$w = (__this, __arguments, generator) => {
36377
36389
  };
36378
36390
  const useListLabelsInfinite = (params) => {
36379
36391
  const { client } = useShipEngine();
36380
- const _a = __spreadValues$k({}, params), { queryFnParams } = _a, rest = __objRest$f(_a, ["queryFnParams"]);
36381
- return reactQuery.useInfiniteQuery(__spreadProps$h(__spreadValues$k({}, rest), {
36392
+ const _a = __spreadValues$l({}, params), { queryFnParams } = _a, rest = __objRest$g(_a, ["queryFnParams"]);
36393
+ return reactQuery.useInfiniteQuery(__spreadProps$i(__spreadValues$l({}, rest), {
36382
36394
  getNextPageParam: (lastPage) => {
36383
36395
  if (lastPage.page < lastPage.pages) {
36384
36396
  return lastPage.page + 1;
@@ -36387,7 +36399,7 @@ const useListLabelsInfinite = (params) => {
36387
36399
  },
36388
36400
  onError,
36389
36401
  queryFn: (_0) => __async$w(void 0, [_0], function* ({ pageParam = 1 }) {
36390
- const response = yield client.labels.list(__spreadProps$h(__spreadValues$k({}, queryFnParams), { page: pageParam }));
36402
+ const response = yield client.labels.list(__spreadProps$i(__spreadValues$l({}, queryFnParams), { page: pageParam }));
36391
36403
  return response.data;
36392
36404
  }),
36393
36405
  queryKey: ["useListLabelsInfinite", params],
@@ -36401,69 +36413,69 @@ const useListLabelsInfinite = (params) => {
36401
36413
  }));
36402
36414
  };
36403
36415
 
36404
- var __defProp$j = Object.defineProperty;
36405
- var __defProps$g = Object.defineProperties;
36406
- var __getOwnPropDescs$g = Object.getOwnPropertyDescriptors;
36407
- var __getOwnPropSymbols$o = Object.getOwnPropertySymbols;
36408
- var __hasOwnProp$o = Object.prototype.hasOwnProperty;
36409
- var __propIsEnum$o = Object.prototype.propertyIsEnumerable;
36410
- var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
36411
- var __spreadValues$j = (a, b) => {
36416
+ var __defProp$k = Object.defineProperty;
36417
+ var __defProps$h = Object.defineProperties;
36418
+ var __getOwnPropDescs$h = Object.getOwnPropertyDescriptors;
36419
+ var __getOwnPropSymbols$p = Object.getOwnPropertySymbols;
36420
+ var __hasOwnProp$p = Object.prototype.hasOwnProperty;
36421
+ var __propIsEnum$p = Object.prototype.propertyIsEnumerable;
36422
+ var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
36423
+ var __spreadValues$k = (a, b) => {
36412
36424
  for (var prop in b || (b = {}))
36413
- if (__hasOwnProp$o.call(b, prop))
36414
- __defNormalProp$j(a, prop, b[prop]);
36415
- if (__getOwnPropSymbols$o)
36416
- for (var prop of __getOwnPropSymbols$o(b)) {
36417
- if (__propIsEnum$o.call(b, prop))
36418
- __defNormalProp$j(a, prop, b[prop]);
36425
+ if (__hasOwnProp$p.call(b, prop))
36426
+ __defNormalProp$k(a, prop, b[prop]);
36427
+ if (__getOwnPropSymbols$p)
36428
+ for (var prop of __getOwnPropSymbols$p(b)) {
36429
+ if (__propIsEnum$p.call(b, prop))
36430
+ __defNormalProp$k(a, prop, b[prop]);
36419
36431
  }
36420
36432
  return a;
36421
36433
  };
36422
- var __spreadProps$g = (a, b) => __defProps$g(a, __getOwnPropDescs$g(b));
36423
- var __objRest$e = (source, exclude) => {
36434
+ var __spreadProps$h = (a, b) => __defProps$h(a, __getOwnPropDescs$h(b));
36435
+ var __objRest$f = (source, exclude) => {
36424
36436
  var target = {};
36425
36437
  for (var prop in source)
36426
- if (__hasOwnProp$o.call(source, prop) && exclude.indexOf(prop) < 0)
36438
+ if (__hasOwnProp$p.call(source, prop) && exclude.indexOf(prop) < 0)
36427
36439
  target[prop] = source[prop];
36428
- if (source != null && __getOwnPropSymbols$o)
36429
- for (var prop of __getOwnPropSymbols$o(source)) {
36430
- if (exclude.indexOf(prop) < 0 && __propIsEnum$o.call(source, prop))
36440
+ if (source != null && __getOwnPropSymbols$p)
36441
+ for (var prop of __getOwnPropSymbols$p(source)) {
36442
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$p.call(source, prop))
36431
36443
  target[prop] = source[prop];
36432
36444
  }
36433
36445
  return target;
36434
36446
  };
36435
36447
  const useDownloadLabels = (params) => {
36436
36448
  const { client } = useShipEngine();
36437
- const _a = __spreadValues$j({}, params), { queryFnParams } = _a, rest = __objRest$e(_a, ["queryFnParams"]);
36438
- return reactQuery.useQuery(__spreadProps$g(__spreadValues$j({}, rest), {
36449
+ const _a = __spreadValues$k({}, params), { queryFnParams } = _a, rest = __objRest$f(_a, ["queryFnParams"]);
36450
+ return reactQuery.useQuery(__spreadProps$h(__spreadValues$k({}, rest), {
36439
36451
  onError,
36440
36452
  queryFn: () => client.labels.download(queryFnParams),
36441
36453
  queryKey: ["useDownloadLabels", params]
36442
36454
  }));
36443
36455
  };
36444
36456
 
36445
- var __defProp$i = Object.defineProperty;
36446
- var __defProps$f = Object.defineProperties;
36447
- var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
36448
- var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
36449
- var __hasOwnProp$n = Object.prototype.hasOwnProperty;
36450
- var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
36451
- var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
36452
- var __spreadValues$i = (a, b) => {
36457
+ var __defProp$j = Object.defineProperty;
36458
+ var __defProps$g = Object.defineProperties;
36459
+ var __getOwnPropDescs$g = Object.getOwnPropertyDescriptors;
36460
+ var __getOwnPropSymbols$o = Object.getOwnPropertySymbols;
36461
+ var __hasOwnProp$o = Object.prototype.hasOwnProperty;
36462
+ var __propIsEnum$o = Object.prototype.propertyIsEnumerable;
36463
+ var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
36464
+ var __spreadValues$j = (a, b) => {
36453
36465
  for (var prop in b || (b = {}))
36454
- if (__hasOwnProp$n.call(b, prop))
36455
- __defNormalProp$i(a, prop, b[prop]);
36456
- if (__getOwnPropSymbols$n)
36457
- for (var prop of __getOwnPropSymbols$n(b)) {
36458
- if (__propIsEnum$n.call(b, prop))
36459
- __defNormalProp$i(a, prop, b[prop]);
36466
+ if (__hasOwnProp$o.call(b, prop))
36467
+ __defNormalProp$j(a, prop, b[prop]);
36468
+ if (__getOwnPropSymbols$o)
36469
+ for (var prop of __getOwnPropSymbols$o(b)) {
36470
+ if (__propIsEnum$o.call(b, prop))
36471
+ __defNormalProp$j(a, prop, b[prop]);
36460
36472
  }
36461
36473
  return a;
36462
36474
  };
36463
- var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
36475
+ var __spreadProps$g = (a, b) => __defProps$g(a, __getOwnPropDescs$g(b));
36464
36476
  const useListOrderSources = (params) => {
36465
36477
  const { client } = useShipEngine();
36466
- return reactQuery.useQuery(__spreadProps$f(__spreadValues$i({}, params), {
36478
+ return reactQuery.useQuery(__spreadProps$g(__spreadValues$j({}, params), {
36467
36479
  onError,
36468
36480
  queryFn: () => client.orderSources.list(),
36469
36481
  queryKey: ["useListOrderSources"],
@@ -36901,17 +36913,17 @@ const useListSalesOrders = (params = {}) => {
36901
36913
  });
36902
36914
  };
36903
36915
 
36904
- var __getOwnPropSymbols$m = Object.getOwnPropertySymbols;
36905
- var __hasOwnProp$m = Object.prototype.hasOwnProperty;
36906
- var __propIsEnum$m = Object.prototype.propertyIsEnumerable;
36907
- var __objRest$d = (source, exclude) => {
36916
+ var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
36917
+ var __hasOwnProp$n = Object.prototype.hasOwnProperty;
36918
+ var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
36919
+ var __objRest$e = (source, exclude) => {
36908
36920
  var target = {};
36909
36921
  for (var prop in source)
36910
- if (__hasOwnProp$m.call(source, prop) && exclude.indexOf(prop) < 0)
36922
+ if (__hasOwnProp$n.call(source, prop) && exclude.indexOf(prop) < 0)
36911
36923
  target[prop] = source[prop];
36912
- if (source != null && __getOwnPropSymbols$m)
36913
- for (var prop of __getOwnPropSymbols$m(source)) {
36914
- if (exclude.indexOf(prop) < 0 && __propIsEnum$m.call(source, prop))
36924
+ if (source != null && __getOwnPropSymbols$n)
36925
+ for (var prop of __getOwnPropSymbols$n(source)) {
36926
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$n.call(source, prop))
36915
36927
  target[prop] = source[prop];
36916
36928
  }
36917
36929
  return target;
@@ -36940,7 +36952,7 @@ const useNotifySalesOrderShipped = () => {
36940
36952
  const { client } = useShipEngine();
36941
36953
  return reactQuery.useMutation({
36942
36954
  mutationFn: (_a) => __async$l(void 0, null, function* () {
36943
- var _b = _a, { salesOrderId } = _b, tracking = __objRest$d(_b, ["salesOrderId"]);
36955
+ var _b = _a, { salesOrderId } = _b, tracking = __objRest$e(_b, ["salesOrderId"]);
36944
36956
  const result = yield client.salesOrders.notifyShipped(salesOrderId, tracking);
36945
36957
  return result.data;
36946
36958
  }),
@@ -36949,17 +36961,17 @@ const useNotifySalesOrderShipped = () => {
36949
36961
  });
36950
36962
  };
36951
36963
 
36952
- var __getOwnPropSymbols$l = Object.getOwnPropertySymbols;
36953
- var __hasOwnProp$l = Object.prototype.hasOwnProperty;
36954
- var __propIsEnum$l = Object.prototype.propertyIsEnumerable;
36955
- var __objRest$c = (source, exclude) => {
36964
+ var __getOwnPropSymbols$m = Object.getOwnPropertySymbols;
36965
+ var __hasOwnProp$m = Object.prototype.hasOwnProperty;
36966
+ var __propIsEnum$m = Object.prototype.propertyIsEnumerable;
36967
+ var __objRest$d = (source, exclude) => {
36956
36968
  var target = {};
36957
36969
  for (var prop in source)
36958
- if (__hasOwnProp$l.call(source, prop) && exclude.indexOf(prop) < 0)
36970
+ if (__hasOwnProp$m.call(source, prop) && exclude.indexOf(prop) < 0)
36959
36971
  target[prop] = source[prop];
36960
- if (source != null && __getOwnPropSymbols$l)
36961
- for (var prop of __getOwnPropSymbols$l(source)) {
36962
- if (exclude.indexOf(prop) < 0 && __propIsEnum$l.call(source, prop))
36972
+ if (source != null && __getOwnPropSymbols$m)
36973
+ for (var prop of __getOwnPropSymbols$m(source)) {
36974
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$m.call(source, prop))
36963
36975
  target[prop] = source[prop];
36964
36976
  }
36965
36977
  return target;
@@ -36988,7 +37000,7 @@ const useCreateSalesOrderShipment = () => {
36988
37000
  const { client } = useShipEngine();
36989
37001
  return reactQuery.useMutation({
36990
37002
  mutationFn: (_a) => __async$k(void 0, null, function* () {
36991
- var _b = _a, { salesOrderId } = _b, shipment = __objRest$c(_b, ["salesOrderId"]);
37003
+ var _b = _a, { salesOrderId } = _b, shipment = __objRest$d(_b, ["salesOrderId"]);
36992
37004
  const result = yield client.salesOrderShipments.create(salesOrderId, shipment);
36993
37005
  return result.data;
36994
37006
  }),
@@ -37024,17 +37036,17 @@ const useListSalesOrderShipments = (body) => {
37024
37036
  });
37025
37037
  };
37026
37038
 
37027
- var __getOwnPropSymbols$k = Object.getOwnPropertySymbols;
37028
- var __hasOwnProp$k = Object.prototype.hasOwnProperty;
37029
- var __propIsEnum$k = Object.prototype.propertyIsEnumerable;
37030
- var __objRest$b = (source, exclude) => {
37039
+ var __getOwnPropSymbols$l = Object.getOwnPropertySymbols;
37040
+ var __hasOwnProp$l = Object.prototype.hasOwnProperty;
37041
+ var __propIsEnum$l = Object.prototype.propertyIsEnumerable;
37042
+ var __objRest$c = (source, exclude) => {
37031
37043
  var target = {};
37032
37044
  for (var prop in source)
37033
- if (__hasOwnProp$k.call(source, prop) && exclude.indexOf(prop) < 0)
37045
+ if (__hasOwnProp$l.call(source, prop) && exclude.indexOf(prop) < 0)
37034
37046
  target[prop] = source[prop];
37035
- if (source != null && __getOwnPropSymbols$k)
37036
- for (var prop of __getOwnPropSymbols$k(source)) {
37037
- if (exclude.indexOf(prop) < 0 && __propIsEnum$k.call(source, prop))
37047
+ if (source != null && __getOwnPropSymbols$l)
37048
+ for (var prop of __getOwnPropSymbols$l(source)) {
37049
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$l.call(source, prop))
37038
37050
  target[prop] = source[prop];
37039
37051
  }
37040
37052
  return target;
@@ -37063,7 +37075,7 @@ const useUpdateSalesOrderShipment = () => {
37063
37075
  const { client } = useShipEngine();
37064
37076
  return reactQuery.useMutation({
37065
37077
  mutationFn: (_a) => __async$j(void 0, null, function* () {
37066
- var _b = _a, { shipmentId } = _b, shipment = __objRest$b(_b, ["shipmentId"]);
37078
+ var _b = _a, { shipmentId } = _b, shipment = __objRest$c(_b, ["shipmentId"]);
37067
37079
  const result = yield client.salesOrderShipments.update(shipmentId, shipment);
37068
37080
  return result.data;
37069
37081
  }),
@@ -37083,25 +37095,25 @@ const useListSalesOrderShipmentsByExternalOrderId = (externalOrderId) => {
37083
37095
  });
37084
37096
  };
37085
37097
 
37086
- var __defProp$h = Object.defineProperty;
37087
- var __defProps$e = Object.defineProperties;
37088
- var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
37089
- var __getOwnPropSymbols$j = Object.getOwnPropertySymbols;
37090
- var __hasOwnProp$j = Object.prototype.hasOwnProperty;
37091
- var __propIsEnum$j = Object.prototype.propertyIsEnumerable;
37092
- var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37093
- var __spreadValues$h = (a, b) => {
37098
+ var __defProp$i = Object.defineProperty;
37099
+ var __defProps$f = Object.defineProperties;
37100
+ var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
37101
+ var __getOwnPropSymbols$k = Object.getOwnPropertySymbols;
37102
+ var __hasOwnProp$k = Object.prototype.hasOwnProperty;
37103
+ var __propIsEnum$k = Object.prototype.propertyIsEnumerable;
37104
+ var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37105
+ var __spreadValues$i = (a, b) => {
37094
37106
  for (var prop in b || (b = {}))
37095
- if (__hasOwnProp$j.call(b, prop))
37096
- __defNormalProp$h(a, prop, b[prop]);
37097
- if (__getOwnPropSymbols$j)
37098
- for (var prop of __getOwnPropSymbols$j(b)) {
37099
- if (__propIsEnum$j.call(b, prop))
37100
- __defNormalProp$h(a, prop, b[prop]);
37107
+ if (__hasOwnProp$k.call(b, prop))
37108
+ __defNormalProp$i(a, prop, b[prop]);
37109
+ if (__getOwnPropSymbols$k)
37110
+ for (var prop of __getOwnPropSymbols$k(b)) {
37111
+ if (__propIsEnum$k.call(b, prop))
37112
+ __defNormalProp$i(a, prop, b[prop]);
37101
37113
  }
37102
37114
  return a;
37103
37115
  };
37104
- var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
37116
+ var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
37105
37117
  var __async$i = (__this, __arguments, generator) => {
37106
37118
  return new Promise((resolve, reject) => {
37107
37119
  var fulfilled = (value) => {
@@ -37143,7 +37155,7 @@ const useCreateShipment = () => {
37143
37155
  postalCode: "",
37144
37156
  stateProvince: ""
37145
37157
  };
37146
- return (yield client.shipments.create(__spreadProps$e(__spreadValues$h({}, shipment), {
37158
+ return (yield client.shipments.create(__spreadProps$f(__spreadValues$i({}, shipment), {
37147
37159
  shipTo
37148
37160
  }))).data;
37149
37161
  }),
@@ -37152,43 +37164,43 @@ const useCreateShipment = () => {
37152
37164
  });
37153
37165
  };
37154
37166
 
37155
- var __defProp$g = Object.defineProperty;
37156
- var __defProps$d = Object.defineProperties;
37157
- var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
37158
- var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
37159
- var __hasOwnProp$i = Object.prototype.hasOwnProperty;
37160
- var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
37161
- var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37162
- var __spreadValues$g = (a, b) => {
37167
+ var __defProp$h = Object.defineProperty;
37168
+ var __defProps$e = Object.defineProperties;
37169
+ var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
37170
+ var __getOwnPropSymbols$j = Object.getOwnPropertySymbols;
37171
+ var __hasOwnProp$j = Object.prototype.hasOwnProperty;
37172
+ var __propIsEnum$j = Object.prototype.propertyIsEnumerable;
37173
+ var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37174
+ var __spreadValues$h = (a, b) => {
37163
37175
  for (var prop in b || (b = {}))
37164
- if (__hasOwnProp$i.call(b, prop))
37165
- __defNormalProp$g(a, prop, b[prop]);
37166
- if (__getOwnPropSymbols$i)
37167
- for (var prop of __getOwnPropSymbols$i(b)) {
37168
- if (__propIsEnum$i.call(b, prop))
37169
- __defNormalProp$g(a, prop, b[prop]);
37176
+ if (__hasOwnProp$j.call(b, prop))
37177
+ __defNormalProp$h(a, prop, b[prop]);
37178
+ if (__getOwnPropSymbols$j)
37179
+ for (var prop of __getOwnPropSymbols$j(b)) {
37180
+ if (__propIsEnum$j.call(b, prop))
37181
+ __defNormalProp$h(a, prop, b[prop]);
37170
37182
  }
37171
37183
  return a;
37172
37184
  };
37173
- var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
37174
- var __objRest$a = (source, exclude) => {
37185
+ var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
37186
+ var __objRest$b = (source, exclude) => {
37175
37187
  var target = {};
37176
37188
  for (var prop in source)
37177
- if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0)
37189
+ if (__hasOwnProp$j.call(source, prop) && exclude.indexOf(prop) < 0)
37178
37190
  target[prop] = source[prop];
37179
- if (source != null && __getOwnPropSymbols$i)
37180
- for (var prop of __getOwnPropSymbols$i(source)) {
37181
- if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop))
37191
+ if (source != null && __getOwnPropSymbols$j)
37192
+ for (var prop of __getOwnPropSymbols$j(source)) {
37193
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$j.call(source, prop))
37182
37194
  target[prop] = source[prop];
37183
37195
  }
37184
37196
  return target;
37185
37197
  };
37186
37198
  const useGetShipmentRates = (params) => {
37187
37199
  const { client } = useShipEngine();
37188
- const _a = params, { queryFnParams } = _a, rest = __objRest$a(_a, ["queryFnParams"]);
37200
+ const _a = params, { queryFnParams } = _a, rest = __objRest$b(_a, ["queryFnParams"]);
37189
37201
  const shipmentId = queryFnParams == null ? void 0 : queryFnParams.shipmentId;
37190
37202
  const createdAtStart = queryFnParams == null ? void 0 : queryFnParams.createdAtStart;
37191
- return reactQuery.useQuery(__spreadProps$d(__spreadValues$g({
37203
+ return reactQuery.useQuery(__spreadProps$e(__spreadValues$h({
37192
37204
  enabled: shipmentId !== void 0
37193
37205
  }, rest), {
37194
37206
  onError,
@@ -37203,33 +37215,33 @@ const useGetShipmentRates = (params) => {
37203
37215
  }));
37204
37216
  };
37205
37217
 
37206
- var __defProp$f = Object.defineProperty;
37207
- var __defProps$c = Object.defineProperties;
37208
- var __getOwnPropDescs$c = Object.getOwnPropertyDescriptors;
37209
- var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
37210
- var __hasOwnProp$h = Object.prototype.hasOwnProperty;
37211
- var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
37212
- var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37213
- var __spreadValues$f = (a, b) => {
37218
+ var __defProp$g = Object.defineProperty;
37219
+ var __defProps$d = Object.defineProperties;
37220
+ var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
37221
+ var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
37222
+ var __hasOwnProp$i = Object.prototype.hasOwnProperty;
37223
+ var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
37224
+ var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37225
+ var __spreadValues$g = (a, b) => {
37214
37226
  for (var prop in b || (b = {}))
37215
- if (__hasOwnProp$h.call(b, prop))
37216
- __defNormalProp$f(a, prop, b[prop]);
37217
- if (__getOwnPropSymbols$h)
37218
- for (var prop of __getOwnPropSymbols$h(b)) {
37219
- if (__propIsEnum$h.call(b, prop))
37220
- __defNormalProp$f(a, prop, b[prop]);
37227
+ if (__hasOwnProp$i.call(b, prop))
37228
+ __defNormalProp$g(a, prop, b[prop]);
37229
+ if (__getOwnPropSymbols$i)
37230
+ for (var prop of __getOwnPropSymbols$i(b)) {
37231
+ if (__propIsEnum$i.call(b, prop))
37232
+ __defNormalProp$g(a, prop, b[prop]);
37221
37233
  }
37222
37234
  return a;
37223
37235
  };
37224
- var __spreadProps$c = (a, b) => __defProps$c(a, __getOwnPropDescs$c(b));
37225
- var __objRest$9 = (source, exclude) => {
37236
+ var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
37237
+ var __objRest$a = (source, exclude) => {
37226
37238
  var target = {};
37227
37239
  for (var prop in source)
37228
- if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)
37240
+ if (__hasOwnProp$i.call(source, prop) && exclude.indexOf(prop) < 0)
37229
37241
  target[prop] = source[prop];
37230
- if (source != null && __getOwnPropSymbols$h)
37231
- for (var prop of __getOwnPropSymbols$h(source)) {
37232
- if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))
37242
+ if (source != null && __getOwnPropSymbols$i)
37243
+ for (var prop of __getOwnPropSymbols$i(source)) {
37244
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$i.call(source, prop))
37233
37245
  target[prop] = source[prop];
37234
37246
  }
37235
37247
  return target;
@@ -37240,12 +37252,12 @@ const useGetShipment = (params) => {
37240
37252
  const shipmentId = typeof params === "string" ? params : (_a = params == null ? void 0 : params.queryFnParams) == null ? void 0 : _a.shipmentId;
37241
37253
  const getQueryProps = () => {
37242
37254
  if (typeof params !== "string") {
37243
- const _a2 = params, rest = __objRest$9(_a2, ["queryFnParams"]);
37255
+ const _a2 = params, rest = __objRest$a(_a2, ["queryFnParams"]);
37244
37256
  return rest;
37245
37257
  }
37246
37258
  return {};
37247
37259
  };
37248
- return reactQuery.useQuery(__spreadProps$c(__spreadValues$f({}, getQueryProps()), {
37260
+ return reactQuery.useQuery(__spreadProps$d(__spreadValues$g({}, getQueryProps()), {
37249
37261
  enabled: shipmentId !== void 0,
37250
37262
  onError,
37251
37263
  queryFn: () => {
@@ -37259,23 +37271,23 @@ const useGetShipment = (params) => {
37259
37271
  }));
37260
37272
  };
37261
37273
 
37262
- var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
37263
- var __hasOwnProp$g = Object.prototype.hasOwnProperty;
37264
- var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
37265
- var __objRest$8 = (source, exclude) => {
37274
+ var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
37275
+ var __hasOwnProp$h = Object.prototype.hasOwnProperty;
37276
+ var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
37277
+ var __objRest$9 = (source, exclude) => {
37266
37278
  var target = {};
37267
37279
  for (var prop in source)
37268
- if (__hasOwnProp$g.call(source, prop) && exclude.indexOf(prop) < 0)
37280
+ if (__hasOwnProp$h.call(source, prop) && exclude.indexOf(prop) < 0)
37269
37281
  target[prop] = source[prop];
37270
- if (source != null && __getOwnPropSymbols$g)
37271
- for (var prop of __getOwnPropSymbols$g(source)) {
37272
- if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source, prop))
37282
+ if (source != null && __getOwnPropSymbols$h)
37283
+ for (var prop of __getOwnPropSymbols$h(source)) {
37284
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$h.call(source, prop))
37273
37285
  target[prop] = source[prop];
37274
37286
  }
37275
37287
  return target;
37276
37288
  };
37277
37289
  const useListShipments = (_params) => {
37278
- const _a = _params || {}, { enabled = true } = _a, params = __objRest$8(_a, ["enabled"]);
37290
+ const _a = _params || {}, { enabled = true } = _a, params = __objRest$9(_a, ["enabled"]);
37279
37291
  const { client } = useShipEngine();
37280
37292
  return reactQuery.useQuery({
37281
37293
  enabled,
@@ -37286,41 +37298,41 @@ const useListShipments = (_params) => {
37286
37298
  });
37287
37299
  };
37288
37300
 
37289
- var __defProp$e = Object.defineProperty;
37290
- var __defProps$b = Object.defineProperties;
37291
- var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
37292
- var __getOwnPropSymbols$f = Object.getOwnPropertySymbols;
37293
- var __hasOwnProp$f = Object.prototype.hasOwnProperty;
37294
- var __propIsEnum$f = Object.prototype.propertyIsEnumerable;
37295
- var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37296
- var __spreadValues$e = (a, b) => {
37301
+ var __defProp$f = Object.defineProperty;
37302
+ var __defProps$c = Object.defineProperties;
37303
+ var __getOwnPropDescs$c = Object.getOwnPropertyDescriptors;
37304
+ var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
37305
+ var __hasOwnProp$g = Object.prototype.hasOwnProperty;
37306
+ var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
37307
+ var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37308
+ var __spreadValues$f = (a, b) => {
37297
37309
  for (var prop in b || (b = {}))
37298
- if (__hasOwnProp$f.call(b, prop))
37299
- __defNormalProp$e(a, prop, b[prop]);
37300
- if (__getOwnPropSymbols$f)
37301
- for (var prop of __getOwnPropSymbols$f(b)) {
37302
- if (__propIsEnum$f.call(b, prop))
37303
- __defNormalProp$e(a, prop, b[prop]);
37310
+ if (__hasOwnProp$g.call(b, prop))
37311
+ __defNormalProp$f(a, prop, b[prop]);
37312
+ if (__getOwnPropSymbols$g)
37313
+ for (var prop of __getOwnPropSymbols$g(b)) {
37314
+ if (__propIsEnum$g.call(b, prop))
37315
+ __defNormalProp$f(a, prop, b[prop]);
37304
37316
  }
37305
37317
  return a;
37306
37318
  };
37307
- var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
37308
- var __objRest$7 = (source, exclude) => {
37319
+ var __spreadProps$c = (a, b) => __defProps$c(a, __getOwnPropDescs$c(b));
37320
+ var __objRest$8 = (source, exclude) => {
37309
37321
  var target = {};
37310
37322
  for (var prop in source)
37311
- if (__hasOwnProp$f.call(source, prop) && exclude.indexOf(prop) < 0)
37323
+ if (__hasOwnProp$g.call(source, prop) && exclude.indexOf(prop) < 0)
37312
37324
  target[prop] = source[prop];
37313
- if (source != null && __getOwnPropSymbols$f)
37314
- for (var prop of __getOwnPropSymbols$f(source)) {
37315
- if (exclude.indexOf(prop) < 0 && __propIsEnum$f.call(source, prop))
37325
+ if (source != null && __getOwnPropSymbols$g)
37326
+ for (var prop of __getOwnPropSymbols$g(source)) {
37327
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source, prop))
37316
37328
  target[prop] = source[prop];
37317
37329
  }
37318
37330
  return target;
37319
37331
  };
37320
37332
  const useGetShipmentByExternalId = (params) => {
37321
37333
  const { client } = useShipEngine();
37322
- const _a = params, { queryFnParams } = _a, rest = __objRest$7(_a, ["queryFnParams"]);
37323
- return reactQuery.useQuery(__spreadProps$b(__spreadValues$e({}, rest), {
37334
+ const _a = params, { queryFnParams } = _a, rest = __objRest$8(_a, ["queryFnParams"]);
37335
+ return reactQuery.useQuery(__spreadProps$c(__spreadValues$f({}, rest), {
37324
37336
  onError,
37325
37337
  queryFn: () => client.shipments.getByExternalId(queryFnParams.externalId),
37326
37338
  queryKey: ["useGetShipmentByExternalId", queryFnParams],
@@ -37360,6 +37372,47 @@ const useCancelShipment = () => {
37360
37372
  });
37361
37373
  };
37362
37374
 
37375
+ var __defProp$e = Object.defineProperty;
37376
+ var __defProps$b = Object.defineProperties;
37377
+ var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
37378
+ var __getOwnPropSymbols$f = Object.getOwnPropertySymbols;
37379
+ var __hasOwnProp$f = Object.prototype.hasOwnProperty;
37380
+ var __propIsEnum$f = Object.prototype.propertyIsEnumerable;
37381
+ var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
37382
+ var __spreadValues$e = (a, b) => {
37383
+ for (var prop in b || (b = {}))
37384
+ if (__hasOwnProp$f.call(b, prop))
37385
+ __defNormalProp$e(a, prop, b[prop]);
37386
+ if (__getOwnPropSymbols$f)
37387
+ for (var prop of __getOwnPropSymbols$f(b)) {
37388
+ if (__propIsEnum$f.call(b, prop))
37389
+ __defNormalProp$e(a, prop, b[prop]);
37390
+ }
37391
+ return a;
37392
+ };
37393
+ var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
37394
+ var __objRest$7 = (source, exclude) => {
37395
+ var target = {};
37396
+ for (var prop in source)
37397
+ if (__hasOwnProp$f.call(source, prop) && exclude.indexOf(prop) < 0)
37398
+ target[prop] = source[prop];
37399
+ if (source != null && __getOwnPropSymbols$f)
37400
+ for (var prop of __getOwnPropSymbols$f(source)) {
37401
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$f.call(source, prop))
37402
+ target[prop] = source[prop];
37403
+ }
37404
+ return target;
37405
+ };
37406
+ const useDownloadShipments = (params) => {
37407
+ const { client } = useShipEngine();
37408
+ const _a = __spreadValues$e({}, params), { queryFnParams } = _a, rest = __objRest$7(_a, ["queryFnParams"]);
37409
+ return reactQuery.useQuery(__spreadProps$b(__spreadValues$e({}, rest), {
37410
+ onError,
37411
+ queryFn: () => client.shipments.download(queryFnParams),
37412
+ queryKey: ["useDownloadShipments", params]
37413
+ }));
37414
+ };
37415
+
37363
37416
  var __defProp$d = Object.defineProperty;
37364
37417
  var __defProps$a = Object.defineProperties;
37365
37418
  var __getOwnPropDescs$a = Object.getOwnPropertyDescriptors;
@@ -39575,6 +39628,7 @@ exports.useDeleteWarehouse = useDeleteWarehouse;
39575
39628
  exports.useDeleteWebhook = useDeleteWebhook;
39576
39629
  exports.useDownloadLabels = useDownloadLabels;
39577
39630
  exports.useDownloadRateCard = useDownloadRateCard;
39631
+ exports.useDownloadShipments = useDownloadShipments;
39578
39632
  exports.useEditShippingRule = useEditShippingRule;
39579
39633
  exports.useFundingSourcesAddFunds = useFundingSourcesAddFunds;
39580
39634
  exports.useGetAccountBilling = useGetAccountBilling;