@shipengine/alchemy 6.0.29 → 6.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +438 -360
- package/index.mjs +439 -362
- package/package.json +1 -1
package/index.mjs
CHANGED
|
@@ -2,7 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { createContext, forwardRef, useContext, createElement as createElement$1, Fragment, useState, useEffect, useCallback, useMemo, useRef } from 'react';
|
|
3
3
|
import { jsx as jsx$1 } from 'react/jsx-runtime';
|
|
4
4
|
import { GigerProvider, GigerTestProvider, DefaultPortalRefProvider } from '@shipengine/giger';
|
|
5
|
-
import { QueryClient, QueryClientProvider, useMutation, useQuery, useQueryClient } from '@tanstack/react-query';
|
|
5
|
+
import { QueryClient, QueryClientProvider, useMutation, useQuery, useQueryClient, useInfiniteQuery } from '@tanstack/react-query';
|
|
6
6
|
import { CacheProvider } from '@emotion/react';
|
|
7
7
|
import { I18nextProvider } from 'react-i18next';
|
|
8
8
|
import i18n from 'i18next';
|
|
@@ -10790,17 +10790,17 @@ var AccountBillingPlanChangeType = /* @__PURE__ */ ((AccountBillingPlanChangeTyp
|
|
|
10790
10790
|
return AccountBillingPlanChangeType2;
|
|
10791
10791
|
})(AccountBillingPlanChangeType || {});
|
|
10792
10792
|
|
|
10793
|
-
var __getOwnPropSymbols$
|
|
10794
|
-
var __hasOwnProp$
|
|
10795
|
-
var __propIsEnum$
|
|
10796
|
-
var __objRest$
|
|
10793
|
+
var __getOwnPropSymbols$I = Object.getOwnPropertySymbols;
|
|
10794
|
+
var __hasOwnProp$I = Object.prototype.hasOwnProperty;
|
|
10795
|
+
var __propIsEnum$I = Object.prototype.propertyIsEnumerable;
|
|
10796
|
+
var __objRest$q = (source, exclude) => {
|
|
10797
10797
|
var target = {};
|
|
10798
10798
|
for (var prop in source)
|
|
10799
|
-
if (__hasOwnProp$
|
|
10799
|
+
if (__hasOwnProp$I.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
10800
10800
|
target[prop] = source[prop];
|
|
10801
|
-
if (source != null && __getOwnPropSymbols$
|
|
10802
|
-
for (var prop of __getOwnPropSymbols$
|
|
10803
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
10801
|
+
if (source != null && __getOwnPropSymbols$I)
|
|
10802
|
+
for (var prop of __getOwnPropSymbols$I(source)) {
|
|
10803
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$I.call(source, prop))
|
|
10804
10804
|
target[prop] = source[prop];
|
|
10805
10805
|
}
|
|
10806
10806
|
return target;
|
|
@@ -10814,7 +10814,7 @@ class CodedError {
|
|
|
10814
10814
|
this.message = message;
|
|
10815
10815
|
}
|
|
10816
10816
|
static fromObject(_a) {
|
|
10817
|
-
var _b = _a, { message } = _b, options = __objRest$
|
|
10817
|
+
var _b = _a, { message } = _b, options = __objRest$q(_b, ["message"]);
|
|
10818
10818
|
return new CodedError(message, options);
|
|
10819
10819
|
}
|
|
10820
10820
|
}
|
|
@@ -10933,17 +10933,17 @@ const types = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.defineProperty({
|
|
|
10933
10933
|
RateCardStatus
|
|
10934
10934
|
}, Symbol.toStringTag, { value: 'Module' }));
|
|
10935
10935
|
|
|
10936
|
-
var __getOwnPropSymbols$
|
|
10937
|
-
var __hasOwnProp$
|
|
10938
|
-
var __propIsEnum$
|
|
10939
|
-
var __objRest$
|
|
10936
|
+
var __getOwnPropSymbols$H = Object.getOwnPropertySymbols;
|
|
10937
|
+
var __hasOwnProp$H = Object.prototype.hasOwnProperty;
|
|
10938
|
+
var __propIsEnum$H = Object.prototype.propertyIsEnumerable;
|
|
10939
|
+
var __objRest$p = (source, exclude) => {
|
|
10940
10940
|
var target = {};
|
|
10941
10941
|
for (var prop in source)
|
|
10942
|
-
if (__hasOwnProp$
|
|
10942
|
+
if (__hasOwnProp$H.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
10943
10943
|
target[prop] = source[prop];
|
|
10944
|
-
if (source != null && __getOwnPropSymbols$
|
|
10945
|
-
for (var prop of __getOwnPropSymbols$
|
|
10946
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
10944
|
+
if (source != null && __getOwnPropSymbols$H)
|
|
10945
|
+
for (var prop of __getOwnPropSymbols$H(source)) {
|
|
10946
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$H.call(source, prop))
|
|
10947
10947
|
target[prop] = source[prop];
|
|
10948
10948
|
}
|
|
10949
10949
|
return target;
|
|
@@ -10975,7 +10975,7 @@ class AccountSettingsAPI {
|
|
|
10975
10975
|
* The `updateImage` method updates specific image data for a given image id.
|
|
10976
10976
|
*/
|
|
10977
10977
|
this.updateImage = (_a) => {
|
|
10978
|
-
var _b = _a, { labelImageId } = _b, data = __objRest$
|
|
10978
|
+
var _b = _a, { labelImageId } = _b, data = __objRest$p(_b, ["labelImageId"]);
|
|
10979
10979
|
return this.client.put(`/v1/account/settings/images/${labelImageId}`, data);
|
|
10980
10980
|
};
|
|
10981
10981
|
/**
|
|
@@ -13685,7 +13685,7 @@ var ipaddr = {
|
|
|
13685
13685
|
}).call(commonjsGlobal);
|
|
13686
13686
|
} (ipaddr));
|
|
13687
13687
|
|
|
13688
|
-
var __async$
|
|
13688
|
+
var __async$Y = (__this, __arguments, generator) => {
|
|
13689
13689
|
return new Promise((resolve, reject) => {
|
|
13690
13690
|
var fulfilled = (value) => {
|
|
13691
13691
|
try {
|
|
@@ -13705,7 +13705,7 @@ var __async$X = (__this, __arguments, generator) => {
|
|
|
13705
13705
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
13706
13706
|
});
|
|
13707
13707
|
};
|
|
13708
|
-
const getEndUserIpAddress = () => __async$
|
|
13708
|
+
const getEndUserIpAddress = () => __async$Y(void 0, null, function* () {
|
|
13709
13709
|
try {
|
|
13710
13710
|
const response = yield axios.get("https://api.ipify.org/?format=json");
|
|
13711
13711
|
if (response.data.ip && ipaddrExports.isValid(response.data.ip)) {
|
|
@@ -13762,38 +13762,38 @@ const decamelizeKeys = (obj, separator = "_") => {
|
|
|
13762
13762
|
return obj;
|
|
13763
13763
|
};
|
|
13764
13764
|
|
|
13765
|
-
var __defProp$
|
|
13766
|
-
var __defProps$
|
|
13767
|
-
var __getOwnPropDescs$
|
|
13768
|
-
var __getOwnPropSymbols$
|
|
13769
|
-
var __hasOwnProp$
|
|
13770
|
-
var __propIsEnum$
|
|
13771
|
-
var __defNormalProp$
|
|
13772
|
-
var __spreadValues$
|
|
13765
|
+
var __defProp$v = Object.defineProperty;
|
|
13766
|
+
var __defProps$p = Object.defineProperties;
|
|
13767
|
+
var __getOwnPropDescs$p = Object.getOwnPropertyDescriptors;
|
|
13768
|
+
var __getOwnPropSymbols$G = Object.getOwnPropertySymbols;
|
|
13769
|
+
var __hasOwnProp$G = Object.prototype.hasOwnProperty;
|
|
13770
|
+
var __propIsEnum$G = Object.prototype.propertyIsEnumerable;
|
|
13771
|
+
var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
13772
|
+
var __spreadValues$v = (a, b) => {
|
|
13773
13773
|
for (var prop in b || (b = {}))
|
|
13774
|
-
if (__hasOwnProp$
|
|
13775
|
-
__defNormalProp$
|
|
13776
|
-
if (__getOwnPropSymbols$
|
|
13777
|
-
for (var prop of __getOwnPropSymbols$
|
|
13778
|
-
if (__propIsEnum$
|
|
13779
|
-
__defNormalProp$
|
|
13774
|
+
if (__hasOwnProp$G.call(b, prop))
|
|
13775
|
+
__defNormalProp$v(a, prop, b[prop]);
|
|
13776
|
+
if (__getOwnPropSymbols$G)
|
|
13777
|
+
for (var prop of __getOwnPropSymbols$G(b)) {
|
|
13778
|
+
if (__propIsEnum$G.call(b, prop))
|
|
13779
|
+
__defNormalProp$v(a, prop, b[prop]);
|
|
13780
13780
|
}
|
|
13781
13781
|
return a;
|
|
13782
13782
|
};
|
|
13783
|
-
var __spreadProps$
|
|
13784
|
-
var __objRest$
|
|
13783
|
+
var __spreadProps$p = (a, b) => __defProps$p(a, __getOwnPropDescs$p(b));
|
|
13784
|
+
var __objRest$o = (source, exclude) => {
|
|
13785
13785
|
var target = {};
|
|
13786
13786
|
for (var prop in source)
|
|
13787
|
-
if (__hasOwnProp$
|
|
13787
|
+
if (__hasOwnProp$G.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
13788
13788
|
target[prop] = source[prop];
|
|
13789
|
-
if (source != null && __getOwnPropSymbols$
|
|
13790
|
-
for (var prop of __getOwnPropSymbols$
|
|
13791
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
13789
|
+
if (source != null && __getOwnPropSymbols$G)
|
|
13790
|
+
for (var prop of __getOwnPropSymbols$G(source)) {
|
|
13791
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$G.call(source, prop))
|
|
13792
13792
|
target[prop] = source[prop];
|
|
13793
13793
|
}
|
|
13794
13794
|
return target;
|
|
13795
13795
|
};
|
|
13796
|
-
var __async$
|
|
13796
|
+
var __async$X = (__this, __arguments, generator) => {
|
|
13797
13797
|
return new Promise((resolve, reject) => {
|
|
13798
13798
|
var fulfilled = (value) => {
|
|
13799
13799
|
try {
|
|
@@ -13833,12 +13833,12 @@ class CarriersAPI {
|
|
|
13833
13833
|
/**
|
|
13834
13834
|
* The `connect` method connects a carrier account to a user's ShipEngine account.
|
|
13835
13835
|
*/
|
|
13836
|
-
this.connect = (_a) => __async$
|
|
13837
|
-
var _b = _a, { carrierCode } = _b, connection = __objRest$
|
|
13836
|
+
this.connect = (_a) => __async$X(this, null, function* () {
|
|
13837
|
+
var _b = _a, { carrierCode } = _b, connection = __objRest$o(_b, ["carrierCode"]);
|
|
13838
13838
|
const endUserIpAddress = yield getEndUserIpAddress();
|
|
13839
13839
|
if (!endUserIpAddress)
|
|
13840
13840
|
return Promise.reject([new CodedError("Unable to get IP address")]);
|
|
13841
|
-
return yield this.client.post(`/v1/registration/${carrierCode}`, __spreadProps$
|
|
13841
|
+
return yield this.client.post(`/v1/registration/${carrierCode}`, __spreadProps$p(__spreadValues$v({}, connection), {
|
|
13842
13842
|
endUserIpAddress
|
|
13843
13843
|
}));
|
|
13844
13844
|
});
|
|
@@ -13924,7 +13924,7 @@ class CarriersAPI {
|
|
|
13924
13924
|
}
|
|
13925
13925
|
}
|
|
13926
13926
|
|
|
13927
|
-
var __async$
|
|
13927
|
+
var __async$W = (__this, __arguments, generator) => {
|
|
13928
13928
|
return new Promise((resolve, reject) => {
|
|
13929
13929
|
var fulfilled = (value) => {
|
|
13930
13930
|
try {
|
|
@@ -13966,7 +13966,7 @@ class ConnectionsAPI {
|
|
|
13966
13966
|
/**
|
|
13967
13967
|
* The `connectCarrier` method connects a carrier to account.
|
|
13968
13968
|
*/
|
|
13969
|
-
this.connectCarrier = (carrierName, formData) => __async$
|
|
13969
|
+
this.connectCarrier = (carrierName, formData) => __async$W(this, null, function* () {
|
|
13970
13970
|
return yield this.client.post(
|
|
13971
13971
|
`/v1/connections/carriers/${carrierName}`,
|
|
13972
13972
|
formData,
|
|
@@ -16141,23 +16141,23 @@ class CustomPackagesAPI {
|
|
|
16141
16141
|
}
|
|
16142
16142
|
}
|
|
16143
16143
|
|
|
16144
|
-
var __defProp$
|
|
16145
|
-
var __getOwnPropSymbols$
|
|
16146
|
-
var __hasOwnProp$
|
|
16147
|
-
var __propIsEnum$
|
|
16148
|
-
var __defNormalProp$
|
|
16149
|
-
var __spreadValues$
|
|
16144
|
+
var __defProp$u = Object.defineProperty;
|
|
16145
|
+
var __getOwnPropSymbols$F = Object.getOwnPropertySymbols;
|
|
16146
|
+
var __hasOwnProp$F = Object.prototype.hasOwnProperty;
|
|
16147
|
+
var __propIsEnum$F = Object.prototype.propertyIsEnumerable;
|
|
16148
|
+
var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
16149
|
+
var __spreadValues$u = (a, b) => {
|
|
16150
16150
|
for (var prop in b || (b = {}))
|
|
16151
|
-
if (__hasOwnProp$
|
|
16152
|
-
__defNormalProp$
|
|
16153
|
-
if (__getOwnPropSymbols$
|
|
16154
|
-
for (var prop of __getOwnPropSymbols$
|
|
16155
|
-
if (__propIsEnum$
|
|
16156
|
-
__defNormalProp$
|
|
16151
|
+
if (__hasOwnProp$F.call(b, prop))
|
|
16152
|
+
__defNormalProp$u(a, prop, b[prop]);
|
|
16153
|
+
if (__getOwnPropSymbols$F)
|
|
16154
|
+
for (var prop of __getOwnPropSymbols$F(b)) {
|
|
16155
|
+
if (__propIsEnum$F.call(b, prop))
|
|
16156
|
+
__defNormalProp$u(a, prop, b[prop]);
|
|
16157
16157
|
}
|
|
16158
16158
|
return a;
|
|
16159
16159
|
};
|
|
16160
|
-
var __async$
|
|
16160
|
+
var __async$V = (__this, __arguments, generator) => {
|
|
16161
16161
|
return new Promise((resolve, reject) => {
|
|
16162
16162
|
var fulfilled = (value) => {
|
|
16163
16163
|
try {
|
|
@@ -16196,12 +16196,12 @@ class FundingSourcesAPI {
|
|
|
16196
16196
|
* The `create` method creates a new funding source for a given user. This requires
|
|
16197
16197
|
* payment information to be collected from the user.
|
|
16198
16198
|
*/
|
|
16199
|
-
this.create = (createFundingSource) => __async$
|
|
16199
|
+
this.create = (createFundingSource) => __async$V(this, null, function* () {
|
|
16200
16200
|
const endUserIpAddress = yield getEndUserIpAddress();
|
|
16201
16201
|
if (!endUserIpAddress) {
|
|
16202
16202
|
return Promise.reject([new CodedError("Unable to get IP address")]);
|
|
16203
16203
|
}
|
|
16204
|
-
return yield this.client.post("/v1/funding_sources", __spreadValues$
|
|
16204
|
+
return yield this.client.post("/v1/funding_sources", __spreadValues$u({
|
|
16205
16205
|
endUserIpAddress
|
|
16206
16206
|
}, createFundingSource));
|
|
16207
16207
|
});
|
|
@@ -16210,7 +16210,7 @@ class FundingSourcesAPI {
|
|
|
16210
16210
|
* user to update the billing address or payment information associated with the
|
|
16211
16211
|
* funding source.
|
|
16212
16212
|
*/
|
|
16213
|
-
this.update = (billingInfo, creditCardInfo, fundingSourceId) => __async$
|
|
16213
|
+
this.update = (billingInfo, creditCardInfo, fundingSourceId) => __async$V(this, null, function* () {
|
|
16214
16214
|
const endUserIpAddress = yield getEndUserIpAddress();
|
|
16215
16215
|
if (!endUserIpAddress) {
|
|
16216
16216
|
return Promise.reject([new CodedError("Unable to get IP address")]);
|
|
@@ -16228,19 +16228,19 @@ class FundingSourcesAPI {
|
|
|
16228
16228
|
* The `registerCarrier` method registers a carrier account and associates
|
|
16229
16229
|
* it with a given funding source.
|
|
16230
16230
|
*/
|
|
16231
|
-
this.registerCarrier = (carrier) => __async$
|
|
16231
|
+
this.registerCarrier = (carrier) => __async$V(this, null, function* () {
|
|
16232
16232
|
const endUserIpAddress = yield getEndUserIpAddress();
|
|
16233
16233
|
if (!endUserIpAddress) {
|
|
16234
16234
|
return Promise.reject([new CodedError("Unable to get IP address")]);
|
|
16235
16235
|
}
|
|
16236
|
-
return yield this.client.post("/v1/registration/funding_source", __spreadValues$
|
|
16236
|
+
return yield this.client.post("/v1/registration/funding_source", __spreadValues$u({
|
|
16237
16237
|
endUserIpAddress
|
|
16238
16238
|
}, carrier));
|
|
16239
16239
|
});
|
|
16240
16240
|
/**
|
|
16241
16241
|
* The `addFunds` method allows you to add funds to a funding source.
|
|
16242
16242
|
*/
|
|
16243
|
-
this.addFunds = (amount, fundingSourceId) => __async$
|
|
16243
|
+
this.addFunds = (amount, fundingSourceId) => __async$V(this, null, function* () {
|
|
16244
16244
|
return yield this.client.put(
|
|
16245
16245
|
`/v1/funding_sources/${fundingSourceId}/add_funds`,
|
|
16246
16246
|
amount
|
|
@@ -16250,7 +16250,7 @@ class FundingSourcesAPI {
|
|
|
16250
16250
|
* The `metadata` method returns seller-specific requirements for creating funding sources
|
|
16251
16251
|
* and attaching carriers
|
|
16252
16252
|
*/
|
|
16253
|
-
this.metadata = () => __async$
|
|
16253
|
+
this.metadata = () => __async$V(this, null, function* () {
|
|
16254
16254
|
return yield this.client.get("/v1/funding_sources/metadata");
|
|
16255
16255
|
});
|
|
16256
16256
|
/**
|
|
@@ -16302,7 +16302,7 @@ class InsuranceAPI {
|
|
|
16302
16302
|
}
|
|
16303
16303
|
}
|
|
16304
16304
|
|
|
16305
|
-
var __async$
|
|
16305
|
+
var __async$U = (__this, __arguments, generator) => {
|
|
16306
16306
|
return new Promise((resolve, reject) => {
|
|
16307
16307
|
var fulfilled = (value) => {
|
|
16308
16308
|
try {
|
|
@@ -16334,13 +16334,13 @@ class InvoiceAddressAPI {
|
|
|
16334
16334
|
/**
|
|
16335
16335
|
* The `create` method creates a new invoice address for a given user.
|
|
16336
16336
|
*/
|
|
16337
|
-
this.create = (invoiceAddress) => __async$
|
|
16337
|
+
this.create = (invoiceAddress) => __async$U(this, null, function* () {
|
|
16338
16338
|
return yield this.client.post("/v1/invoice_address", invoiceAddress);
|
|
16339
16339
|
});
|
|
16340
16340
|
/**
|
|
16341
16341
|
* The `update` method updates a invoice address for a given user.
|
|
16342
16342
|
*/
|
|
16343
|
-
this.update = (invoiceAddress) => __async$
|
|
16343
|
+
this.update = (invoiceAddress) => __async$U(this, null, function* () {
|
|
16344
16344
|
return yield this.client.put("/v1/invoice_address", invoiceAddress);
|
|
16345
16345
|
});
|
|
16346
16346
|
this.client = client;
|
|
@@ -16382,17 +16382,17 @@ class LabelsAPI {
|
|
|
16382
16382
|
}
|
|
16383
16383
|
}
|
|
16384
16384
|
|
|
16385
|
-
var __getOwnPropSymbols$
|
|
16386
|
-
var __hasOwnProp$
|
|
16387
|
-
var __propIsEnum$
|
|
16388
|
-
var __objRest$
|
|
16385
|
+
var __getOwnPropSymbols$E = Object.getOwnPropertySymbols;
|
|
16386
|
+
var __hasOwnProp$E = Object.prototype.hasOwnProperty;
|
|
16387
|
+
var __propIsEnum$E = Object.prototype.propertyIsEnumerable;
|
|
16388
|
+
var __objRest$n = (source, exclude) => {
|
|
16389
16389
|
var target = {};
|
|
16390
16390
|
for (var prop in source)
|
|
16391
|
-
if (__hasOwnProp$
|
|
16391
|
+
if (__hasOwnProp$E.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
16392
16392
|
target[prop] = source[prop];
|
|
16393
|
-
if (source != null && __getOwnPropSymbols$
|
|
16394
|
-
for (var prop of __getOwnPropSymbols$
|
|
16395
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
16393
|
+
if (source != null && __getOwnPropSymbols$E)
|
|
16394
|
+
for (var prop of __getOwnPropSymbols$E(source)) {
|
|
16395
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$E.call(source, prop))
|
|
16396
16396
|
target[prop] = source[prop];
|
|
16397
16397
|
}
|
|
16398
16398
|
return target;
|
|
@@ -16424,7 +16424,7 @@ class OrderSourcesAPI {
|
|
|
16424
16424
|
* The `update` method will allow the user to update a connected Order Source
|
|
16425
16425
|
*/
|
|
16426
16426
|
this.update = (_a) => {
|
|
16427
|
-
var _b = _a, { orderSourceId } = _b, rest = __objRest$
|
|
16427
|
+
var _b = _a, { orderSourceId } = _b, rest = __objRest$n(_b, ["orderSourceId"]);
|
|
16428
16428
|
return this.client.put(`/v-beta/order_sources/${orderSourceId}`, rest);
|
|
16429
16429
|
};
|
|
16430
16430
|
/**
|
|
@@ -16513,19 +16513,19 @@ class RateCardsAPI {
|
|
|
16513
16513
|
}
|
|
16514
16514
|
}
|
|
16515
16515
|
|
|
16516
|
-
var __defProp$
|
|
16517
|
-
var __getOwnPropSymbols$
|
|
16518
|
-
var __hasOwnProp$
|
|
16519
|
-
var __propIsEnum$
|
|
16520
|
-
var __defNormalProp$
|
|
16521
|
-
var __spreadValues$
|
|
16516
|
+
var __defProp$t = Object.defineProperty;
|
|
16517
|
+
var __getOwnPropSymbols$D = Object.getOwnPropertySymbols;
|
|
16518
|
+
var __hasOwnProp$D = Object.prototype.hasOwnProperty;
|
|
16519
|
+
var __propIsEnum$D = Object.prototype.propertyIsEnumerable;
|
|
16520
|
+
var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
16521
|
+
var __spreadValues$t = (a, b) => {
|
|
16522
16522
|
for (var prop in b || (b = {}))
|
|
16523
|
-
if (__hasOwnProp$
|
|
16524
|
-
__defNormalProp$
|
|
16525
|
-
if (__getOwnPropSymbols$
|
|
16526
|
-
for (var prop of __getOwnPropSymbols$
|
|
16527
|
-
if (__propIsEnum$
|
|
16528
|
-
__defNormalProp$
|
|
16523
|
+
if (__hasOwnProp$D.call(b, prop))
|
|
16524
|
+
__defNormalProp$t(a, prop, b[prop]);
|
|
16525
|
+
if (__getOwnPropSymbols$D)
|
|
16526
|
+
for (var prop of __getOwnPropSymbols$D(b)) {
|
|
16527
|
+
if (__propIsEnum$D.call(b, prop))
|
|
16528
|
+
__defNormalProp$t(a, prop, b[prop]);
|
|
16529
16529
|
}
|
|
16530
16530
|
return a;
|
|
16531
16531
|
};
|
|
@@ -16547,7 +16547,7 @@ class RatesAPI {
|
|
|
16547
16547
|
* method.
|
|
16548
16548
|
*/
|
|
16549
16549
|
this.estimate = (params) => {
|
|
16550
|
-
return this.client.post("/v1/rates/estimate", __spreadValues$
|
|
16550
|
+
return this.client.post("/v1/rates/estimate", __spreadValues$t({}, params));
|
|
16551
16551
|
};
|
|
16552
16552
|
this.client = client;
|
|
16553
16553
|
}
|
|
@@ -16627,7 +16627,7 @@ class SalesOrdersAPI {
|
|
|
16627
16627
|
}
|
|
16628
16628
|
}
|
|
16629
16629
|
|
|
16630
|
-
var __async$
|
|
16630
|
+
var __async$T = (__this, __arguments, generator) => {
|
|
16631
16631
|
return new Promise((resolve, reject) => {
|
|
16632
16632
|
var fulfilled = (value) => {
|
|
16633
16633
|
try {
|
|
@@ -16685,7 +16685,7 @@ class SellersAPI {
|
|
|
16685
16685
|
/**
|
|
16686
16686
|
* Deletes an API Key
|
|
16687
16687
|
*/
|
|
16688
|
-
this.deleteSellerApiKey = (_0) => __async$
|
|
16688
|
+
this.deleteSellerApiKey = (_0) => __async$T(this, [_0], function* ({
|
|
16689
16689
|
encryptedApiKey,
|
|
16690
16690
|
sellerId,
|
|
16691
16691
|
isSandbox
|
|
@@ -16731,19 +16731,19 @@ class SellersAPI {
|
|
|
16731
16731
|
}
|
|
16732
16732
|
}
|
|
16733
16733
|
|
|
16734
|
-
var __defProp$
|
|
16735
|
-
var __getOwnPropSymbols$
|
|
16736
|
-
var __hasOwnProp$
|
|
16737
|
-
var __propIsEnum$
|
|
16738
|
-
var __defNormalProp$
|
|
16739
|
-
var __spreadValues$
|
|
16734
|
+
var __defProp$s = Object.defineProperty;
|
|
16735
|
+
var __getOwnPropSymbols$C = Object.getOwnPropertySymbols;
|
|
16736
|
+
var __hasOwnProp$C = Object.prototype.hasOwnProperty;
|
|
16737
|
+
var __propIsEnum$C = Object.prototype.propertyIsEnumerable;
|
|
16738
|
+
var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
16739
|
+
var __spreadValues$s = (a, b) => {
|
|
16740
16740
|
for (var prop in b || (b = {}))
|
|
16741
|
-
if (__hasOwnProp$
|
|
16742
|
-
__defNormalProp$
|
|
16743
|
-
if (__getOwnPropSymbols$
|
|
16744
|
-
for (var prop of __getOwnPropSymbols$
|
|
16745
|
-
if (__propIsEnum$
|
|
16746
|
-
__defNormalProp$
|
|
16741
|
+
if (__hasOwnProp$C.call(b, prop))
|
|
16742
|
+
__defNormalProp$s(a, prop, b[prop]);
|
|
16743
|
+
if (__getOwnPropSymbols$C)
|
|
16744
|
+
for (var prop of __getOwnPropSymbols$C(b)) {
|
|
16745
|
+
if (__propIsEnum$C.call(b, prop))
|
|
16746
|
+
__defNormalProp$s(a, prop, b[prop]);
|
|
16747
16747
|
}
|
|
16748
16748
|
return a;
|
|
16749
16749
|
};
|
|
@@ -16755,7 +16755,7 @@ class ServicePointsAPI {
|
|
|
16755
16755
|
* Either an address, coordinates, or an address query
|
|
16756
16756
|
*/
|
|
16757
16757
|
this.list = (options) => {
|
|
16758
|
-
return this.client.post("/v1/service_points/list", __spreadValues$
|
|
16758
|
+
return this.client.post("/v1/service_points/list", __spreadValues$s({}, options));
|
|
16759
16759
|
};
|
|
16760
16760
|
/**
|
|
16761
16761
|
* Get a specific service point by its carrier code, country code, and id
|
|
@@ -16773,7 +16773,7 @@ class ServicePointsAPI {
|
|
|
16773
16773
|
}
|
|
16774
16774
|
}
|
|
16775
16775
|
|
|
16776
|
-
var __async$
|
|
16776
|
+
var __async$S = (__this, __arguments, generator) => {
|
|
16777
16777
|
return new Promise((resolve, reject) => {
|
|
16778
16778
|
var fulfilled = (value) => {
|
|
16779
16779
|
try {
|
|
@@ -16822,7 +16822,7 @@ class ShipmentsAPI {
|
|
|
16822
16822
|
* The `create` method allows for creating shipments based on a list of shipment
|
|
16823
16823
|
* items passed into this method.
|
|
16824
16824
|
*/
|
|
16825
|
-
this.create = (...shipments) => __async$
|
|
16825
|
+
this.create = (...shipments) => __async$S(this, null, function* () {
|
|
16826
16826
|
return this.client.post("/v1/shipments", {
|
|
16827
16827
|
shipments
|
|
16828
16828
|
});
|
|
@@ -34214,26 +34214,26 @@ class WebhooksAPI {
|
|
|
34214
34214
|
}
|
|
34215
34215
|
}
|
|
34216
34216
|
|
|
34217
|
-
var __defProp$
|
|
34218
|
-
var __defProps$
|
|
34219
|
-
var __getOwnPropDescs$
|
|
34220
|
-
var __getOwnPropSymbols$
|
|
34221
|
-
var __hasOwnProp$
|
|
34222
|
-
var __propIsEnum$
|
|
34223
|
-
var __defNormalProp$
|
|
34224
|
-
var __spreadValues$
|
|
34217
|
+
var __defProp$r = Object.defineProperty;
|
|
34218
|
+
var __defProps$o = Object.defineProperties;
|
|
34219
|
+
var __getOwnPropDescs$o = Object.getOwnPropertyDescriptors;
|
|
34220
|
+
var __getOwnPropSymbols$B = Object.getOwnPropertySymbols;
|
|
34221
|
+
var __hasOwnProp$B = Object.prototype.hasOwnProperty;
|
|
34222
|
+
var __propIsEnum$B = Object.prototype.propertyIsEnumerable;
|
|
34223
|
+
var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
34224
|
+
var __spreadValues$r = (a, b) => {
|
|
34225
34225
|
for (var prop in b || (b = {}))
|
|
34226
|
-
if (__hasOwnProp$
|
|
34227
|
-
__defNormalProp$
|
|
34228
|
-
if (__getOwnPropSymbols$
|
|
34229
|
-
for (var prop of __getOwnPropSymbols$
|
|
34230
|
-
if (__propIsEnum$
|
|
34231
|
-
__defNormalProp$
|
|
34226
|
+
if (__hasOwnProp$B.call(b, prop))
|
|
34227
|
+
__defNormalProp$r(a, prop, b[prop]);
|
|
34228
|
+
if (__getOwnPropSymbols$B)
|
|
34229
|
+
for (var prop of __getOwnPropSymbols$B(b)) {
|
|
34230
|
+
if (__propIsEnum$B.call(b, prop))
|
|
34231
|
+
__defNormalProp$r(a, prop, b[prop]);
|
|
34232
34232
|
}
|
|
34233
34233
|
return a;
|
|
34234
34234
|
};
|
|
34235
|
-
var __spreadProps$
|
|
34236
|
-
var __async$
|
|
34235
|
+
var __spreadProps$o = (a, b) => __defProps$o(a, __getOwnPropDescs$o(b));
|
|
34236
|
+
var __async$R = (__this, __arguments, generator) => {
|
|
34237
34237
|
return new Promise((resolve, reject) => {
|
|
34238
34238
|
var fulfilled = (value) => {
|
|
34239
34239
|
try {
|
|
@@ -34256,7 +34256,7 @@ var __async$Q = (__this, __arguments, generator) => {
|
|
|
34256
34256
|
const logger$1 = E({
|
|
34257
34257
|
level: process.env.NODE_ENV === "production" ? "fatal" : "info",
|
|
34258
34258
|
name: "shipengine-api",
|
|
34259
|
-
serializers: __spreadProps$
|
|
34259
|
+
serializers: __spreadProps$o(__spreadValues$r({}, k), {
|
|
34260
34260
|
req: (req) => ({
|
|
34261
34261
|
headers: req.headers,
|
|
34262
34262
|
method: req.method,
|
|
@@ -34281,7 +34281,7 @@ class ShipEngineAPI {
|
|
|
34281
34281
|
this.getSandboxToken = getSandboxToken;
|
|
34282
34282
|
const client = axios.create({
|
|
34283
34283
|
baseURL,
|
|
34284
|
-
headers: __spreadProps$
|
|
34284
|
+
headers: __spreadProps$o(__spreadValues$r({}, headers), {
|
|
34285
34285
|
"Content-Type": "application/json"
|
|
34286
34286
|
}),
|
|
34287
34287
|
paramsSerializer: (params) => lib.stringify(decamelizeKeys(params), { arrayFormat: "brackets" }),
|
|
@@ -34316,7 +34316,7 @@ class ShipEngineAPI {
|
|
|
34316
34316
|
});
|
|
34317
34317
|
client.defaults.headers.common["Authorization"] = `Bearer ${token}`;
|
|
34318
34318
|
client.interceptors.request.use(
|
|
34319
|
-
(config) => __async$
|
|
34319
|
+
(config) => __async$R(this, null, function* () {
|
|
34320
34320
|
if (config.isSandbox) {
|
|
34321
34321
|
if (!this.sandboxToken) {
|
|
34322
34322
|
this.sandboxToken = yield getSandboxToken == null ? void 0 : getSandboxToken();
|
|
@@ -34343,7 +34343,7 @@ class ShipEngineAPI {
|
|
|
34343
34343
|
);
|
|
34344
34344
|
return res;
|
|
34345
34345
|
},
|
|
34346
|
-
(err) => __async$
|
|
34346
|
+
(err) => __async$R(this, null, function* () {
|
|
34347
34347
|
var _a, _b, _c, _d, _e;
|
|
34348
34348
|
logger$1.error(
|
|
34349
34349
|
{ err, req: err.config, res: err.response },
|
|
@@ -34390,7 +34390,7 @@ class ShipEngineAPI {
|
|
|
34390
34390
|
* that token (also known as Seller ID)
|
|
34391
34391
|
*/
|
|
34392
34392
|
getTenant(isSandbox) {
|
|
34393
|
-
return __async$
|
|
34393
|
+
return __async$R(this, null, function* () {
|
|
34394
34394
|
var _a;
|
|
34395
34395
|
if (!isSandbox) {
|
|
34396
34396
|
return this.getTenantFromToken(this.token);
|
|
@@ -34669,25 +34669,25 @@ const delay = (ms) => new Promise((resolve) => {
|
|
|
34669
34669
|
|
|
34670
34670
|
const onError = (_errors) => _default();
|
|
34671
34671
|
|
|
34672
|
-
var __defProp$
|
|
34673
|
-
var __defProps$
|
|
34674
|
-
var __getOwnPropDescs$
|
|
34675
|
-
var __getOwnPropSymbols$
|
|
34676
|
-
var __hasOwnProp$
|
|
34677
|
-
var __propIsEnum$
|
|
34678
|
-
var __defNormalProp$
|
|
34679
|
-
var __spreadValues$
|
|
34672
|
+
var __defProp$q = Object.defineProperty;
|
|
34673
|
+
var __defProps$n = Object.defineProperties;
|
|
34674
|
+
var __getOwnPropDescs$n = Object.getOwnPropertyDescriptors;
|
|
34675
|
+
var __getOwnPropSymbols$A = Object.getOwnPropertySymbols;
|
|
34676
|
+
var __hasOwnProp$A = Object.prototype.hasOwnProperty;
|
|
34677
|
+
var __propIsEnum$A = Object.prototype.propertyIsEnumerable;
|
|
34678
|
+
var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
34679
|
+
var __spreadValues$q = (a, b) => {
|
|
34680
34680
|
for (var prop in b || (b = {}))
|
|
34681
|
-
if (__hasOwnProp$
|
|
34682
|
-
__defNormalProp$
|
|
34683
|
-
if (__getOwnPropSymbols$
|
|
34684
|
-
for (var prop of __getOwnPropSymbols$
|
|
34685
|
-
if (__propIsEnum$
|
|
34686
|
-
__defNormalProp$
|
|
34681
|
+
if (__hasOwnProp$A.call(b, prop))
|
|
34682
|
+
__defNormalProp$q(a, prop, b[prop]);
|
|
34683
|
+
if (__getOwnPropSymbols$A)
|
|
34684
|
+
for (var prop of __getOwnPropSymbols$A(b)) {
|
|
34685
|
+
if (__propIsEnum$A.call(b, prop))
|
|
34686
|
+
__defNormalProp$q(a, prop, b[prop]);
|
|
34687
34687
|
}
|
|
34688
34688
|
return a;
|
|
34689
34689
|
};
|
|
34690
|
-
var __spreadProps$
|
|
34690
|
+
var __spreadProps$n = (a, b) => __defProps$n(a, __getOwnPropDescs$n(b));
|
|
34691
34691
|
const streams = [];
|
|
34692
34692
|
if (process.env.NODE_ENV === "production") {
|
|
34693
34693
|
streams.push({
|
|
@@ -34696,7 +34696,7 @@ if (process.env.NODE_ENV === "production") {
|
|
|
34696
34696
|
}
|
|
34697
34697
|
const logger = E({
|
|
34698
34698
|
name: "shipengine",
|
|
34699
|
-
serializers: __spreadProps$
|
|
34699
|
+
serializers: __spreadProps$n(__spreadValues$q({}, k), {
|
|
34700
34700
|
req: (req) => ({
|
|
34701
34701
|
headers: req.headers,
|
|
34702
34702
|
method: req.method,
|
|
@@ -34721,7 +34721,7 @@ const retryUntil = (callbackFn, retries = 10, timeoutBetweenAttempts = 1e3) => P
|
|
|
34721
34721
|
throw error;
|
|
34722
34722
|
});
|
|
34723
34723
|
|
|
34724
|
-
var __async$
|
|
34724
|
+
var __async$Q = (__this, __arguments, generator) => {
|
|
34725
34725
|
return new Promise((resolve, reject) => {
|
|
34726
34726
|
var fulfilled = (value) => {
|
|
34727
34727
|
try {
|
|
@@ -34744,7 +34744,7 @@ var __async$P = (__this, __arguments, generator) => {
|
|
|
34744
34744
|
const useCreateAccountImage = () => {
|
|
34745
34745
|
const { client } = useShipEngine();
|
|
34746
34746
|
return useMutation({
|
|
34747
|
-
mutationFn: (data) => __async$
|
|
34747
|
+
mutationFn: (data) => __async$Q(void 0, null, function* () {
|
|
34748
34748
|
const result = yield client.accountSettings.createImage(data);
|
|
34749
34749
|
return result.data;
|
|
34750
34750
|
}),
|
|
@@ -34753,7 +34753,7 @@ const useCreateAccountImage = () => {
|
|
|
34753
34753
|
});
|
|
34754
34754
|
};
|
|
34755
34755
|
|
|
34756
|
-
var __async$
|
|
34756
|
+
var __async$P = (__this, __arguments, generator) => {
|
|
34757
34757
|
return new Promise((resolve, reject) => {
|
|
34758
34758
|
var fulfilled = (value) => {
|
|
34759
34759
|
try {
|
|
@@ -34776,7 +34776,7 @@ var __async$O = (__this, __arguments, generator) => {
|
|
|
34776
34776
|
const useDeleteAccountImage = () => {
|
|
34777
34777
|
const { client } = useShipEngine();
|
|
34778
34778
|
return useMutation({
|
|
34779
|
-
mutationFn: (labelImageId) => __async$
|
|
34779
|
+
mutationFn: (labelImageId) => __async$P(void 0, null, function* () {
|
|
34780
34780
|
const result = yield client.accountSettings.deleteImage(labelImageId);
|
|
34781
34781
|
return result.data;
|
|
34782
34782
|
}),
|
|
@@ -34805,7 +34805,7 @@ const useGetAccountSettings = () => {
|
|
|
34805
34805
|
});
|
|
34806
34806
|
};
|
|
34807
34807
|
|
|
34808
|
-
var __async$
|
|
34808
|
+
var __async$O = (__this, __arguments, generator) => {
|
|
34809
34809
|
return new Promise((resolve, reject) => {
|
|
34810
34810
|
var fulfilled = (value) => {
|
|
34811
34811
|
try {
|
|
@@ -34828,7 +34828,7 @@ var __async$N = (__this, __arguments, generator) => {
|
|
|
34828
34828
|
const useUpdateAccountImage = () => {
|
|
34829
34829
|
const { client } = useShipEngine();
|
|
34830
34830
|
return useMutation({
|
|
34831
|
-
mutationFn: (data) => __async$
|
|
34831
|
+
mutationFn: (data) => __async$O(void 0, null, function* () {
|
|
34832
34832
|
const result = yield client.accountSettings.updateImage(data);
|
|
34833
34833
|
return result.data;
|
|
34834
34834
|
}),
|
|
@@ -34837,7 +34837,7 @@ const useUpdateAccountImage = () => {
|
|
|
34837
34837
|
});
|
|
34838
34838
|
};
|
|
34839
34839
|
|
|
34840
|
-
var __async$
|
|
34840
|
+
var __async$N = (__this, __arguments, generator) => {
|
|
34841
34841
|
return new Promise((resolve, reject) => {
|
|
34842
34842
|
var fulfilled = (value) => {
|
|
34843
34843
|
try {
|
|
@@ -34860,7 +34860,7 @@ var __async$M = (__this, __arguments, generator) => {
|
|
|
34860
34860
|
const useUpdateAccountSettings = () => {
|
|
34861
34861
|
const { client } = useShipEngine();
|
|
34862
34862
|
return useMutation({
|
|
34863
|
-
mutationFn: (settings) => __async$
|
|
34863
|
+
mutationFn: (settings) => __async$N(void 0, null, function* () {
|
|
34864
34864
|
const result = yield client.accountSettings.update(settings);
|
|
34865
34865
|
return result.data;
|
|
34866
34866
|
}),
|
|
@@ -34869,7 +34869,7 @@ const useUpdateAccountSettings = () => {
|
|
|
34869
34869
|
});
|
|
34870
34870
|
};
|
|
34871
34871
|
|
|
34872
|
-
var __async$
|
|
34872
|
+
var __async$M = (__this, __arguments, generator) => {
|
|
34873
34873
|
return new Promise((resolve, reject) => {
|
|
34874
34874
|
var fulfilled = (value) => {
|
|
34875
34875
|
try {
|
|
@@ -34892,7 +34892,7 @@ var __async$L = (__this, __arguments, generator) => {
|
|
|
34892
34892
|
const useParseAddress = () => {
|
|
34893
34893
|
const { client } = useShipEngine();
|
|
34894
34894
|
return useMutation({
|
|
34895
|
-
mutationFn: (_0) => __async$
|
|
34895
|
+
mutationFn: (_0) => __async$M(void 0, [_0], function* ({ address, text }) {
|
|
34896
34896
|
const result = yield client.addresses.parse(text, address);
|
|
34897
34897
|
return result.data;
|
|
34898
34898
|
}),
|
|
@@ -34901,7 +34901,7 @@ const useParseAddress = () => {
|
|
|
34901
34901
|
});
|
|
34902
34902
|
};
|
|
34903
34903
|
|
|
34904
|
-
var __async$
|
|
34904
|
+
var __async$L = (__this, __arguments, generator) => {
|
|
34905
34905
|
return new Promise((resolve, reject) => {
|
|
34906
34906
|
var fulfilled = (value) => {
|
|
34907
34907
|
try {
|
|
@@ -34924,7 +34924,7 @@ var __async$K = (__this, __arguments, generator) => {
|
|
|
34924
34924
|
const useValidateAddresses = () => {
|
|
34925
34925
|
const { client } = useShipEngine();
|
|
34926
34926
|
return useMutation({
|
|
34927
|
-
mutationFn: (addresses) => __async$
|
|
34927
|
+
mutationFn: (addresses) => __async$L(void 0, null, function* () {
|
|
34928
34928
|
const result = yield client.addresses.validate(addresses);
|
|
34929
34929
|
return result.data;
|
|
34930
34930
|
}),
|
|
@@ -34933,7 +34933,7 @@ const useValidateAddresses = () => {
|
|
|
34933
34933
|
});
|
|
34934
34934
|
};
|
|
34935
34935
|
|
|
34936
|
-
var __async$
|
|
34936
|
+
var __async$K = (__this, __arguments, generator) => {
|
|
34937
34937
|
return new Promise((resolve, reject) => {
|
|
34938
34938
|
var fulfilled = (value) => {
|
|
34939
34939
|
try {
|
|
@@ -34956,7 +34956,7 @@ var __async$J = (__this, __arguments, generator) => {
|
|
|
34956
34956
|
const useAddFunds = () => {
|
|
34957
34957
|
const { client } = useShipEngine();
|
|
34958
34958
|
return useMutation({
|
|
34959
|
-
mutationFn: (_0) => __async$
|
|
34959
|
+
mutationFn: (_0) => __async$K(void 0, [_0], function* ({ carrierId, funds }) {
|
|
34960
34960
|
const result = yield client.carriers.addFunds(carrierId, funds);
|
|
34961
34961
|
return result.data;
|
|
34962
34962
|
}),
|
|
@@ -34965,7 +34965,7 @@ const useAddFunds = () => {
|
|
|
34965
34965
|
});
|
|
34966
34966
|
};
|
|
34967
34967
|
|
|
34968
|
-
var __async$
|
|
34968
|
+
var __async$J = (__this, __arguments, generator) => {
|
|
34969
34969
|
return new Promise((resolve, reject) => {
|
|
34970
34970
|
var fulfilled = (value) => {
|
|
34971
34971
|
try {
|
|
@@ -34988,7 +34988,7 @@ var __async$I = (__this, __arguments, generator) => {
|
|
|
34988
34988
|
const useConnectCarrier = () => {
|
|
34989
34989
|
const { client } = useShipEngine();
|
|
34990
34990
|
return useMutation({
|
|
34991
|
-
mutationFn: (params) => __async$
|
|
34991
|
+
mutationFn: (params) => __async$J(void 0, null, function* () {
|
|
34992
34992
|
const result = yield client.carriers.connect(params);
|
|
34993
34993
|
return result.data;
|
|
34994
34994
|
}),
|
|
@@ -35097,41 +35097,41 @@ const useGetServicesByCarrier = (carrierId) => {
|
|
|
35097
35097
|
});
|
|
35098
35098
|
};
|
|
35099
35099
|
|
|
35100
|
-
var __defProp$
|
|
35101
|
-
var __defProps$
|
|
35102
|
-
var __getOwnPropDescs$
|
|
35103
|
-
var __getOwnPropSymbols$
|
|
35104
|
-
var __hasOwnProp$
|
|
35105
|
-
var __propIsEnum$
|
|
35106
|
-
var __defNormalProp$
|
|
35107
|
-
var __spreadValues$
|
|
35100
|
+
var __defProp$p = Object.defineProperty;
|
|
35101
|
+
var __defProps$m = Object.defineProperties;
|
|
35102
|
+
var __getOwnPropDescs$m = Object.getOwnPropertyDescriptors;
|
|
35103
|
+
var __getOwnPropSymbols$z = Object.getOwnPropertySymbols;
|
|
35104
|
+
var __hasOwnProp$z = Object.prototype.hasOwnProperty;
|
|
35105
|
+
var __propIsEnum$z = Object.prototype.propertyIsEnumerable;
|
|
35106
|
+
var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
35107
|
+
var __spreadValues$p = (a, b) => {
|
|
35108
35108
|
for (var prop in b || (b = {}))
|
|
35109
|
-
if (__hasOwnProp$
|
|
35110
|
-
__defNormalProp$
|
|
35111
|
-
if (__getOwnPropSymbols$
|
|
35112
|
-
for (var prop of __getOwnPropSymbols$
|
|
35113
|
-
if (__propIsEnum$
|
|
35114
|
-
__defNormalProp$
|
|
35109
|
+
if (__hasOwnProp$z.call(b, prop))
|
|
35110
|
+
__defNormalProp$p(a, prop, b[prop]);
|
|
35111
|
+
if (__getOwnPropSymbols$z)
|
|
35112
|
+
for (var prop of __getOwnPropSymbols$z(b)) {
|
|
35113
|
+
if (__propIsEnum$z.call(b, prop))
|
|
35114
|
+
__defNormalProp$p(a, prop, b[prop]);
|
|
35115
35115
|
}
|
|
35116
35116
|
return a;
|
|
35117
35117
|
};
|
|
35118
|
-
var __spreadProps$
|
|
35119
|
-
var __objRest$
|
|
35118
|
+
var __spreadProps$m = (a, b) => __defProps$m(a, __getOwnPropDescs$m(b));
|
|
35119
|
+
var __objRest$m = (source, exclude) => {
|
|
35120
35120
|
var target = {};
|
|
35121
35121
|
for (var prop in source)
|
|
35122
|
-
if (__hasOwnProp$
|
|
35122
|
+
if (__hasOwnProp$z.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35123
35123
|
target[prop] = source[prop];
|
|
35124
|
-
if (source != null && __getOwnPropSymbols$
|
|
35125
|
-
for (var prop of __getOwnPropSymbols$
|
|
35126
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
35124
|
+
if (source != null && __getOwnPropSymbols$z)
|
|
35125
|
+
for (var prop of __getOwnPropSymbols$z(source)) {
|
|
35126
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$z.call(source, prop))
|
|
35127
35127
|
target[prop] = source[prop];
|
|
35128
35128
|
}
|
|
35129
35129
|
return target;
|
|
35130
35130
|
};
|
|
35131
35131
|
const useListCarriers = (params) => {
|
|
35132
35132
|
const { client } = useShipEngine();
|
|
35133
|
-
const _a = __spreadValues$
|
|
35134
|
-
return useQuery(__spreadProps$
|
|
35133
|
+
const _a = __spreadValues$p({}, params), { queryFnParams } = _a, rest = __objRest$m(_a, ["queryFnParams"]);
|
|
35134
|
+
return useQuery(__spreadProps$m(__spreadValues$p({}, rest), {
|
|
35135
35135
|
onError,
|
|
35136
35136
|
queryFn: () => client.carriers.list(queryFnParams),
|
|
35137
35137
|
queryKey: ["useListCarriers", queryFnParams],
|
|
@@ -35139,22 +35139,22 @@ const useListCarriers = (params) => {
|
|
|
35139
35139
|
}));
|
|
35140
35140
|
};
|
|
35141
35141
|
|
|
35142
|
-
var __getOwnPropSymbols$
|
|
35143
|
-
var __hasOwnProp$
|
|
35144
|
-
var __propIsEnum$
|
|
35145
|
-
var __objRest$
|
|
35142
|
+
var __getOwnPropSymbols$y = Object.getOwnPropertySymbols;
|
|
35143
|
+
var __hasOwnProp$y = Object.prototype.hasOwnProperty;
|
|
35144
|
+
var __propIsEnum$y = Object.prototype.propertyIsEnumerable;
|
|
35145
|
+
var __objRest$l = (source, exclude) => {
|
|
35146
35146
|
var target = {};
|
|
35147
35147
|
for (var prop in source)
|
|
35148
|
-
if (__hasOwnProp$
|
|
35148
|
+
if (__hasOwnProp$y.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35149
35149
|
target[prop] = source[prop];
|
|
35150
|
-
if (source != null && __getOwnPropSymbols$
|
|
35151
|
-
for (var prop of __getOwnPropSymbols$
|
|
35152
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
35150
|
+
if (source != null && __getOwnPropSymbols$y)
|
|
35151
|
+
for (var prop of __getOwnPropSymbols$y(source)) {
|
|
35152
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$y.call(source, prop))
|
|
35153
35153
|
target[prop] = source[prop];
|
|
35154
35154
|
}
|
|
35155
35155
|
return target;
|
|
35156
35156
|
};
|
|
35157
|
-
var __async$
|
|
35157
|
+
var __async$I = (__this, __arguments, generator) => {
|
|
35158
35158
|
return new Promise((resolve, reject) => {
|
|
35159
35159
|
var fulfilled = (value) => {
|
|
35160
35160
|
try {
|
|
@@ -35178,8 +35178,8 @@ const useUpdateAutoFunding = () => {
|
|
|
35178
35178
|
const { client } = useShipEngine();
|
|
35179
35179
|
const queryClient = useQueryClient();
|
|
35180
35180
|
return useMutation({
|
|
35181
|
-
mutationFn: (_a) => __async$
|
|
35182
|
-
var _b = _a, { carrierId } = _b, options = __objRest$
|
|
35181
|
+
mutationFn: (_a) => __async$I(void 0, null, function* () {
|
|
35182
|
+
var _b = _a, { carrierId } = _b, options = __objRest$l(_b, ["carrierId"]);
|
|
35183
35183
|
const result = yield client.carriers.updateAutoFunding(carrierId, options);
|
|
35184
35184
|
return result.data;
|
|
35185
35185
|
}),
|
|
@@ -35208,7 +35208,7 @@ const useGetZonesByCarrier = (carrierId) => {
|
|
|
35208
35208
|
});
|
|
35209
35209
|
};
|
|
35210
35210
|
|
|
35211
|
-
var __async$
|
|
35211
|
+
var __async$H = (__this, __arguments, generator) => {
|
|
35212
35212
|
return new Promise((resolve, reject) => {
|
|
35213
35213
|
var fulfilled = (value) => {
|
|
35214
35214
|
try {
|
|
@@ -35231,7 +35231,7 @@ var __async$G = (__this, __arguments, generator) => {
|
|
|
35231
35231
|
const useDeleteCarrier = () => {
|
|
35232
35232
|
const { client } = useShipEngine();
|
|
35233
35233
|
return useMutation({
|
|
35234
|
-
mutationFn: (carrierId) => __async$
|
|
35234
|
+
mutationFn: (carrierId) => __async$H(void 0, null, function* () {
|
|
35235
35235
|
const result = yield client.carriers.delete(carrierId);
|
|
35236
35236
|
return result.data;
|
|
35237
35237
|
}),
|
|
@@ -35240,24 +35240,24 @@ const useDeleteCarrier = () => {
|
|
|
35240
35240
|
});
|
|
35241
35241
|
};
|
|
35242
35242
|
|
|
35243
|
-
var __getOwnPropSymbols$
|
|
35244
|
-
var __hasOwnProp$
|
|
35245
|
-
var __propIsEnum$
|
|
35246
|
-
var __objRest$
|
|
35243
|
+
var __getOwnPropSymbols$x = Object.getOwnPropertySymbols;
|
|
35244
|
+
var __hasOwnProp$x = Object.prototype.hasOwnProperty;
|
|
35245
|
+
var __propIsEnum$x = Object.prototype.propertyIsEnumerable;
|
|
35246
|
+
var __objRest$k = (source, exclude) => {
|
|
35247
35247
|
var target = {};
|
|
35248
35248
|
for (var prop in source)
|
|
35249
|
-
if (__hasOwnProp$
|
|
35249
|
+
if (__hasOwnProp$x.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35250
35250
|
target[prop] = source[prop];
|
|
35251
|
-
if (source != null && __getOwnPropSymbols$
|
|
35252
|
-
for (var prop of __getOwnPropSymbols$
|
|
35253
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
35251
|
+
if (source != null && __getOwnPropSymbols$x)
|
|
35252
|
+
for (var prop of __getOwnPropSymbols$x(source)) {
|
|
35253
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$x.call(source, prop))
|
|
35254
35254
|
target[prop] = source[prop];
|
|
35255
35255
|
}
|
|
35256
35256
|
return target;
|
|
35257
35257
|
};
|
|
35258
35258
|
const useGetCarrierConnectionForm = (_params) => {
|
|
35259
35259
|
const { client } = useShipEngine();
|
|
35260
|
-
const _a = _params || {}, { carrierName, enabled = true } = _a, params = __objRest$
|
|
35260
|
+
const _a = _params || {}, { carrierName, enabled = true } = _a, params = __objRest$k(_a, ["carrierName", "enabled"]);
|
|
35261
35261
|
return useQuery({
|
|
35262
35262
|
enabled,
|
|
35263
35263
|
onError,
|
|
@@ -35267,24 +35267,24 @@ const useGetCarrierConnectionForm = (_params) => {
|
|
|
35267
35267
|
});
|
|
35268
35268
|
};
|
|
35269
35269
|
|
|
35270
|
-
var __getOwnPropSymbols$
|
|
35271
|
-
var __hasOwnProp$
|
|
35272
|
-
var __propIsEnum$
|
|
35273
|
-
var __objRest$
|
|
35270
|
+
var __getOwnPropSymbols$w = Object.getOwnPropertySymbols;
|
|
35271
|
+
var __hasOwnProp$w = Object.prototype.hasOwnProperty;
|
|
35272
|
+
var __propIsEnum$w = Object.prototype.propertyIsEnumerable;
|
|
35273
|
+
var __objRest$j = (source, exclude) => {
|
|
35274
35274
|
var target = {};
|
|
35275
35275
|
for (var prop in source)
|
|
35276
|
-
if (__hasOwnProp$
|
|
35276
|
+
if (__hasOwnProp$w.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35277
35277
|
target[prop] = source[prop];
|
|
35278
|
-
if (source != null && __getOwnPropSymbols$
|
|
35279
|
-
for (var prop of __getOwnPropSymbols$
|
|
35280
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
35278
|
+
if (source != null && __getOwnPropSymbols$w)
|
|
35279
|
+
for (var prop of __getOwnPropSymbols$w(source)) {
|
|
35280
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$w.call(source, prop))
|
|
35281
35281
|
target[prop] = source[prop];
|
|
35282
35282
|
}
|
|
35283
35283
|
return target;
|
|
35284
35284
|
};
|
|
35285
35285
|
const useListCarrierConnections = (_params) => {
|
|
35286
35286
|
const { client } = useShipEngine();
|
|
35287
|
-
const _a = _params || {}, { enabled = true } = _a, params = __objRest$
|
|
35287
|
+
const _a = _params || {}, { enabled = true } = _a, params = __objRest$j(_a, ["enabled"]);
|
|
35288
35288
|
return useQuery({
|
|
35289
35289
|
enabled,
|
|
35290
35290
|
onError,
|
|
@@ -35294,7 +35294,7 @@ const useListCarrierConnections = (_params) => {
|
|
|
35294
35294
|
});
|
|
35295
35295
|
};
|
|
35296
35296
|
|
|
35297
|
-
var __async$
|
|
35297
|
+
var __async$G = (__this, __arguments, generator) => {
|
|
35298
35298
|
return new Promise((resolve, reject) => {
|
|
35299
35299
|
var fulfilled = (value) => {
|
|
35300
35300
|
try {
|
|
@@ -35317,7 +35317,7 @@ var __async$F = (__this, __arguments, generator) => {
|
|
|
35317
35317
|
const useConnectCarrierAccount = () => {
|
|
35318
35318
|
const { client } = useShipEngine();
|
|
35319
35319
|
return useMutation({
|
|
35320
|
-
mutationFn: (_0) => __async$
|
|
35320
|
+
mutationFn: (_0) => __async$G(void 0, [_0], function* ({ carrierName, formData }) {
|
|
35321
35321
|
const result = yield client.connections.connectCarrier(carrierName, formData);
|
|
35322
35322
|
return result.data;
|
|
35323
35323
|
}),
|
|
@@ -35337,33 +35337,33 @@ const useCarrierConnectionsServicesList = (carrierCode) => {
|
|
|
35337
35337
|
});
|
|
35338
35338
|
};
|
|
35339
35339
|
|
|
35340
|
-
var __defProp$
|
|
35341
|
-
var __defProps$
|
|
35342
|
-
var __getOwnPropDescs$
|
|
35343
|
-
var __getOwnPropSymbols$
|
|
35344
|
-
var __hasOwnProp$
|
|
35345
|
-
var __propIsEnum$
|
|
35346
|
-
var __defNormalProp$
|
|
35347
|
-
var __spreadValues$
|
|
35340
|
+
var __defProp$o = Object.defineProperty;
|
|
35341
|
+
var __defProps$l = Object.defineProperties;
|
|
35342
|
+
var __getOwnPropDescs$l = Object.getOwnPropertyDescriptors;
|
|
35343
|
+
var __getOwnPropSymbols$v = Object.getOwnPropertySymbols;
|
|
35344
|
+
var __hasOwnProp$v = Object.prototype.hasOwnProperty;
|
|
35345
|
+
var __propIsEnum$v = Object.prototype.propertyIsEnumerable;
|
|
35346
|
+
var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
35347
|
+
var __spreadValues$o = (a, b) => {
|
|
35348
35348
|
for (var prop in b || (b = {}))
|
|
35349
|
-
if (__hasOwnProp$
|
|
35350
|
-
__defNormalProp$
|
|
35351
|
-
if (__getOwnPropSymbols$
|
|
35352
|
-
for (var prop of __getOwnPropSymbols$
|
|
35353
|
-
if (__propIsEnum$
|
|
35354
|
-
__defNormalProp$
|
|
35349
|
+
if (__hasOwnProp$v.call(b, prop))
|
|
35350
|
+
__defNormalProp$o(a, prop, b[prop]);
|
|
35351
|
+
if (__getOwnPropSymbols$v)
|
|
35352
|
+
for (var prop of __getOwnPropSymbols$v(b)) {
|
|
35353
|
+
if (__propIsEnum$v.call(b, prop))
|
|
35354
|
+
__defNormalProp$o(a, prop, b[prop]);
|
|
35355
35355
|
}
|
|
35356
35356
|
return a;
|
|
35357
35357
|
};
|
|
35358
|
-
var __spreadProps$
|
|
35359
|
-
var __objRest$
|
|
35358
|
+
var __spreadProps$l = (a, b) => __defProps$l(a, __getOwnPropDescs$l(b));
|
|
35359
|
+
var __objRest$i = (source, exclude) => {
|
|
35360
35360
|
var target = {};
|
|
35361
35361
|
for (var prop in source)
|
|
35362
|
-
if (__hasOwnProp$
|
|
35362
|
+
if (__hasOwnProp$v.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35363
35363
|
target[prop] = source[prop];
|
|
35364
|
-
if (source != null && __getOwnPropSymbols$
|
|
35365
|
-
for (var prop of __getOwnPropSymbols$
|
|
35366
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
35364
|
+
if (source != null && __getOwnPropSymbols$v)
|
|
35365
|
+
for (var prop of __getOwnPropSymbols$v(source)) {
|
|
35366
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$v.call(source, prop))
|
|
35367
35367
|
target[prop] = source[prop];
|
|
35368
35368
|
}
|
|
35369
35369
|
return target;
|
|
@@ -35371,12 +35371,12 @@ var __objRest$h = (source, exclude) => {
|
|
|
35371
35371
|
const useGetConnectionsCarrierSettings = (_a) => {
|
|
35372
35372
|
var _b = _a, {
|
|
35373
35373
|
queryFnParams
|
|
35374
|
-
} = _b, params = __objRest$
|
|
35374
|
+
} = _b, params = __objRest$i(_b, [
|
|
35375
35375
|
"queryFnParams"
|
|
35376
35376
|
]);
|
|
35377
35377
|
const { client } = useShipEngine();
|
|
35378
35378
|
const { carrierName, carrierId } = queryFnParams;
|
|
35379
|
-
return useQuery(__spreadProps$
|
|
35379
|
+
return useQuery(__spreadProps$l(__spreadValues$o({}, params), {
|
|
35380
35380
|
onError,
|
|
35381
35381
|
queryFn: () => client.connections.getCarrierSettings(carrierName, carrierId),
|
|
35382
35382
|
queryKey: ["useGetConnectionsCarrierSettings", carrierName, carrierId],
|
|
@@ -35384,26 +35384,26 @@ const useGetConnectionsCarrierSettings = (_a) => {
|
|
|
35384
35384
|
}));
|
|
35385
35385
|
};
|
|
35386
35386
|
|
|
35387
|
-
var __defProp$
|
|
35388
|
-
var __defProps$
|
|
35389
|
-
var __getOwnPropDescs$
|
|
35390
|
-
var __getOwnPropSymbols$
|
|
35391
|
-
var __hasOwnProp$
|
|
35392
|
-
var __propIsEnum$
|
|
35393
|
-
var __defNormalProp$
|
|
35394
|
-
var __spreadValues$
|
|
35387
|
+
var __defProp$n = Object.defineProperty;
|
|
35388
|
+
var __defProps$k = Object.defineProperties;
|
|
35389
|
+
var __getOwnPropDescs$k = Object.getOwnPropertyDescriptors;
|
|
35390
|
+
var __getOwnPropSymbols$u = Object.getOwnPropertySymbols;
|
|
35391
|
+
var __hasOwnProp$u = Object.prototype.hasOwnProperty;
|
|
35392
|
+
var __propIsEnum$u = Object.prototype.propertyIsEnumerable;
|
|
35393
|
+
var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
35394
|
+
var __spreadValues$n = (a, b) => {
|
|
35395
35395
|
for (var prop in b || (b = {}))
|
|
35396
|
-
if (__hasOwnProp$
|
|
35397
|
-
__defNormalProp$
|
|
35398
|
-
if (__getOwnPropSymbols$
|
|
35399
|
-
for (var prop of __getOwnPropSymbols$
|
|
35400
|
-
if (__propIsEnum$
|
|
35401
|
-
__defNormalProp$
|
|
35396
|
+
if (__hasOwnProp$u.call(b, prop))
|
|
35397
|
+
__defNormalProp$n(a, prop, b[prop]);
|
|
35398
|
+
if (__getOwnPropSymbols$u)
|
|
35399
|
+
for (var prop of __getOwnPropSymbols$u(b)) {
|
|
35400
|
+
if (__propIsEnum$u.call(b, prop))
|
|
35401
|
+
__defNormalProp$n(a, prop, b[prop]);
|
|
35402
35402
|
}
|
|
35403
35403
|
return a;
|
|
35404
35404
|
};
|
|
35405
|
-
var __spreadProps$
|
|
35406
|
-
var __async$
|
|
35405
|
+
var __spreadProps$k = (a, b) => __defProps$k(a, __getOwnPropDescs$k(b));
|
|
35406
|
+
var __async$F = (__this, __arguments, generator) => {
|
|
35407
35407
|
return new Promise((resolve, reject) => {
|
|
35408
35408
|
var fulfilled = (value) => {
|
|
35409
35409
|
try {
|
|
@@ -35425,8 +35425,8 @@ var __async$E = (__this, __arguments, generator) => {
|
|
|
35425
35425
|
};
|
|
35426
35426
|
const useUpdateConnectionsCarrierSettings = (params) => {
|
|
35427
35427
|
const { client } = useShipEngine();
|
|
35428
|
-
return useMutation(__spreadProps$
|
|
35429
|
-
mutationFn: (_0) => __async$
|
|
35428
|
+
return useMutation(__spreadProps$k(__spreadValues$n({}, params), {
|
|
35429
|
+
mutationFn: (_0) => __async$F(void 0, [_0], function* ({
|
|
35430
35430
|
carrierName,
|
|
35431
35431
|
carrierId,
|
|
35432
35432
|
formData
|
|
@@ -35453,7 +35453,7 @@ const useListCustomPackageTypes = () => {
|
|
|
35453
35453
|
});
|
|
35454
35454
|
};
|
|
35455
35455
|
|
|
35456
|
-
var __async$
|
|
35456
|
+
var __async$E = (__this, __arguments, generator) => {
|
|
35457
35457
|
return new Promise((resolve, reject) => {
|
|
35458
35458
|
var fulfilled = (value) => {
|
|
35459
35459
|
try {
|
|
@@ -35476,7 +35476,7 @@ var __async$D = (__this, __arguments, generator) => {
|
|
|
35476
35476
|
const useCreateFundingSource = () => {
|
|
35477
35477
|
const { client } = useShipEngine();
|
|
35478
35478
|
return useMutation({
|
|
35479
|
-
mutationFn: (fundingSource) => __async$
|
|
35479
|
+
mutationFn: (fundingSource) => __async$E(void 0, null, function* () {
|
|
35480
35480
|
const result = yield client.fundingSources.create(fundingSource);
|
|
35481
35481
|
return result.data;
|
|
35482
35482
|
}),
|
|
@@ -35485,7 +35485,7 @@ const useCreateFundingSource = () => {
|
|
|
35485
35485
|
});
|
|
35486
35486
|
};
|
|
35487
35487
|
|
|
35488
|
-
var __async$
|
|
35488
|
+
var __async$D = (__this, __arguments, generator) => {
|
|
35489
35489
|
return new Promise((resolve, reject) => {
|
|
35490
35490
|
var fulfilled = (value) => {
|
|
35491
35491
|
try {
|
|
@@ -35508,7 +35508,7 @@ var __async$C = (__this, __arguments, generator) => {
|
|
|
35508
35508
|
const useFundingSourcesAddFunds = () => {
|
|
35509
35509
|
const { client } = useShipEngine();
|
|
35510
35510
|
return useMutation({
|
|
35511
|
-
mutationFn: (_0) => __async$
|
|
35511
|
+
mutationFn: (_0) => __async$D(void 0, [_0], function* ({ funds, fundingSourceId }) {
|
|
35512
35512
|
const result = yield client.fundingSources.addFunds(funds, fundingSourceId);
|
|
35513
35513
|
return result.data;
|
|
35514
35514
|
}),
|
|
@@ -35537,7 +35537,7 @@ const useListFundingSources = () => {
|
|
|
35537
35537
|
});
|
|
35538
35538
|
};
|
|
35539
35539
|
|
|
35540
|
-
var __async$
|
|
35540
|
+
var __async$C = (__this, __arguments, generator) => {
|
|
35541
35541
|
return new Promise((resolve, reject) => {
|
|
35542
35542
|
var fulfilled = (value) => {
|
|
35543
35543
|
try {
|
|
@@ -35560,7 +35560,7 @@ var __async$B = (__this, __arguments, generator) => {
|
|
|
35560
35560
|
const useRegisterCarrier = () => {
|
|
35561
35561
|
const { client } = useShipEngine();
|
|
35562
35562
|
return useMutation({
|
|
35563
|
-
mutationFn: (carrier) => __async$
|
|
35563
|
+
mutationFn: (carrier) => __async$C(void 0, null, function* () {
|
|
35564
35564
|
const result = yield client.fundingSources.registerCarrier(carrier);
|
|
35565
35565
|
return result.data;
|
|
35566
35566
|
}),
|
|
@@ -35569,7 +35569,7 @@ const useRegisterCarrier = () => {
|
|
|
35569
35569
|
});
|
|
35570
35570
|
};
|
|
35571
35571
|
|
|
35572
|
-
var __async$
|
|
35572
|
+
var __async$B = (__this, __arguments, generator) => {
|
|
35573
35573
|
return new Promise((resolve, reject) => {
|
|
35574
35574
|
var fulfilled = (value) => {
|
|
35575
35575
|
try {
|
|
@@ -35592,7 +35592,7 @@ var __async$A = (__this, __arguments, generator) => {
|
|
|
35592
35592
|
const useUpdateFundingSource = () => {
|
|
35593
35593
|
const { client } = useShipEngine();
|
|
35594
35594
|
return useMutation({
|
|
35595
|
-
mutationFn: (_0) => __async$
|
|
35595
|
+
mutationFn: (_0) => __async$B(void 0, [_0], function* ({
|
|
35596
35596
|
billingInfo,
|
|
35597
35597
|
creditCardInfo,
|
|
35598
35598
|
fundingSourceId
|
|
@@ -35631,29 +35631,29 @@ const useGetFundingSourceTransactions = (fundingSourceId, params) => {
|
|
|
35631
35631
|
});
|
|
35632
35632
|
};
|
|
35633
35633
|
|
|
35634
|
-
var __defProp$
|
|
35635
|
-
var __defProps$
|
|
35636
|
-
var __getOwnPropDescs$
|
|
35637
|
-
var __getOwnPropSymbols$
|
|
35638
|
-
var __hasOwnProp$
|
|
35639
|
-
var __propIsEnum$
|
|
35640
|
-
var __defNormalProp$
|
|
35641
|
-
var __spreadValues$
|
|
35634
|
+
var __defProp$m = Object.defineProperty;
|
|
35635
|
+
var __defProps$j = Object.defineProperties;
|
|
35636
|
+
var __getOwnPropDescs$j = Object.getOwnPropertyDescriptors;
|
|
35637
|
+
var __getOwnPropSymbols$t = Object.getOwnPropertySymbols;
|
|
35638
|
+
var __hasOwnProp$t = Object.prototype.hasOwnProperty;
|
|
35639
|
+
var __propIsEnum$t = Object.prototype.propertyIsEnumerable;
|
|
35640
|
+
var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
35641
|
+
var __spreadValues$m = (a, b) => {
|
|
35642
35642
|
for (var prop in b || (b = {}))
|
|
35643
|
-
if (__hasOwnProp$
|
|
35644
|
-
__defNormalProp$
|
|
35645
|
-
if (__getOwnPropSymbols$
|
|
35646
|
-
for (var prop of __getOwnPropSymbols$
|
|
35647
|
-
if (__propIsEnum$
|
|
35648
|
-
__defNormalProp$
|
|
35643
|
+
if (__hasOwnProp$t.call(b, prop))
|
|
35644
|
+
__defNormalProp$m(a, prop, b[prop]);
|
|
35645
|
+
if (__getOwnPropSymbols$t)
|
|
35646
|
+
for (var prop of __getOwnPropSymbols$t(b)) {
|
|
35647
|
+
if (__propIsEnum$t.call(b, prop))
|
|
35648
|
+
__defNormalProp$m(a, prop, b[prop]);
|
|
35649
35649
|
}
|
|
35650
35650
|
return a;
|
|
35651
35651
|
};
|
|
35652
|
-
var __spreadProps$
|
|
35652
|
+
var __spreadProps$j = (a, b) => __defProps$j(a, __getOwnPropDescs$j(b));
|
|
35653
35653
|
const useGetInsuranceFundingSourceAcceptedTerms = (params) => {
|
|
35654
35654
|
const { client } = useShipEngine();
|
|
35655
|
-
const queryParams = __spreadValues$
|
|
35656
|
-
return useQuery(__spreadProps$
|
|
35655
|
+
const queryParams = __spreadValues$m({}, params);
|
|
35656
|
+
return useQuery(__spreadProps$j(__spreadValues$m({}, queryParams), {
|
|
35657
35657
|
onError,
|
|
35658
35658
|
queryFn: () => client.fundingSources.insuranceAcceptedTerms(),
|
|
35659
35659
|
queryKey: ["useGetInsuranceFundingSourceAcceptedTerms"],
|
|
@@ -35676,22 +35676,22 @@ const useGetInsuranceAccount = (insuranceProvider) => {
|
|
|
35676
35676
|
});
|
|
35677
35677
|
};
|
|
35678
35678
|
|
|
35679
|
-
var __getOwnPropSymbols$
|
|
35680
|
-
var __hasOwnProp$
|
|
35681
|
-
var __propIsEnum$
|
|
35682
|
-
var __objRest$
|
|
35679
|
+
var __getOwnPropSymbols$s = Object.getOwnPropertySymbols;
|
|
35680
|
+
var __hasOwnProp$s = Object.prototype.hasOwnProperty;
|
|
35681
|
+
var __propIsEnum$s = Object.prototype.propertyIsEnumerable;
|
|
35682
|
+
var __objRest$h = (source, exclude) => {
|
|
35683
35683
|
var target = {};
|
|
35684
35684
|
for (var prop in source)
|
|
35685
|
-
if (__hasOwnProp$
|
|
35685
|
+
if (__hasOwnProp$s.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35686
35686
|
target[prop] = source[prop];
|
|
35687
|
-
if (source != null && __getOwnPropSymbols$
|
|
35688
|
-
for (var prop of __getOwnPropSymbols$
|
|
35689
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum$
|
|
35687
|
+
if (source != null && __getOwnPropSymbols$s)
|
|
35688
|
+
for (var prop of __getOwnPropSymbols$s(source)) {
|
|
35689
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$s.call(source, prop))
|
|
35690
35690
|
target[prop] = source[prop];
|
|
35691
35691
|
}
|
|
35692
35692
|
return target;
|
|
35693
35693
|
};
|
|
35694
|
-
var __async$
|
|
35694
|
+
var __async$A = (__this, __arguments, generator) => {
|
|
35695
35695
|
return new Promise((resolve, reject) => {
|
|
35696
35696
|
var fulfilled = (value) => {
|
|
35697
35697
|
try {
|
|
@@ -35714,8 +35714,8 @@ var __async$z = (__this, __arguments, generator) => {
|
|
|
35714
35714
|
const useAddInsuranceFunds = () => {
|
|
35715
35715
|
const { client } = useShipEngine();
|
|
35716
35716
|
return useMutation({
|
|
35717
|
-
mutationFn: (_a) => __async$
|
|
35718
|
-
var _b = _a, { insuranceProvider } = _b, rest = __objRest$
|
|
35717
|
+
mutationFn: (_a) => __async$A(void 0, null, function* () {
|
|
35718
|
+
var _b = _a, { insuranceProvider } = _b, rest = __objRest$h(_b, ["insuranceProvider"]);
|
|
35719
35719
|
const result = yield client.insurance.addFunds(insuranceProvider, rest);
|
|
35720
35720
|
return result.data;
|
|
35721
35721
|
}),
|
|
@@ -35724,6 +35724,57 @@ const useAddInsuranceFunds = () => {
|
|
|
35724
35724
|
});
|
|
35725
35725
|
};
|
|
35726
35726
|
|
|
35727
|
+
var __defProp$l = Object.defineProperty;
|
|
35728
|
+
var __defProps$i = Object.defineProperties;
|
|
35729
|
+
var __getOwnPropDescs$i = Object.getOwnPropertyDescriptors;
|
|
35730
|
+
var __getOwnPropSymbols$r = Object.getOwnPropertySymbols;
|
|
35731
|
+
var __hasOwnProp$r = Object.prototype.hasOwnProperty;
|
|
35732
|
+
var __propIsEnum$r = Object.prototype.propertyIsEnumerable;
|
|
35733
|
+
var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
35734
|
+
var __spreadValues$l = (a, b) => {
|
|
35735
|
+
for (var prop in b || (b = {}))
|
|
35736
|
+
if (__hasOwnProp$r.call(b, prop))
|
|
35737
|
+
__defNormalProp$l(a, prop, b[prop]);
|
|
35738
|
+
if (__getOwnPropSymbols$r)
|
|
35739
|
+
for (var prop of __getOwnPropSymbols$r(b)) {
|
|
35740
|
+
if (__propIsEnum$r.call(b, prop))
|
|
35741
|
+
__defNormalProp$l(a, prop, b[prop]);
|
|
35742
|
+
}
|
|
35743
|
+
return a;
|
|
35744
|
+
};
|
|
35745
|
+
var __spreadProps$i = (a, b) => __defProps$i(a, __getOwnPropDescs$i(b));
|
|
35746
|
+
var __async$z = (__this, __arguments, generator) => {
|
|
35747
|
+
return new Promise((resolve, reject) => {
|
|
35748
|
+
var fulfilled = (value) => {
|
|
35749
|
+
try {
|
|
35750
|
+
step(generator.next(value));
|
|
35751
|
+
} catch (e) {
|
|
35752
|
+
reject(e);
|
|
35753
|
+
}
|
|
35754
|
+
};
|
|
35755
|
+
var rejected = (value) => {
|
|
35756
|
+
try {
|
|
35757
|
+
step(generator.throw(value));
|
|
35758
|
+
} catch (e) {
|
|
35759
|
+
reject(e);
|
|
35760
|
+
}
|
|
35761
|
+
};
|
|
35762
|
+
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
35763
|
+
step((generator = generator.apply(__this, __arguments)).next());
|
|
35764
|
+
});
|
|
35765
|
+
};
|
|
35766
|
+
const useCreateInvoiceAddress = (params) => {
|
|
35767
|
+
const { client } = useShipEngine();
|
|
35768
|
+
return useMutation(__spreadProps$i(__spreadValues$l({}, params), {
|
|
35769
|
+
mutationFn: (invoiceAddress) => __async$z(void 0, null, function* () {
|
|
35770
|
+
const result = yield client.invoiceAddress.create(invoiceAddress);
|
|
35771
|
+
return result.data;
|
|
35772
|
+
}),
|
|
35773
|
+
mutationKey: ["useCreateInvoiceAddress"],
|
|
35774
|
+
onError
|
|
35775
|
+
}));
|
|
35776
|
+
};
|
|
35777
|
+
|
|
35727
35778
|
var __defProp$k = Object.defineProperty;
|
|
35728
35779
|
var __defProps$h = Object.defineProperties;
|
|
35729
35780
|
var __getOwnPropDescs$h = Object.getOwnPropertyDescriptors;
|
|
@@ -35763,14 +35814,14 @@ var __async$y = (__this, __arguments, generator) => {
|
|
|
35763
35814
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
35764
35815
|
});
|
|
35765
35816
|
};
|
|
35766
|
-
const
|
|
35817
|
+
const useUpdateInvoiceAddress = (params) => {
|
|
35767
35818
|
const { client } = useShipEngine();
|
|
35768
35819
|
return useMutation(__spreadProps$h(__spreadValues$k({}, params), {
|
|
35769
35820
|
mutationFn: (invoiceAddress) => __async$y(void 0, null, function* () {
|
|
35770
|
-
const result = yield client.invoiceAddress.
|
|
35821
|
+
const result = yield client.invoiceAddress.update(invoiceAddress);
|
|
35771
35822
|
return result.data;
|
|
35772
35823
|
}),
|
|
35773
|
-
mutationKey: ["
|
|
35824
|
+
mutationKey: ["useUpdateInvoiceAddress"],
|
|
35774
35825
|
onError
|
|
35775
35826
|
}));
|
|
35776
35827
|
};
|
|
@@ -35794,6 +35845,31 @@ var __spreadValues$j = (a, b) => {
|
|
|
35794
35845
|
return a;
|
|
35795
35846
|
};
|
|
35796
35847
|
var __spreadProps$g = (a, b) => __defProps$g(a, __getOwnPropDescs$g(b));
|
|
35848
|
+
const useGetInvoiceAddress = (params) => {
|
|
35849
|
+
const { client } = useShipEngine();
|
|
35850
|
+
return useQuery(__spreadProps$g(__spreadValues$j({}, params), {
|
|
35851
|
+
onError,
|
|
35852
|
+
queryFn: () => client.invoiceAddress.get(),
|
|
35853
|
+
queryKey: ["useGetInvoiceAddress"],
|
|
35854
|
+
select: (result) => result.data
|
|
35855
|
+
}));
|
|
35856
|
+
};
|
|
35857
|
+
|
|
35858
|
+
var __getOwnPropSymbols$o = Object.getOwnPropertySymbols;
|
|
35859
|
+
var __hasOwnProp$o = Object.prototype.hasOwnProperty;
|
|
35860
|
+
var __propIsEnum$o = Object.prototype.propertyIsEnumerable;
|
|
35861
|
+
var __objRest$g = (source, exclude) => {
|
|
35862
|
+
var target = {};
|
|
35863
|
+
for (var prop in source)
|
|
35864
|
+
if (__hasOwnProp$o.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
35865
|
+
target[prop] = source[prop];
|
|
35866
|
+
if (source != null && __getOwnPropSymbols$o)
|
|
35867
|
+
for (var prop of __getOwnPropSymbols$o(source)) {
|
|
35868
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum$o.call(source, prop))
|
|
35869
|
+
target[prop] = source[prop];
|
|
35870
|
+
}
|
|
35871
|
+
return target;
|
|
35872
|
+
};
|
|
35797
35873
|
var __async$x = (__this, __arguments, generator) => {
|
|
35798
35874
|
return new Promise((resolve, reject) => {
|
|
35799
35875
|
var fulfilled = (value) => {
|
|
@@ -35814,50 +35890,53 @@ var __async$x = (__this, __arguments, generator) => {
|
|
|
35814
35890
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
35815
35891
|
});
|
|
35816
35892
|
};
|
|
35817
|
-
const
|
|
35893
|
+
const useCreateLabel = () => {
|
|
35818
35894
|
const { client } = useShipEngine();
|
|
35819
|
-
return useMutation(
|
|
35820
|
-
mutationFn: (
|
|
35821
|
-
|
|
35895
|
+
return useMutation({
|
|
35896
|
+
mutationFn: (_a) => __async$x(void 0, null, function* () {
|
|
35897
|
+
var _b = _a, { rateId } = _b, options = __objRest$g(_b, ["rateId"]);
|
|
35898
|
+
const result = yield client.labels.createByRateId(rateId, options);
|
|
35822
35899
|
return result.data;
|
|
35823
35900
|
}),
|
|
35824
|
-
mutationKey: ["
|
|
35901
|
+
mutationKey: ["useCreateLabel"],
|
|
35825
35902
|
onError
|
|
35826
|
-
})
|
|
35903
|
+
});
|
|
35904
|
+
};
|
|
35905
|
+
|
|
35906
|
+
const useGetLabel = (labelId) => {
|
|
35907
|
+
const { client } = useShipEngine();
|
|
35908
|
+
return useQuery({
|
|
35909
|
+
enabled: labelId !== void 0,
|
|
35910
|
+
onError,
|
|
35911
|
+
queryFn: () => {
|
|
35912
|
+
if (labelId)
|
|
35913
|
+
return client.labels.get(labelId);
|
|
35914
|
+
return Promise.reject(new Error("labelId is require"));
|
|
35915
|
+
},
|
|
35916
|
+
queryKey: ["useGetLabel", labelId],
|
|
35917
|
+
select: (result) => result.data
|
|
35918
|
+
});
|
|
35827
35919
|
};
|
|
35828
35920
|
|
|
35829
35921
|
var __defProp$i = Object.defineProperty;
|
|
35830
35922
|
var __defProps$f = Object.defineProperties;
|
|
35831
35923
|
var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
|
|
35832
|
-
var __getOwnPropSymbols$
|
|
35833
|
-
var __hasOwnProp$
|
|
35834
|
-
var __propIsEnum$
|
|
35924
|
+
var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
|
|
35925
|
+
var __hasOwnProp$n = Object.prototype.hasOwnProperty;
|
|
35926
|
+
var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
|
|
35835
35927
|
var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
35836
35928
|
var __spreadValues$i = (a, b) => {
|
|
35837
35929
|
for (var prop in b || (b = {}))
|
|
35838
|
-
if (__hasOwnProp$
|
|
35930
|
+
if (__hasOwnProp$n.call(b, prop))
|
|
35839
35931
|
__defNormalProp$i(a, prop, b[prop]);
|
|
35840
|
-
if (__getOwnPropSymbols$
|
|
35841
|
-
for (var prop of __getOwnPropSymbols$
|
|
35842
|
-
if (__propIsEnum$
|
|
35932
|
+
if (__getOwnPropSymbols$n)
|
|
35933
|
+
for (var prop of __getOwnPropSymbols$n(b)) {
|
|
35934
|
+
if (__propIsEnum$n.call(b, prop))
|
|
35843
35935
|
__defNormalProp$i(a, prop, b[prop]);
|
|
35844
35936
|
}
|
|
35845
35937
|
return a;
|
|
35846
35938
|
};
|
|
35847
35939
|
var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
|
|
35848
|
-
const useGetInvoiceAddress = (params) => {
|
|
35849
|
-
const { client } = useShipEngine();
|
|
35850
|
-
return useQuery(__spreadProps$f(__spreadValues$i({}, params), {
|
|
35851
|
-
onError,
|
|
35852
|
-
queryFn: () => client.invoiceAddress.get(),
|
|
35853
|
-
queryKey: ["useGetInvoiceAddress"],
|
|
35854
|
-
select: (result) => result.data
|
|
35855
|
-
}));
|
|
35856
|
-
};
|
|
35857
|
-
|
|
35858
|
-
var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
|
|
35859
|
-
var __hasOwnProp$n = Object.prototype.hasOwnProperty;
|
|
35860
|
-
var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
|
|
35861
35940
|
var __objRest$f = (source, exclude) => {
|
|
35862
35941
|
var target = {};
|
|
35863
35942
|
for (var prop in source)
|
|
@@ -35870,6 +35949,17 @@ var __objRest$f = (source, exclude) => {
|
|
|
35870
35949
|
}
|
|
35871
35950
|
return target;
|
|
35872
35951
|
};
|
|
35952
|
+
const useListLabels = (params) => {
|
|
35953
|
+
const { client } = useShipEngine();
|
|
35954
|
+
const _a = __spreadValues$i({}, params), { queryFnParams } = _a, rest = __objRest$f(_a, ["queryFnParams"]);
|
|
35955
|
+
return useQuery(__spreadProps$f(__spreadValues$i({}, rest), {
|
|
35956
|
+
onError,
|
|
35957
|
+
queryFn: () => client.labels.list(queryFnParams),
|
|
35958
|
+
queryKey: ["useListLabels", params],
|
|
35959
|
+
select: (result) => result.data
|
|
35960
|
+
}));
|
|
35961
|
+
};
|
|
35962
|
+
|
|
35873
35963
|
var __async$w = (__this, __arguments, generator) => {
|
|
35874
35964
|
return new Promise((resolve, reject) => {
|
|
35875
35965
|
var fulfilled = (value) => {
|
|
@@ -35890,34 +35980,18 @@ var __async$w = (__this, __arguments, generator) => {
|
|
|
35890
35980
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
35891
35981
|
});
|
|
35892
35982
|
};
|
|
35893
|
-
const
|
|
35983
|
+
const useVoidLabel = () => {
|
|
35894
35984
|
const { client } = useShipEngine();
|
|
35895
35985
|
return useMutation({
|
|
35896
|
-
mutationFn: (
|
|
35897
|
-
|
|
35898
|
-
const result = yield client.labels.createByRateId(rateId, options);
|
|
35986
|
+
mutationFn: (labelId) => __async$w(void 0, null, function* () {
|
|
35987
|
+
const result = yield client.labels.void(labelId);
|
|
35899
35988
|
return result.data;
|
|
35900
35989
|
}),
|
|
35901
|
-
mutationKey: ["
|
|
35990
|
+
mutationKey: ["useVoidLabel"],
|
|
35902
35991
|
onError
|
|
35903
35992
|
});
|
|
35904
35993
|
};
|
|
35905
35994
|
|
|
35906
|
-
const useGetLabel = (labelId) => {
|
|
35907
|
-
const { client } = useShipEngine();
|
|
35908
|
-
return useQuery({
|
|
35909
|
-
enabled: labelId !== void 0,
|
|
35910
|
-
onError,
|
|
35911
|
-
queryFn: () => {
|
|
35912
|
-
if (labelId)
|
|
35913
|
-
return client.labels.get(labelId);
|
|
35914
|
-
return Promise.reject(new Error("labelId is require"));
|
|
35915
|
-
},
|
|
35916
|
-
queryKey: ["useGetLabel", labelId],
|
|
35917
|
-
select: (result) => result.data
|
|
35918
|
-
});
|
|
35919
|
-
};
|
|
35920
|
-
|
|
35921
35995
|
var __defProp$h = Object.defineProperty;
|
|
35922
35996
|
var __defProps$e = Object.defineProperties;
|
|
35923
35997
|
var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
|
|
@@ -35949,17 +36023,6 @@ var __objRest$e = (source, exclude) => {
|
|
|
35949
36023
|
}
|
|
35950
36024
|
return target;
|
|
35951
36025
|
};
|
|
35952
|
-
const useListLabels = (params) => {
|
|
35953
|
-
const { client } = useShipEngine();
|
|
35954
|
-
const _a = __spreadValues$h({}, params), { queryFnParams } = _a, rest = __objRest$e(_a, ["queryFnParams"]);
|
|
35955
|
-
return useQuery(__spreadProps$e(__spreadValues$h({}, rest), {
|
|
35956
|
-
onError,
|
|
35957
|
-
queryFn: () => client.labels.list(queryFnParams),
|
|
35958
|
-
queryKey: ["useListLabels", params],
|
|
35959
|
-
select: (result) => result.data
|
|
35960
|
-
}));
|
|
35961
|
-
};
|
|
35962
|
-
|
|
35963
36026
|
var __async$v = (__this, __arguments, generator) => {
|
|
35964
36027
|
return new Promise((resolve, reject) => {
|
|
35965
36028
|
var fulfilled = (value) => {
|
|
@@ -35980,16 +36043,30 @@ var __async$v = (__this, __arguments, generator) => {
|
|
|
35980
36043
|
step((generator = generator.apply(__this, __arguments)).next());
|
|
35981
36044
|
});
|
|
35982
36045
|
};
|
|
35983
|
-
const
|
|
36046
|
+
const useListLabelsInfinite = (params) => {
|
|
35984
36047
|
const { client } = useShipEngine();
|
|
35985
|
-
|
|
35986
|
-
|
|
35987
|
-
|
|
35988
|
-
|
|
36048
|
+
const _a = __spreadValues$h({}, params), { queryFnParams } = _a, rest = __objRest$e(_a, ["queryFnParams"]);
|
|
36049
|
+
return useInfiniteQuery(__spreadProps$e(__spreadValues$h({}, rest), {
|
|
36050
|
+
getNextPageParam: (lastPage) => {
|
|
36051
|
+
if (lastPage.page < lastPage.pages) {
|
|
36052
|
+
return lastPage.page + 1;
|
|
36053
|
+
}
|
|
36054
|
+
return void 0;
|
|
36055
|
+
},
|
|
36056
|
+
onError,
|
|
36057
|
+
queryFn: (_0) => __async$v(void 0, [_0], function* ({ pageParam = 1 }) {
|
|
36058
|
+
const response = yield client.labels.list(__spreadProps$e(__spreadValues$h({}, queryFnParams), { page: pageParam }));
|
|
36059
|
+
return response.data;
|
|
35989
36060
|
}),
|
|
35990
|
-
|
|
35991
|
-
|
|
35992
|
-
|
|
36061
|
+
queryKey: ["useListLabelsInfinite", params],
|
|
36062
|
+
select: (data) => {
|
|
36063
|
+
return {
|
|
36064
|
+
labels: data.pages.flatMap((page) => page.labels),
|
|
36065
|
+
pageParams: data.pageParams,
|
|
36066
|
+
pages: data.pages
|
|
36067
|
+
};
|
|
36068
|
+
}
|
|
36069
|
+
}));
|
|
35993
36070
|
};
|
|
35994
36071
|
|
|
35995
36072
|
var __defProp$g = Object.defineProperty;
|
|
@@ -38950,4 +39027,4 @@ const alchemy = {
|
|
|
38950
39027
|
createElement
|
|
38951
39028
|
};
|
|
38952
39029
|
|
|
38953
|
-
export { AccountSettingsAPI, AddressesAPI, AlchemyContext, AlchemyProvider, AlchemyTestProvider, CarriersAPI, CodedError, ConfirmationType, ConnectionsAPI, CreditCardVendor, Currency, CustomPackagesAPI, CustomsContentsType, CustomsNonDeliveryType, Element, ErrorBoundary, FundingSourcesAPI, InsuranceAPI, InsuranceProviderType, InvoiceAddressAPI, LabelsAPI, MetadataCapability, MetadataRequirement, MetadataSatisfyingFormTypes, MovementIndicator, OrderSourcesAPI, RateCardStatus, RateCardsAPI, RatesAPI, types as SE, SalesOrderShipmentsAPI, SalesOrdersAPI, SellersAPI, ServicePointsAPI, ShipEngine, ShipEngineAPI, ShipEngineContext, ShipmentsAPI, ShippingRulesAPI, ThemesAPI, WarehousesAPI, WebhooksAPI, alchemy, camelizeKeys, decamelizeKeys, alchemy as default, delay, getEmotionCache, getEndUserIpAddress, isCodedError, isCodedErrors, isDataCodedErrors, isInvalidTokenError, logger, onError, parseError, retryUntil, useAddFunds, useAddInsuranceFunds, useAddSandboxCarriers, useAlchemy, useCalculateRates, useCancelShipment, useCarrierConnectionsServicesList, useConnectCarrier, useConnectCarrierAccount, useCreateAccountImage, useCreateFundingSource, useCreateInvoiceAddress, useCreateLabel, useCreateRateCard, useCreateSalesOrderShipment, useCreateSandboxSeller, useCreateSellerApiKey, useCreateShipment, useCreateShippingRule, useCreateWarehouse, useCreateWebhook, useDeactivateOrderSource, useDeleteAccountImage, useDeleteCarrier, useDeleteRateCard, useDeleteSellerApiKey, useDeleteShippingRule, useDeleteWarehouse, useDeleteWebhook, useDownloadRateCard, useEditShippingRule, useFundingSourcesAddFunds, useGetAccountBillingPlan, useGetAccountImages, useGetAccountSettings, useGetAutoFundingConfiguration, useGetCarrierById, useGetCarrierConnectionForm, useGetConnectionsCarrierSettings, useGetCountriesByCarrier, useGetCurrenciesByCarrier, useGetFundingSourceById, useGetFundingSourceMetadata, useGetFundingSourceTransactions, useGetHereToken, useGetInsuranceAccount, useGetInsuranceFundingSourceAcceptedTerms, useGetInvoiceAddress, useGetLabel, useGetPackageRatingGroupByCarrier, useGetRateCardById, useGetSalesOrder, useGetSalesOrderByExternalOrderId, useGetSalesOrderShipment, useGetServicePoint, useGetServicesByCarrier, useGetShipment, useGetShipmentByExternalId, useGetShipmentRates, useGetShippingRuleById, useGetShippingRuleConditionsOptions, useGetThemeById, useGetZonesByCarrier, useI18n, useListCarrierConnections, useListCarriers, useListCustomPackageTypes, useListFundingSources, useListLabels, useListOrderSources, useListOrderSourcesConnections, useListRateCards, useListSalesOrderShipments, useListSalesOrderShipmentsByExternalOrderId, useListSalesOrders, useListSandboxSellerIds, useListSellerApiKeys, useListServicePoints, useListShipments, useListShippingRules, useListWarehouses, useListWebhooks, useLoadIcons, useNotifySalesOrderShipped, useParseAddress, usePublishRateCard, useRatesEstimate, useRefreshOrderSource, useRefreshOrderSourceAsync, useRegisterCarrier, useShipEngine, useUpdateAccountBillingPlan, useUpdateAccountImage, useUpdateAccountSettings, useUpdateAutoFunding, useUpdateConnectionsCarrierSettings, useUpdateFundingSource, useUpdateInvoiceAddress, useUpdateOrderSource, useUpdateRateCard, useUpdateSalesOrderShipment, useUpdateWarehouse, useUpdateWebhook, useUploadRateCard, useValidateAddresses, useVoidLabel };
|
|
39030
|
+
export { AccountSettingsAPI, AddressesAPI, AlchemyContext, AlchemyProvider, AlchemyTestProvider, CarriersAPI, CodedError, ConfirmationType, ConnectionsAPI, CreditCardVendor, Currency, CustomPackagesAPI, CustomsContentsType, CustomsNonDeliveryType, Element, ErrorBoundary, FundingSourcesAPI, InsuranceAPI, InsuranceProviderType, InvoiceAddressAPI, LabelsAPI, MetadataCapability, MetadataRequirement, MetadataSatisfyingFormTypes, MovementIndicator, OrderSourcesAPI, RateCardStatus, RateCardsAPI, RatesAPI, types as SE, SalesOrderShipmentsAPI, SalesOrdersAPI, SellersAPI, ServicePointsAPI, ShipEngine, ShipEngineAPI, ShipEngineContext, ShipmentsAPI, ShippingRulesAPI, ThemesAPI, WarehousesAPI, WebhooksAPI, alchemy, camelizeKeys, decamelizeKeys, alchemy as default, delay, getEmotionCache, getEndUserIpAddress, isCodedError, isCodedErrors, isDataCodedErrors, isInvalidTokenError, logger, onError, parseError, retryUntil, useAddFunds, useAddInsuranceFunds, useAddSandboxCarriers, useAlchemy, useCalculateRates, useCancelShipment, useCarrierConnectionsServicesList, useConnectCarrier, useConnectCarrierAccount, useCreateAccountImage, useCreateFundingSource, useCreateInvoiceAddress, useCreateLabel, useCreateRateCard, useCreateSalesOrderShipment, useCreateSandboxSeller, useCreateSellerApiKey, useCreateShipment, useCreateShippingRule, useCreateWarehouse, useCreateWebhook, useDeactivateOrderSource, useDeleteAccountImage, useDeleteCarrier, useDeleteRateCard, useDeleteSellerApiKey, useDeleteShippingRule, useDeleteWarehouse, useDeleteWebhook, useDownloadRateCard, useEditShippingRule, useFundingSourcesAddFunds, useGetAccountBillingPlan, useGetAccountImages, useGetAccountSettings, useGetAutoFundingConfiguration, useGetCarrierById, useGetCarrierConnectionForm, useGetConnectionsCarrierSettings, useGetCountriesByCarrier, useGetCurrenciesByCarrier, useGetFundingSourceById, useGetFundingSourceMetadata, useGetFundingSourceTransactions, useGetHereToken, useGetInsuranceAccount, useGetInsuranceFundingSourceAcceptedTerms, useGetInvoiceAddress, useGetLabel, useGetPackageRatingGroupByCarrier, useGetRateCardById, useGetSalesOrder, useGetSalesOrderByExternalOrderId, useGetSalesOrderShipment, useGetServicePoint, useGetServicesByCarrier, useGetShipment, useGetShipmentByExternalId, useGetShipmentRates, useGetShippingRuleById, useGetShippingRuleConditionsOptions, useGetThemeById, useGetZonesByCarrier, useI18n, useListCarrierConnections, useListCarriers, useListCustomPackageTypes, useListFundingSources, useListLabels, useListLabelsInfinite, useListOrderSources, useListOrderSourcesConnections, useListRateCards, useListSalesOrderShipments, useListSalesOrderShipmentsByExternalOrderId, useListSalesOrders, useListSandboxSellerIds, useListSellerApiKeys, useListServicePoints, useListShipments, useListShippingRules, useListWarehouses, useListWebhooks, useLoadIcons, useNotifySalesOrderShipped, useParseAddress, usePublishRateCard, useRatesEstimate, useRefreshOrderSource, useRefreshOrderSourceAsync, useRegisterCarrier, useShipEngine, useUpdateAccountBillingPlan, useUpdateAccountImage, useUpdateAccountSettings, useUpdateAutoFunding, useUpdateConnectionsCarrierSettings, useUpdateFundingSource, useUpdateInvoiceAddress, useUpdateOrderSource, useUpdateRateCard, useUpdateSalesOrderShipment, useUpdateWarehouse, useUpdateWebhook, useUploadRateCard, useValidateAddresses, useVoidLabel };
|