@chrt-inc/typescript-sdk 1.944.0 → 1.953.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Client.js +2 -2
- package/dist/cjs/api/resources/shipping/resources/flights/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/shipping/resources/flights/client/Client.js +1 -1
- package/dist/cjs/api/resources/shipping/resources/orderTemplatesNew/client/Client.d.ts +1 -0
- package/dist/cjs/api/resources/shipping/resources/orderTemplatesNew/client/Client.js +5 -1
- package/dist/cjs/api/resources/shipping/resources/orderTemplatesNew/client/requests/OrderTemplatesNewListV1Request.d.ts +3 -0
- package/dist/cjs/api/resources/shippingIntegrations/client/Client.d.ts +3 -0
- package/dist/cjs/api/resources/shippingIntegrations/client/Client.js +19 -14
- package/dist/cjs/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/Client.d.ts +3 -19
- package/dist/cjs/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/Client.js +7 -78
- package/dist/cjs/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/shippingIntegrations/resources/cxt/resources/orders/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/shippingIntegrations/resources/cxt/resources/orders/client/Client.js +7 -7
- package/dist/cjs/api/resources/shippingIntegrations/resources/dispatchScience/resources/orders/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/shippingIntegrations/resources/dispatchScience/resources/orders/client/Client.js +7 -7
- package/dist/cjs/api/resources/shippingIntegrations/resources/ecourier/resources/orders/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/shippingIntegrations/resources/ecourier/resources/orders/client/Client.js +7 -7
- package/dist/cjs/api/resources/shippingIntegrations/resources/index.d.ts +1 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/index.js +2 -1
- package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/client/Client.d.ts +44 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/client/Client.js +121 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/client/index.js +2 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/index.d.ts +1 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/index.js +17 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/ontime360/resources/orders/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/shippingIntegrations/resources/ontime360/resources/orders/client/Client.js +7 -7
- package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/Client.d.ts +35 -2
- package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/Client.js +152 -4
- package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/requests/OrdersListForIntegrationExecutorOperatorsV1Request.d.ts +54 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/requests/OrdersListV1Request.d.ts +6 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/requests/OrdersStatusSummaryV1Request.d.ts +6 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/Client.d.ts +3 -19
- package/dist/cjs/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/Client.js +7 -78
- package/dist/cjs/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/tracking/resources/sessions/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/tracking/resources/sessions/client/Client.js +1 -1
- package/dist/cjs/api/types/ShippingIntegrationIntegrationExecutor.d.ts +17 -0
- package/dist/cjs/api/types/ShippingIntegrationIntegrationExecutorListRes.d.ts +8 -0
- package/dist/cjs/api/types/ShippingIntegrationIntegrationExecutorListRes.js +5 -0
- package/dist/cjs/api/types/ShippingIntegrationOrderCompletedAtProvenanceEnum1.d.ts +8 -0
- package/dist/cjs/api/types/ShippingIntegrationOrderCompletedAtProvenanceEnum1.js +10 -0
- package/dist/cjs/api/types/ShippingIntegrationOrderExpanded1.d.ts +3 -0
- package/dist/cjs/api/types/ShippingIntegrationOrderSortByEnum.d.ts +2 -1
- package/dist/cjs/api/types/ShippingIntegrationOrderSortByEnum.js +1 -0
- package/dist/cjs/api/types/ShippingIntegrationOrderTypeaheadFieldEnum.d.ts +5 -1
- package/dist/cjs/api/types/ShippingIntegrationOrderTypeaheadFieldEnum.js +5 -0
- package/dist/cjs/api/types/index.d.ts +3 -0
- package/dist/cjs/api/types/index.js +3 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/api/resources/shipping/resources/flights/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/shipping/resources/flights/client/Client.mjs +1 -1
- package/dist/esm/api/resources/shipping/resources/orderTemplatesNew/client/Client.d.mts +1 -0
- package/dist/esm/api/resources/shipping/resources/orderTemplatesNew/client/Client.mjs +5 -1
- package/dist/esm/api/resources/shipping/resources/orderTemplatesNew/client/requests/OrderTemplatesNewListV1Request.d.mts +3 -0
- package/dist/esm/api/resources/shippingIntegrations/client/Client.d.mts +3 -0
- package/dist/esm/api/resources/shippingIntegrations/client/Client.mjs +5 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/Client.d.mts +3 -19
- package/dist/esm/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/Client.mjs +7 -78
- package/dist/esm/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/shippingIntegrations/resources/cxt/resources/orders/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/shippingIntegrations/resources/cxt/resources/orders/client/Client.mjs +7 -7
- package/dist/esm/api/resources/shippingIntegrations/resources/dispatchScience/resources/orders/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/shippingIntegrations/resources/dispatchScience/resources/orders/client/Client.mjs +7 -7
- package/dist/esm/api/resources/shippingIntegrations/resources/ecourier/resources/orders/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/shippingIntegrations/resources/ecourier/resources/orders/client/Client.mjs +7 -7
- package/dist/esm/api/resources/shippingIntegrations/resources/index.d.mts +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/index.mjs +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/integrationExecutors/client/Client.d.mts +44 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/integrationExecutors/client/Client.mjs +84 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/integrationExecutors/client/index.d.mts +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/integrationExecutors/client/index.mjs +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/integrationExecutors/index.d.mts +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/integrationExecutors/index.mjs +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/ontime360/resources/orders/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/shippingIntegrations/resources/ontime360/resources/orders/client/Client.mjs +7 -7
- package/dist/esm/api/resources/shippingIntegrations/resources/orders/client/Client.d.mts +35 -2
- package/dist/esm/api/resources/shippingIntegrations/resources/orders/client/Client.mjs +152 -4
- package/dist/esm/api/resources/shippingIntegrations/resources/orders/client/requests/OrdersListForIntegrationExecutorOperatorsV1Request.d.mts +54 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/orders/client/requests/OrdersListV1Request.d.mts +6 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/orders/client/requests/OrdersStatusSummaryV1Request.d.mts +6 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/orders/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/Client.d.mts +3 -19
- package/dist/esm/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/Client.mjs +7 -78
- package/dist/esm/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/tracking/resources/sessions/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/tracking/resources/sessions/client/Client.mjs +1 -1
- package/dist/esm/api/types/ShippingIntegrationIntegrationExecutor.d.mts +17 -0
- package/dist/esm/api/types/ShippingIntegrationIntegrationExecutorListRes.d.mts +8 -0
- package/dist/esm/api/types/ShippingIntegrationIntegrationExecutorListRes.mjs +4 -0
- package/dist/esm/api/types/ShippingIntegrationOrderCompletedAtProvenanceEnum1.d.mts +8 -0
- package/dist/esm/api/types/ShippingIntegrationOrderCompletedAtProvenanceEnum1.mjs +7 -0
- package/dist/esm/api/types/ShippingIntegrationOrderExpanded1.d.mts +3 -0
- package/dist/esm/api/types/ShippingIntegrationOrderSortByEnum.d.mts +2 -1
- package/dist/esm/api/types/ShippingIntegrationOrderSortByEnum.mjs +1 -0
- package/dist/esm/api/types/ShippingIntegrationOrderTypeaheadFieldEnum.d.mts +5 -1
- package/dist/esm/api/types/ShippingIntegrationOrderTypeaheadFieldEnum.mjs +4 -1
- package/dist/esm/api/types/index.d.mts +3 -0
- package/dist/esm/api/types/index.mjs +3 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +163 -166
- package/dist/cjs/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/requests/OrdersTypeaheadV1Request.d.ts +0 -16
- package/dist/cjs/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/requests/OrdersTypeaheadV1Request.d.ts +0 -16
- package/dist/esm/api/resources/shippingIntegrations/resources/atlas/resources/orders/client/requests/OrdersTypeaheadV1Request.d.mts +0 -16
- package/dist/esm/api/resources/shippingIntegrations/resources/xcelerator/resources/orders/client/requests/OrdersTypeaheadV1Request.d.mts +0 -16
- /package/dist/cjs/api/resources/shippingIntegrations/resources/{atlas/resources/orders/client/requests/OrdersTypeaheadV1Request.js → orders/client/requests/OrdersListForIntegrationExecutorOperatorsV1Request.js} +0 -0
- /package/dist/cjs/api/{resources/shippingIntegrations/resources/xcelerator/resources/orders/client/requests/OrdersTypeaheadV1Request.js → types/ShippingIntegrationIntegrationExecutor.js} +0 -0
- /package/dist/esm/api/resources/shippingIntegrations/resources/{atlas/resources/orders/client/requests/OrdersTypeaheadV1Request.mjs → orders/client/requests/OrdersListForIntegrationExecutorOperatorsV1Request.mjs} +0 -0
- /package/dist/esm/api/{resources/shippingIntegrations/resources/xcelerator/resources/orders/client/requests/OrdersTypeaheadV1Request.mjs → types/ShippingIntegrationIntegrationExecutor.mjs} +0 -0
package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/client/Client.js
ADDED
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
+
var ownKeys = function(o) {
|
|
23
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
+
var ar = [];
|
|
25
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
return ownKeys(o);
|
|
29
|
+
};
|
|
30
|
+
return function (mod) {
|
|
31
|
+
if (mod && mod.__esModule) return mod;
|
|
32
|
+
var result = {};
|
|
33
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
+
__setModuleDefault(result, mod);
|
|
35
|
+
return result;
|
|
36
|
+
};
|
|
37
|
+
})();
|
|
38
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
39
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
40
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
41
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
42
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
43
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
44
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
45
|
+
});
|
|
46
|
+
};
|
|
47
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
|
+
exports.IntegrationExecutors = void 0;
|
|
49
|
+
const environments = __importStar(require("../../../../../../environments.js"));
|
|
50
|
+
const core = __importStar(require("../../../../../../core/index.js"));
|
|
51
|
+
const headers_js_1 = require("../../../../../../core/headers.js");
|
|
52
|
+
const errors = __importStar(require("../../../../../../errors/index.js"));
|
|
53
|
+
class IntegrationExecutors {
|
|
54
|
+
constructor(_options = {}) {
|
|
55
|
+
this._options = _options;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Lists all distinct integration executor organizations that have credentials configured across any shipping integration, with public organization data expanded. | authz: min_org_role=operator | () -> (ShippingIntegrationIntegrationExecutorListRes)
|
|
59
|
+
*
|
|
60
|
+
* @param {IntegrationExecutors.RequestOptions} requestOptions - Request-specific configuration.
|
|
61
|
+
*
|
|
62
|
+
* @example
|
|
63
|
+
* await client.shippingIntegrations.integrationExecutors.listV1()
|
|
64
|
+
*/
|
|
65
|
+
listV1(requestOptions) {
|
|
66
|
+
return core.HttpResponsePromise.fromPromise(this.__listV1(requestOptions));
|
|
67
|
+
}
|
|
68
|
+
__listV1(requestOptions) {
|
|
69
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
70
|
+
var _a, _b, _c, _d;
|
|
71
|
+
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
72
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
73
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "shipping_integrations/integration_executors/list/v1"),
|
|
74
|
+
method: "GET",
|
|
75
|
+
headers: _headers,
|
|
76
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
77
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
78
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
79
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
80
|
+
});
|
|
81
|
+
if (_response.ok) {
|
|
82
|
+
return {
|
|
83
|
+
data: _response.body,
|
|
84
|
+
rawResponse: _response.rawResponse,
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
if (_response.error.reason === "status-code") {
|
|
88
|
+
throw new errors.ChrtError({
|
|
89
|
+
statusCode: _response.error.statusCode,
|
|
90
|
+
body: _response.error.body,
|
|
91
|
+
rawResponse: _response.rawResponse,
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
switch (_response.error.reason) {
|
|
95
|
+
case "non-json":
|
|
96
|
+
throw new errors.ChrtError({
|
|
97
|
+
statusCode: _response.error.statusCode,
|
|
98
|
+
body: _response.error.rawBody,
|
|
99
|
+
rawResponse: _response.rawResponse,
|
|
100
|
+
});
|
|
101
|
+
case "timeout":
|
|
102
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /shipping_integrations/integration_executors/list/v1.");
|
|
103
|
+
case "unknown":
|
|
104
|
+
throw new errors.ChrtError({
|
|
105
|
+
message: _response.error.errorMessage,
|
|
106
|
+
rawResponse: _response.rawResponse,
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
_getAuthorizationHeader() {
|
|
112
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
113
|
+
const bearer = yield core.Supplier.get(this._options.token);
|
|
114
|
+
if (bearer != null) {
|
|
115
|
+
return `Bearer ${bearer}`;
|
|
116
|
+
}
|
|
117
|
+
return undefined;
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
exports.IntegrationExecutors = IntegrationExecutors;
|
package/dist/cjs/api/resources/shippingIntegrations/resources/integrationExecutors/client/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./client/index.js";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./client/index.js"), exports);
|
|
@@ -33,16 +33,16 @@ export declare class Orders {
|
|
|
33
33
|
/**
|
|
34
34
|
* Returns one mirrored OnTime360 order by the provider's own order GUID. | () -> (OnTime360Order1)
|
|
35
35
|
*
|
|
36
|
-
* @param {string}
|
|
36
|
+
* @param {string} orgId - CHRT org ID of the other party (executor if caller is coordinator, coordinator if caller is executor)
|
|
37
37
|
* @param {string} integrationOrderId - OnTime360's own GUID for the order (its ID), as carried on a unified order row
|
|
38
38
|
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
39
39
|
*
|
|
40
40
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
41
41
|
*
|
|
42
42
|
* @example
|
|
43
|
-
* await client.shippingIntegrations.ontime360.orders.detailByIntegrationOrderIdV1("
|
|
43
|
+
* await client.shippingIntegrations.ontime360.orders.detailByIntegrationOrderIdV1("org_id", "integration_order_id")
|
|
44
44
|
*/
|
|
45
|
-
detailByIntegrationOrderIdV1(
|
|
45
|
+
detailByIntegrationOrderIdV1(orgId: string, integrationOrderId: string, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.OnTime360Order1>;
|
|
46
46
|
private __detailByIntegrationOrderIdV1;
|
|
47
47
|
/**
|
|
48
48
|
* Returns one mirrored OnTime360 order by its Mongo ObjectId. | () -> (OnTime360Order1)
|
|
@@ -58,24 +58,24 @@ class Orders {
|
|
|
58
58
|
/**
|
|
59
59
|
* Returns one mirrored OnTime360 order by the provider's own order GUID. | () -> (OnTime360Order1)
|
|
60
60
|
*
|
|
61
|
-
* @param {string}
|
|
61
|
+
* @param {string} orgId - CHRT org ID of the other party (executor if caller is coordinator, coordinator if caller is executor)
|
|
62
62
|
* @param {string} integrationOrderId - OnTime360's own GUID for the order (its ID), as carried on a unified order row
|
|
63
63
|
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
64
64
|
*
|
|
65
65
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
66
66
|
*
|
|
67
67
|
* @example
|
|
68
|
-
* await client.shippingIntegrations.ontime360.orders.detailByIntegrationOrderIdV1("
|
|
68
|
+
* await client.shippingIntegrations.ontime360.orders.detailByIntegrationOrderIdV1("org_id", "integration_order_id")
|
|
69
69
|
*/
|
|
70
|
-
detailByIntegrationOrderIdV1(
|
|
71
|
-
return core.HttpResponsePromise.fromPromise(this.__detailByIntegrationOrderIdV1(
|
|
70
|
+
detailByIntegrationOrderIdV1(orgId, integrationOrderId, requestOptions) {
|
|
71
|
+
return core.HttpResponsePromise.fromPromise(this.__detailByIntegrationOrderIdV1(orgId, integrationOrderId, requestOptions));
|
|
72
72
|
}
|
|
73
|
-
__detailByIntegrationOrderIdV1(
|
|
73
|
+
__detailByIntegrationOrderIdV1(orgId, integrationOrderId, requestOptions) {
|
|
74
74
|
return __awaiter(this, void 0, void 0, function* () {
|
|
75
75
|
var _a, _b, _c, _d;
|
|
76
76
|
let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
77
77
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
78
|
-
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `shipping_integrations/ontime360/orders/by_integration_order_id/detail/v1/${encodeURIComponent(
|
|
78
|
+
url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `shipping_integrations/ontime360/orders/by_integration_order_id/detail/v1/${encodeURIComponent(orgId)}/${encodeURIComponent(integrationOrderId)}`),
|
|
79
79
|
method: "GET",
|
|
80
80
|
headers: _headers,
|
|
81
81
|
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
@@ -106,7 +106,7 @@ class Orders {
|
|
|
106
106
|
rawResponse: _response.rawResponse,
|
|
107
107
|
});
|
|
108
108
|
case "timeout":
|
|
109
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /shipping_integrations/ontime360/orders/by_integration_order_id/detail/v1/{
|
|
109
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /shipping_integrations/ontime360/orders/by_integration_order_id/detail/v1/{org_id}/{integration_order_id}.");
|
|
110
110
|
case "unknown":
|
|
111
111
|
throw new errors.ChrtError({
|
|
112
112
|
message: _response.error.errorMessage,
|
|
@@ -31,7 +31,7 @@ export declare class Orders {
|
|
|
31
31
|
protected readonly _options: Orders.Options;
|
|
32
32
|
constructor(_options?: Orders.Options);
|
|
33
33
|
/**
|
|
34
|
-
* Returns one unified shipping integration order by its Mongo ObjectId with
|
|
34
|
+
* Returns one unified shipping integration order by its Mongo ObjectId with related organizations expanded. | () -> (ShippingIntegrationOrderExpanded1)
|
|
35
35
|
*
|
|
36
36
|
* @param {string} id - Mongo ObjectId of the unified order document. The provider's own order ID is the integration_order_id field on the returned order.
|
|
37
37
|
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -43,6 +43,35 @@ export declare class Orders {
|
|
|
43
43
|
*/
|
|
44
44
|
detailV1(id: string, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.ShippingIntegrationOrderExpanded1>;
|
|
45
45
|
private __detailV1;
|
|
46
|
+
/**
|
|
47
|
+
* Lists orders assigned to the caller's integration executor organization across all shipping integrations with integration coordinator organizations expanded, filtering, sorting, pagination, and optional search. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (ShippingIntegrationOrderListRes)
|
|
48
|
+
*
|
|
49
|
+
* @param {Chrt.shippingIntegrations.OrdersListForIntegrationExecutorOperatorsV1Request} request
|
|
50
|
+
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
51
|
+
*
|
|
52
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* await client.shippingIntegrations.orders.listForIntegrationExecutorOperatorsV1({
|
|
56
|
+
* sort_by: "ordered_at_timestamp",
|
|
57
|
+
* sort_order: "asc",
|
|
58
|
+
* page: 1,
|
|
59
|
+
* page_size: 1,
|
|
60
|
+
* search: "search",
|
|
61
|
+
* filter_shipping_integration: ["xcelerator"],
|
|
62
|
+
* filter_status: ["staged"],
|
|
63
|
+
* filter_integration_order_id: "filter_integration_order_id",
|
|
64
|
+
* filter_reference_number: "filter_reference_number",
|
|
65
|
+
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
66
|
+
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
67
|
+
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
68
|
+
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
69
|
+
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
70
|
+
* filter_first_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z"
|
|
71
|
+
* })
|
|
72
|
+
*/
|
|
73
|
+
listForIntegrationExecutorOperatorsV1(request?: Chrt.shippingIntegrations.OrdersListForIntegrationExecutorOperatorsV1Request, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.ShippingIntegrationOrderListRes>;
|
|
74
|
+
private __listForIntegrationExecutorOperatorsV1;
|
|
46
75
|
/**
|
|
47
76
|
* Lists the caller's orders from every shipping integration with provider organizations expanded, filtering, sorting, pagination, and optional search. | () -> (ShippingIntegrationOrderListRes)
|
|
48
77
|
*
|
|
@@ -65,6 +94,8 @@ export declare class Orders {
|
|
|
65
94
|
* filter_reference_number: "filter_reference_number",
|
|
66
95
|
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
67
96
|
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
97
|
+
* filter_completed_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
98
|
+
* filter_completed_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
68
99
|
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
69
100
|
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
70
101
|
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
@@ -90,6 +121,8 @@ export declare class Orders {
|
|
|
90
121
|
* filter_reference_number: "filter_reference_number",
|
|
91
122
|
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
92
123
|
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
124
|
+
* filter_completed_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
125
|
+
* filter_completed_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
93
126
|
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
94
127
|
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
95
128
|
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
@@ -99,7 +132,7 @@ export declare class Orders {
|
|
|
99
132
|
statusSummaryV1(request?: Chrt.shippingIntegrations.OrdersStatusSummaryV1Request, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<Chrt.ShippingIntegrationOrderStatusSummaryRes>;
|
|
100
133
|
private __statusSummaryV1;
|
|
101
134
|
/**
|
|
102
|
-
* Returns distinct integration order IDs matching the query via case-insensitive regex within the caller's organization. |
|
|
135
|
+
* Returns distinct integration order IDs and reference numbers matching the query via case-insensitive regex within the caller's organization. | () -> (list[ShippingIntegrationOrderTypeaheadResult])
|
|
103
136
|
*
|
|
104
137
|
* @param {Chrt.shippingIntegrations.OrdersTypeaheadV1Request} request
|
|
105
138
|
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -56,7 +56,7 @@ class Orders {
|
|
|
56
56
|
this._options = _options;
|
|
57
57
|
}
|
|
58
58
|
/**
|
|
59
|
-
* Returns one unified shipping integration order by its Mongo ObjectId with
|
|
59
|
+
* Returns one unified shipping integration order by its Mongo ObjectId with related organizations expanded. | () -> (ShippingIntegrationOrderExpanded1)
|
|
60
60
|
*
|
|
61
61
|
* @param {string} id - Mongo ObjectId of the unified order document. The provider's own order ID is the integration_order_id field on the returned order.
|
|
62
62
|
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -117,6 +117,138 @@ class Orders {
|
|
|
117
117
|
}
|
|
118
118
|
});
|
|
119
119
|
}
|
|
120
|
+
/**
|
|
121
|
+
* Lists orders assigned to the caller's integration executor organization across all shipping integrations with integration coordinator organizations expanded, filtering, sorting, pagination, and optional search. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (ShippingIntegrationOrderListRes)
|
|
122
|
+
*
|
|
123
|
+
* @param {Chrt.shippingIntegrations.OrdersListForIntegrationExecutorOperatorsV1Request} request
|
|
124
|
+
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
125
|
+
*
|
|
126
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
127
|
+
*
|
|
128
|
+
* @example
|
|
129
|
+
* await client.shippingIntegrations.orders.listForIntegrationExecutorOperatorsV1({
|
|
130
|
+
* sort_by: "ordered_at_timestamp",
|
|
131
|
+
* sort_order: "asc",
|
|
132
|
+
* page: 1,
|
|
133
|
+
* page_size: 1,
|
|
134
|
+
* search: "search",
|
|
135
|
+
* filter_shipping_integration: ["xcelerator"],
|
|
136
|
+
* filter_status: ["staged"],
|
|
137
|
+
* filter_integration_order_id: "filter_integration_order_id",
|
|
138
|
+
* filter_reference_number: "filter_reference_number",
|
|
139
|
+
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
140
|
+
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
141
|
+
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
142
|
+
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
143
|
+
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
144
|
+
* filter_first_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z"
|
|
145
|
+
* })
|
|
146
|
+
*/
|
|
147
|
+
listForIntegrationExecutorOperatorsV1(request = {}, requestOptions) {
|
|
148
|
+
return core.HttpResponsePromise.fromPromise(this.__listForIntegrationExecutorOperatorsV1(request, requestOptions));
|
|
149
|
+
}
|
|
150
|
+
__listForIntegrationExecutorOperatorsV1() {
|
|
151
|
+
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
152
|
+
var _a, _b, _c, _d, _e, _f;
|
|
153
|
+
const { sort_by: sortBy, sort_order: sortOrder, page, page_size: pageSize, search, filter_shipping_integration: filterShippingIntegration, filter_status: filterStatus, filter_integration_order_id: filterIntegrationOrderId, filter_reference_number: filterReferenceNumber, filter_ordered_at_timestamp_gte: filterOrderedAtTimestampGte, filter_ordered_at_timestamp_lte: filterOrderedAtTimestampLte, filter_last_mirrored_at_timestamp_gte: filterLastMirroredAtTimestampGte, filter_last_mirrored_at_timestamp_lte: filterLastMirroredAtTimestampLte, filter_first_mirrored_at_timestamp_gte: filterFirstMirroredAtTimestampGte, filter_first_mirrored_at_timestamp_lte: filterFirstMirroredAtTimestampLte, } = request;
|
|
154
|
+
const _queryParams = {};
|
|
155
|
+
if (sortBy !== undefined) {
|
|
156
|
+
_queryParams["sort_by"] = sortBy;
|
|
157
|
+
}
|
|
158
|
+
if (sortOrder !== undefined) {
|
|
159
|
+
_queryParams["sort_order"] = sortOrder;
|
|
160
|
+
}
|
|
161
|
+
if (page !== undefined) {
|
|
162
|
+
_queryParams["page"] = (_a = page === null || page === void 0 ? void 0 : page.toString()) !== null && _a !== void 0 ? _a : null;
|
|
163
|
+
}
|
|
164
|
+
if (pageSize !== undefined) {
|
|
165
|
+
_queryParams["page_size"] = (_b = pageSize === null || pageSize === void 0 ? void 0 : pageSize.toString()) !== null && _b !== void 0 ? _b : null;
|
|
166
|
+
}
|
|
167
|
+
if (search !== undefined) {
|
|
168
|
+
_queryParams["search"] = search;
|
|
169
|
+
}
|
|
170
|
+
if (filterShippingIntegration !== undefined) {
|
|
171
|
+
if (Array.isArray(filterShippingIntegration)) {
|
|
172
|
+
_queryParams["filter_shipping_integration"] = filterShippingIntegration.map((item) => item);
|
|
173
|
+
}
|
|
174
|
+
else {
|
|
175
|
+
_queryParams["filter_shipping_integration"] = filterShippingIntegration;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
if (filterStatus !== undefined) {
|
|
179
|
+
if (Array.isArray(filterStatus)) {
|
|
180
|
+
_queryParams["filter_status"] = filterStatus.map((item) => item);
|
|
181
|
+
}
|
|
182
|
+
else {
|
|
183
|
+
_queryParams["filter_status"] = filterStatus;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
if (filterIntegrationOrderId !== undefined) {
|
|
187
|
+
_queryParams["filter_integration_order_id"] = filterIntegrationOrderId;
|
|
188
|
+
}
|
|
189
|
+
if (filterReferenceNumber !== undefined) {
|
|
190
|
+
_queryParams["filter_reference_number"] = filterReferenceNumber;
|
|
191
|
+
}
|
|
192
|
+
if (filterOrderedAtTimestampGte !== undefined) {
|
|
193
|
+
_queryParams["filter_ordered_at_timestamp_gte"] = filterOrderedAtTimestampGte;
|
|
194
|
+
}
|
|
195
|
+
if (filterOrderedAtTimestampLte !== undefined) {
|
|
196
|
+
_queryParams["filter_ordered_at_timestamp_lte"] = filterOrderedAtTimestampLte;
|
|
197
|
+
}
|
|
198
|
+
if (filterLastMirroredAtTimestampGte !== undefined) {
|
|
199
|
+
_queryParams["filter_last_mirrored_at_timestamp_gte"] = filterLastMirroredAtTimestampGte;
|
|
200
|
+
}
|
|
201
|
+
if (filterLastMirroredAtTimestampLte !== undefined) {
|
|
202
|
+
_queryParams["filter_last_mirrored_at_timestamp_lte"] = filterLastMirroredAtTimestampLte;
|
|
203
|
+
}
|
|
204
|
+
if (filterFirstMirroredAtTimestampGte !== undefined) {
|
|
205
|
+
_queryParams["filter_first_mirrored_at_timestamp_gte"] = filterFirstMirroredAtTimestampGte;
|
|
206
|
+
}
|
|
207
|
+
if (filterFirstMirroredAtTimestampLte !== undefined) {
|
|
208
|
+
_queryParams["filter_first_mirrored_at_timestamp_lte"] = filterFirstMirroredAtTimestampLte;
|
|
209
|
+
}
|
|
210
|
+
let _headers = (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
211
|
+
const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
|
|
212
|
+
url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ChrtEnvironment.Local, "shipping_integrations/orders/list/for_integration_executor_operators/v1"),
|
|
213
|
+
method: "GET",
|
|
214
|
+
headers: _headers,
|
|
215
|
+
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
216
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
217
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
218
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
219
|
+
});
|
|
220
|
+
if (_response.ok) {
|
|
221
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
222
|
+
}
|
|
223
|
+
if (_response.error.reason === "status-code") {
|
|
224
|
+
switch (_response.error.statusCode) {
|
|
225
|
+
case 422:
|
|
226
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
227
|
+
default:
|
|
228
|
+
throw new errors.ChrtError({
|
|
229
|
+
statusCode: _response.error.statusCode,
|
|
230
|
+
body: _response.error.body,
|
|
231
|
+
rawResponse: _response.rawResponse,
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
switch (_response.error.reason) {
|
|
236
|
+
case "non-json":
|
|
237
|
+
throw new errors.ChrtError({
|
|
238
|
+
statusCode: _response.error.statusCode,
|
|
239
|
+
body: _response.error.rawBody,
|
|
240
|
+
rawResponse: _response.rawResponse,
|
|
241
|
+
});
|
|
242
|
+
case "timeout":
|
|
243
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /shipping_integrations/orders/list/for_integration_executor_operators/v1.");
|
|
244
|
+
case "unknown":
|
|
245
|
+
throw new errors.ChrtError({
|
|
246
|
+
message: _response.error.errorMessage,
|
|
247
|
+
rawResponse: _response.rawResponse,
|
|
248
|
+
});
|
|
249
|
+
}
|
|
250
|
+
});
|
|
251
|
+
}
|
|
120
252
|
/**
|
|
121
253
|
* Lists the caller's orders from every shipping integration with provider organizations expanded, filtering, sorting, pagination, and optional search. | () -> (ShippingIntegrationOrderListRes)
|
|
122
254
|
*
|
|
@@ -139,6 +271,8 @@ class Orders {
|
|
|
139
271
|
* filter_reference_number: "filter_reference_number",
|
|
140
272
|
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
141
273
|
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
274
|
+
* filter_completed_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
275
|
+
* filter_completed_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
142
276
|
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
143
277
|
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
144
278
|
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
@@ -151,7 +285,7 @@ class Orders {
|
|
|
151
285
|
__listV1() {
|
|
152
286
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
153
287
|
var _a, _b, _c, _d, _e, _f;
|
|
154
|
-
const { sort_by: sortBy, sort_order: sortOrder, page, page_size: pageSize, search, filter_shipping_integration: filterShippingIntegration, filter_provider_org_id: filterProviderOrgId, filter_status: filterStatus, filter_integration_order_id: filterIntegrationOrderId, filter_reference_number: filterReferenceNumber, filter_ordered_at_timestamp_gte: filterOrderedAtTimestampGte, filter_ordered_at_timestamp_lte: filterOrderedAtTimestampLte, filter_last_mirrored_at_timestamp_gte: filterLastMirroredAtTimestampGte, filter_last_mirrored_at_timestamp_lte: filterLastMirroredAtTimestampLte, filter_first_mirrored_at_timestamp_gte: filterFirstMirroredAtTimestampGte, filter_first_mirrored_at_timestamp_lte: filterFirstMirroredAtTimestampLte, } = request;
|
|
288
|
+
const { sort_by: sortBy, sort_order: sortOrder, page, page_size: pageSize, search, filter_shipping_integration: filterShippingIntegration, filter_provider_org_id: filterProviderOrgId, filter_status: filterStatus, filter_integration_order_id: filterIntegrationOrderId, filter_reference_number: filterReferenceNumber, filter_ordered_at_timestamp_gte: filterOrderedAtTimestampGte, filter_ordered_at_timestamp_lte: filterOrderedAtTimestampLte, filter_completed_at_timestamp_gte: filterCompletedAtTimestampGte, filter_completed_at_timestamp_lte: filterCompletedAtTimestampLte, filter_last_mirrored_at_timestamp_gte: filterLastMirroredAtTimestampGte, filter_last_mirrored_at_timestamp_lte: filterLastMirroredAtTimestampLte, filter_first_mirrored_at_timestamp_gte: filterFirstMirroredAtTimestampGte, filter_first_mirrored_at_timestamp_lte: filterFirstMirroredAtTimestampLte, } = request;
|
|
155
289
|
const _queryParams = {};
|
|
156
290
|
if (sortBy !== undefined) {
|
|
157
291
|
_queryParams["sort_by"] = sortBy;
|
|
@@ -204,6 +338,12 @@ class Orders {
|
|
|
204
338
|
if (filterOrderedAtTimestampLte !== undefined) {
|
|
205
339
|
_queryParams["filter_ordered_at_timestamp_lte"] = filterOrderedAtTimestampLte;
|
|
206
340
|
}
|
|
341
|
+
if (filterCompletedAtTimestampGte !== undefined) {
|
|
342
|
+
_queryParams["filter_completed_at_timestamp_gte"] = filterCompletedAtTimestampGte;
|
|
343
|
+
}
|
|
344
|
+
if (filterCompletedAtTimestampLte !== undefined) {
|
|
345
|
+
_queryParams["filter_completed_at_timestamp_lte"] = filterCompletedAtTimestampLte;
|
|
346
|
+
}
|
|
207
347
|
if (filterLastMirroredAtTimestampGte !== undefined) {
|
|
208
348
|
_queryParams["filter_last_mirrored_at_timestamp_gte"] = filterLastMirroredAtTimestampGte;
|
|
209
349
|
}
|
|
@@ -275,6 +415,8 @@ class Orders {
|
|
|
275
415
|
* filter_reference_number: "filter_reference_number",
|
|
276
416
|
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
277
417
|
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
418
|
+
* filter_completed_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
419
|
+
* filter_completed_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
278
420
|
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
279
421
|
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
280
422
|
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
@@ -287,7 +429,7 @@ class Orders {
|
|
|
287
429
|
__statusSummaryV1() {
|
|
288
430
|
return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
|
|
289
431
|
var _a, _b, _c, _d;
|
|
290
|
-
const { filter_shipping_integration: filterShippingIntegration, filter_provider_org_id: filterProviderOrgId, filter_status: filterStatus, filter_integration_order_id: filterIntegrationOrderId, filter_reference_number: filterReferenceNumber, filter_ordered_at_timestamp_gte: filterOrderedAtTimestampGte, filter_ordered_at_timestamp_lte: filterOrderedAtTimestampLte, filter_last_mirrored_at_timestamp_gte: filterLastMirroredAtTimestampGte, filter_last_mirrored_at_timestamp_lte: filterLastMirroredAtTimestampLte, filter_first_mirrored_at_timestamp_gte: filterFirstMirroredAtTimestampGte, filter_first_mirrored_at_timestamp_lte: filterFirstMirroredAtTimestampLte, } = request;
|
|
432
|
+
const { filter_shipping_integration: filterShippingIntegration, filter_provider_org_id: filterProviderOrgId, filter_status: filterStatus, filter_integration_order_id: filterIntegrationOrderId, filter_reference_number: filterReferenceNumber, filter_ordered_at_timestamp_gte: filterOrderedAtTimestampGte, filter_ordered_at_timestamp_lte: filterOrderedAtTimestampLte, filter_completed_at_timestamp_gte: filterCompletedAtTimestampGte, filter_completed_at_timestamp_lte: filterCompletedAtTimestampLte, filter_last_mirrored_at_timestamp_gte: filterLastMirroredAtTimestampGte, filter_last_mirrored_at_timestamp_lte: filterLastMirroredAtTimestampLte, filter_first_mirrored_at_timestamp_gte: filterFirstMirroredAtTimestampGte, filter_first_mirrored_at_timestamp_lte: filterFirstMirroredAtTimestampLte, } = request;
|
|
291
433
|
const _queryParams = {};
|
|
292
434
|
if (filterShippingIntegration !== undefined) {
|
|
293
435
|
if (Array.isArray(filterShippingIntegration)) {
|
|
@@ -325,6 +467,12 @@ class Orders {
|
|
|
325
467
|
if (filterOrderedAtTimestampLte !== undefined) {
|
|
326
468
|
_queryParams["filter_ordered_at_timestamp_lte"] = filterOrderedAtTimestampLte;
|
|
327
469
|
}
|
|
470
|
+
if (filterCompletedAtTimestampGte !== undefined) {
|
|
471
|
+
_queryParams["filter_completed_at_timestamp_gte"] = filterCompletedAtTimestampGte;
|
|
472
|
+
}
|
|
473
|
+
if (filterCompletedAtTimestampLte !== undefined) {
|
|
474
|
+
_queryParams["filter_completed_at_timestamp_lte"] = filterCompletedAtTimestampLte;
|
|
475
|
+
}
|
|
328
476
|
if (filterLastMirroredAtTimestampGte !== undefined) {
|
|
329
477
|
_queryParams["filter_last_mirrored_at_timestamp_gte"] = filterLastMirroredAtTimestampGte;
|
|
330
478
|
}
|
|
@@ -383,7 +531,7 @@ class Orders {
|
|
|
383
531
|
});
|
|
384
532
|
}
|
|
385
533
|
/**
|
|
386
|
-
* Returns distinct integration order IDs matching the query via case-insensitive regex within the caller's organization. |
|
|
534
|
+
* Returns distinct integration order IDs and reference numbers matching the query via case-insensitive regex within the caller's organization. | () -> (list[ShippingIntegrationOrderTypeaheadResult])
|
|
387
535
|
*
|
|
388
536
|
* @param {Chrt.shippingIntegrations.OrdersTypeaheadV1Request} request
|
|
389
537
|
* @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by Fern from our API Definition.
|
|
3
|
+
*/
|
|
4
|
+
import * as Chrt from "../../../../../../index.js";
|
|
5
|
+
/**
|
|
6
|
+
* @example
|
|
7
|
+
* {
|
|
8
|
+
* sort_by: "ordered_at_timestamp",
|
|
9
|
+
* sort_order: "asc",
|
|
10
|
+
* page: 1,
|
|
11
|
+
* page_size: 1,
|
|
12
|
+
* search: "search",
|
|
13
|
+
* filter_shipping_integration: ["xcelerator"],
|
|
14
|
+
* filter_status: ["staged"],
|
|
15
|
+
* filter_integration_order_id: "filter_integration_order_id",
|
|
16
|
+
* filter_reference_number: "filter_reference_number",
|
|
17
|
+
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
18
|
+
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
19
|
+
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
20
|
+
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
21
|
+
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
22
|
+
* filter_first_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z"
|
|
23
|
+
* }
|
|
24
|
+
*/
|
|
25
|
+
export interface OrdersListForIntegrationExecutorOperatorsV1Request {
|
|
26
|
+
/** Field to sort by. */
|
|
27
|
+
sort_by?: Chrt.ShippingIntegrationOrderSortByEnum | null;
|
|
28
|
+
/** Sort order (asc or desc). */
|
|
29
|
+
sort_order?: Chrt.SortOrderEnum | null;
|
|
30
|
+
page?: number | null;
|
|
31
|
+
page_size?: number | null;
|
|
32
|
+
/** Search provider order IDs and reference numbers. */
|
|
33
|
+
search?: string | null;
|
|
34
|
+
/** Filter by shipping integration(s) */
|
|
35
|
+
filter_shipping_integration?: (Chrt.OrgShippingIntegrationEnum1 | null) | (Chrt.OrgShippingIntegrationEnum1 | null)[];
|
|
36
|
+
/** Filter by unified status(es) */
|
|
37
|
+
filter_status?: (Chrt.ShippingIntegrationOrderStatusEnum1 | null) | (Chrt.ShippingIntegrationOrderStatusEnum1 | null)[];
|
|
38
|
+
/** Filter by the provider's exact order ID */
|
|
39
|
+
filter_integration_order_id?: string | null;
|
|
40
|
+
/** Filter by an exact reference number carried on the order */
|
|
41
|
+
filter_reference_number?: string | null;
|
|
42
|
+
/** Filter ordered_at_timestamp >= value */
|
|
43
|
+
filter_ordered_at_timestamp_gte?: string | null;
|
|
44
|
+
/** Filter ordered_at_timestamp <= value */
|
|
45
|
+
filter_ordered_at_timestamp_lte?: string | null;
|
|
46
|
+
/** Filter last_mirrored_at_timestamp >= value */
|
|
47
|
+
filter_last_mirrored_at_timestamp_gte?: string | null;
|
|
48
|
+
/** Filter last_mirrored_at_timestamp <= value */
|
|
49
|
+
filter_last_mirrored_at_timestamp_lte?: string | null;
|
|
50
|
+
/** Filter first_mirrored_at_timestamp >= value */
|
|
51
|
+
filter_first_mirrored_at_timestamp_gte?: string | null;
|
|
52
|
+
/** Filter first_mirrored_at_timestamp <= value */
|
|
53
|
+
filter_first_mirrored_at_timestamp_lte?: string | null;
|
|
54
|
+
}
|
|
@@ -17,6 +17,8 @@ import * as Chrt from "../../../../../../index.js";
|
|
|
17
17
|
* filter_reference_number: "filter_reference_number",
|
|
18
18
|
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
19
19
|
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
20
|
+
* filter_completed_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
21
|
+
* filter_completed_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
20
22
|
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
21
23
|
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
22
24
|
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
@@ -46,6 +48,10 @@ export interface OrdersListV1Request {
|
|
|
46
48
|
filter_ordered_at_timestamp_gte?: string | null;
|
|
47
49
|
/** Filter ordered_at_timestamp <= value */
|
|
48
50
|
filter_ordered_at_timestamp_lte?: string | null;
|
|
51
|
+
/** Filter completed_at_timestamp >= value */
|
|
52
|
+
filter_completed_at_timestamp_gte?: string | null;
|
|
53
|
+
/** Filter completed_at_timestamp <= value */
|
|
54
|
+
filter_completed_at_timestamp_lte?: string | null;
|
|
49
55
|
/** Filter last_mirrored_at_timestamp >= value */
|
|
50
56
|
filter_last_mirrored_at_timestamp_gte?: string | null;
|
|
51
57
|
/** Filter last_mirrored_at_timestamp <= value */
|
|
@@ -12,6 +12,8 @@ import * as Chrt from "../../../../../../index.js";
|
|
|
12
12
|
* filter_reference_number: "filter_reference_number",
|
|
13
13
|
* filter_ordered_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
14
14
|
* filter_ordered_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
15
|
+
* filter_completed_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
16
|
+
* filter_completed_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
15
17
|
* filter_last_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
16
18
|
* filter_last_mirrored_at_timestamp_lte: "2024-01-15T09:30:00Z",
|
|
17
19
|
* filter_first_mirrored_at_timestamp_gte: "2024-01-15T09:30:00Z",
|
|
@@ -33,6 +35,10 @@ export interface OrdersStatusSummaryV1Request {
|
|
|
33
35
|
filter_ordered_at_timestamp_gte?: string | null;
|
|
34
36
|
/** Filter ordered_at_timestamp <= value */
|
|
35
37
|
filter_ordered_at_timestamp_lte?: string | null;
|
|
38
|
+
/** Filter completed_at_timestamp >= value */
|
|
39
|
+
filter_completed_at_timestamp_gte?: string | null;
|
|
40
|
+
/** Filter completed_at_timestamp <= value */
|
|
41
|
+
filter_completed_at_timestamp_lte?: string | null;
|
|
36
42
|
/** Filter last_mirrored_at_timestamp >= value */
|
|
37
43
|
filter_last_mirrored_at_timestamp_gte?: string | null;
|
|
38
44
|
/** Filter last_mirrored_at_timestamp <= value */
|
package/dist/cjs/api/resources/shippingIntegrations/resources/orders/client/requests/index.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
export { type OrdersListForIntegrationExecutorOperatorsV1Request } from "./OrdersListForIntegrationExecutorOperatorsV1Request.js";
|
|
1
2
|
export { type OrdersListV1Request } from "./OrdersListV1Request.js";
|
|
2
3
|
export { type OrdersStatusSummaryV1Request } from "./OrdersStatusSummaryV1Request.js";
|
|
3
4
|
export { type OrdersTypeaheadV1Request } from "./OrdersTypeaheadV1Request.js";
|