@chrt-inc/typescript-sdk 1.746.0 → 1.751.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 +13 -0
- package/dist/cjs/api/resources/shipping/resources/flights/client/Client.js +59 -0
- package/dist/cjs/api/resources/shipping/resources/orderDrafts/resources/cargo/client/requests/OrderDraftAddCargoReq.d.ts +1 -1
- package/dist/cjs/api/resources/shipping/resources/orderDrafts/resources/task/client/requests/OrderDraftAddTaskReqV1.d.ts +1 -1
- package/dist/cjs/api/resources/shipping/resources/orderDrafts/resources/taskArtifact/client/requests/OrderDraftAddTaskArtifactReq.d.ts +1 -1
- package/dist/cjs/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/Client.d.ts +8 -2
- package/dist/cjs/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/Client.js +8 -2
- package/dist/cjs/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/requests/OrderDraftAddTaskGroupReq.d.ts +1 -1
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/client/Client.d.ts +25 -41
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/client/Client.js +51 -125
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/client/requests/OrderSchedulesListV1Request.d.ts +2 -4
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/client/requests/index.d.ts +0 -2
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/client/Client.d.ts +64 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/client/Client.js +196 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/client/index.d.ts +2 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/client/index.js +17 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientCreate1.d.ts +4 -6
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientUpdate1.d.ts +2 -2
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/client/requests/index.d.ts +2 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/index.d.ts +1 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/draft/index.js +17 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/index.d.ts +2 -0
- package/dist/cjs/api/resources/shipping/resources/orderSchedules/resources/index.js +6 -1
- package/dist/cjs/api/resources/shipping/resources/taskGroups/client/Client.d.ts +8 -2
- package/dist/cjs/api/resources/shipping/resources/taskGroups/client/Client.js +8 -2
- package/dist/cjs/api/resources/shipping/resources/taskGroups/resources/expanded/client/requests/ExpandedListForDriverForExecutorV1Request.d.ts +1 -1
- package/dist/cjs/api/resources/shipping/resources/taskGroups/resources/expanded/client/requests/ExpandedListForExecutorOperatorsV1Request.d.ts +1 -1
- package/dist/cjs/api/resources/utils/resources/dev/client/Client.d.ts +0 -13
- package/dist/cjs/api/resources/utils/resources/dev/client/Client.js +0 -62
- package/dist/cjs/api/resources/utils/resources/dev/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/types/Cargo1.d.ts +1 -3
- package/dist/cjs/api/types/CargoManifest1.d.ts +6 -0
- package/dist/cjs/api/types/FlightInfoForTaskRes.d.ts +4 -3
- package/dist/cjs/api/types/FlightLeg1.d.ts +19 -0
- package/dist/cjs/api/types/FlightLegClientCreate1.d.ts +16 -0
- package/dist/cjs/api/types/FlightLegProvenanceEnum1.d.ts +9 -0
- package/dist/cjs/api/types/FlightLegProvenanceEnum1.js +11 -0
- package/dist/cjs/api/types/FlightLegWebhookInfo.d.ts +22 -0
- package/dist/cjs/api/types/OrderManifest1.d.ts +2 -2
- package/dist/cjs/api/types/OrderSchedule1.d.ts +6 -7
- package/dist/cjs/api/types/OrderScheduleAboutRes.d.ts +1 -1
- package/dist/cjs/api/types/OrderScheduleOrchestratorScheduleStatus.d.ts +0 -1
- package/dist/cjs/api/types/OrderScheduleSortByEnum.d.ts +2 -2
- package/dist/cjs/api/types/OrderScheduleSortByEnum.js +1 -1
- package/dist/cjs/api/types/OrderScheduleSpec1.d.ts +11 -0
- package/dist/cjs/api/types/OrderScheduleSpec1.js +5 -0
- package/dist/cjs/api/types/SetFlightInfoReq.d.ts +3 -4
- package/dist/cjs/api/types/ShippingTaskGroupFlightInfoUpdatedWebhookPayload.d.ts +3 -4
- package/dist/cjs/api/types/Task1.d.ts +2 -4
- package/dist/cjs/api/types/TaskArtifact1.d.ts +1 -3
- package/dist/cjs/api/types/TaskClientCreate1.d.ts +1 -1
- package/dist/cjs/api/types/TaskGroup1.d.ts +2 -5
- package/dist/cjs/api/types/TaskGroupManifest1.d.ts +1 -1
- package/dist/cjs/api/types/TaskManifest1.d.ts +13 -4
- package/dist/cjs/api/types/index.d.ts +5 -3
- package/dist/cjs/api/types/index.js +5 -3
- 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 +13 -0
- package/dist/esm/api/resources/shipping/resources/flights/client/Client.mjs +59 -0
- package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/cargo/client/requests/OrderDraftAddCargoReq.d.mts +1 -1
- package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/task/client/requests/OrderDraftAddTaskReqV1.d.mts +1 -1
- package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/taskArtifact/client/requests/OrderDraftAddTaskArtifactReq.d.mts +1 -1
- package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/Client.d.mts +8 -2
- package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/Client.mjs +8 -2
- package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/requests/OrderDraftAddTaskGroupReq.d.mts +1 -1
- package/dist/esm/api/resources/shipping/resources/orderSchedules/client/Client.d.mts +25 -41
- package/dist/esm/api/resources/shipping/resources/orderSchedules/client/Client.mjs +49 -123
- package/dist/esm/api/resources/shipping/resources/orderSchedules/client/requests/OrderSchedulesListV1Request.d.mts +2 -4
- package/dist/esm/api/resources/shipping/resources/orderSchedules/client/requests/index.d.mts +0 -2
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/client/Client.d.mts +64 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/client/Client.mjs +159 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/client/index.d.mts +2 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/client/index.mjs +1 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientCreate1.d.mts +4 -6
- package/dist/esm/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientUpdate1.d.mts +2 -2
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/client/requests/index.d.mts +2 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/index.d.mts +1 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/draft/index.mjs +1 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/index.d.mts +2 -0
- package/dist/esm/api/resources/shipping/resources/orderSchedules/resources/index.mjs +2 -0
- package/dist/esm/api/resources/shipping/resources/taskGroups/client/Client.d.mts +8 -2
- package/dist/esm/api/resources/shipping/resources/taskGroups/client/Client.mjs +8 -2
- package/dist/esm/api/resources/shipping/resources/taskGroups/resources/expanded/client/requests/ExpandedListForDriverForExecutorV1Request.d.mts +1 -1
- package/dist/esm/api/resources/shipping/resources/taskGroups/resources/expanded/client/requests/ExpandedListForExecutorOperatorsV1Request.d.mts +1 -1
- package/dist/esm/api/resources/utils/resources/dev/client/Client.d.mts +0 -13
- package/dist/esm/api/resources/utils/resources/dev/client/Client.mjs +0 -62
- package/dist/esm/api/resources/utils/resources/dev/client/requests/index.d.mts +0 -1
- package/dist/esm/api/types/Cargo1.d.mts +1 -3
- package/dist/esm/api/types/CargoManifest1.d.mts +6 -0
- package/dist/esm/api/types/FlightInfoForTaskRes.d.mts +4 -3
- package/dist/esm/api/types/FlightLeg1.d.mts +19 -0
- package/dist/esm/api/types/FlightLegClientCreate1.d.mts +16 -0
- package/dist/esm/api/types/FlightLegProvenanceEnum1.d.mts +9 -0
- package/dist/esm/api/types/FlightLegProvenanceEnum1.mjs +8 -0
- package/dist/esm/api/types/FlightLegWebhookInfo.d.mts +22 -0
- package/dist/esm/api/types/OrderManifest1.d.mts +2 -2
- package/dist/esm/api/types/OrderSchedule1.d.mts +6 -7
- package/dist/esm/api/types/OrderScheduleAboutRes.d.mts +1 -1
- package/dist/esm/api/types/OrderScheduleOrchestratorScheduleStatus.d.mts +0 -1
- package/dist/esm/api/types/OrderScheduleSortByEnum.d.mts +2 -2
- package/dist/esm/api/types/OrderScheduleSortByEnum.mjs +1 -1
- package/dist/esm/api/types/OrderScheduleSpec1.d.mts +11 -0
- package/dist/esm/api/types/OrderScheduleSpec1.mjs +4 -0
- package/dist/esm/api/types/SetFlightInfoReq.d.mts +3 -4
- package/dist/esm/api/types/ShippingTaskGroupFlightInfoUpdatedWebhookPayload.d.mts +3 -4
- package/dist/esm/api/types/Task1.d.mts +2 -4
- package/dist/esm/api/types/TaskArtifact1.d.mts +1 -3
- package/dist/esm/api/types/TaskClientCreate1.d.mts +1 -1
- package/dist/esm/api/types/TaskGroup1.d.mts +2 -5
- package/dist/esm/api/types/TaskGroupManifest1.d.mts +1 -1
- package/dist/esm/api/types/TaskManifest1.d.mts +13 -4
- package/dist/esm/api/types/index.d.mts +5 -3
- package/dist/esm/api/types/index.mjs +5 -3
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +239 -160
- package/dist/cjs/api/resources/utils/resources/dev/client/requests/ScheduledPingReq.d.ts +0 -13
- package/dist/cjs/api/types/OrderScheduleOrchestratorScheduleStatusEnum1.d.ts +0 -10
- package/dist/cjs/api/types/OrderScheduleOrchestratorScheduleStatusEnum1.js +0 -12
- package/dist/cjs/api/types/ScheduleSpec.d.ts +0 -14
- package/dist/cjs/api/types/ScheduledPingRes.d.ts +0 -16
- package/dist/esm/api/resources/utils/resources/dev/client/requests/ScheduledPingReq.d.mts +0 -13
- package/dist/esm/api/types/OrderScheduleOrchestratorScheduleStatusEnum1.d.mts +0 -10
- package/dist/esm/api/types/OrderScheduleOrchestratorScheduleStatusEnum1.mjs +0 -9
- package/dist/esm/api/types/ScheduleSpec.d.mts +0 -14
- package/dist/esm/api/types/ScheduledPingRes.d.mts +0 -16
- /package/dist/cjs/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientCreate1.js +0 -0
- /package/dist/cjs/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientUpdate1.js +0 -0
- /package/dist/cjs/api/{resources/utils/resources/dev/client/requests/ScheduledPingReq.js → types/FlightLeg1.js} +0 -0
- /package/dist/cjs/api/types/{ScheduleSpec.js → FlightLegClientCreate1.js} +0 -0
- /package/dist/cjs/api/types/{ScheduledPingRes.js → FlightLegWebhookInfo.js} +0 -0
- /package/dist/esm/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientCreate1.mjs +0 -0
- /package/dist/esm/api/resources/shipping/resources/orderSchedules/{client → resources/draft/client}/requests/OrderScheduleClientUpdate1.mjs +0 -0
- /package/dist/esm/api/{resources/utils/resources/dev/client/requests/ScheduledPingReq.mjs → types/FlightLeg1.mjs} +0 -0
- /package/dist/esm/api/types/{ScheduleSpec.mjs → FlightLegClientCreate1.mjs} +0 -0
- /package/dist/esm/api/types/{ScheduledPingRes.mjs → FlightLegWebhookInfo.mjs} +0 -0
|
@@ -3,15 +3,24 @@
|
|
|
3
3
|
*/
|
|
4
4
|
import * as Chrt from "../index.js";
|
|
5
5
|
/**
|
|
6
|
-
* Task template
|
|
6
|
+
* Task template within an order manifest.
|
|
7
|
+
*
|
|
8
|
+
* Inherits the shared task core (TaskCore1) so the physical fields cannot drift
|
|
9
|
+
* from the real task, and adds the template-only fields: relative time windows
|
|
10
|
+
* (resolved against the fire time at build), positional task->cargo references,
|
|
11
|
+
* and the artifact types to create for the task.
|
|
7
12
|
*/
|
|
8
13
|
export interface TaskManifest1 {
|
|
9
14
|
schema_version: number;
|
|
10
15
|
location?: Chrt.LocationFeature | null;
|
|
11
|
-
|
|
12
|
-
|
|
16
|
+
geofence_distance_miles?: number;
|
|
17
|
+
action?: TaskManifest1.Action | null;
|
|
13
18
|
order_placer_comments?: string | null;
|
|
14
19
|
directory_entry_ids?: string[];
|
|
15
|
-
|
|
20
|
+
time_windows?: Chrt.TimeWindow1[];
|
|
21
|
+
cargo_manifest_indices?: number[];
|
|
16
22
|
task_artifact_types?: Chrt.TaskArtifactTypeEnum1[];
|
|
17
23
|
}
|
|
24
|
+
export declare namespace TaskManifest1 {
|
|
25
|
+
type Action = Chrt.ChrtGroundProviderTaskActionEnum1 | Chrt.CargoOnFlightTaskActionEnum1 | Chrt.OnboardCourierTaskActionEnum1;
|
|
26
|
+
}
|
|
@@ -148,6 +148,10 @@ export * from "./FlightAwareAlertFlight.js";
|
|
|
148
148
|
export * from "./FlightAwareAlertPayload.js";
|
|
149
149
|
export * from "./FlightAwareWebhookResponse.js";
|
|
150
150
|
export * from "./FlightInfoForTaskRes.js";
|
|
151
|
+
export * from "./FlightLeg1.js";
|
|
152
|
+
export * from "./FlightLegClientCreate1.js";
|
|
153
|
+
export * from "./FlightLegProvenanceEnum1.js";
|
|
154
|
+
export * from "./FlightLegWebhookInfo.js";
|
|
151
155
|
export * from "./FlightStatusEnum.js";
|
|
152
156
|
export * from "./GeometryCollectionGeometriesItem.js";
|
|
153
157
|
export * from "./GeometryCollection.js";
|
|
@@ -240,8 +244,8 @@ export * from "./OrderScheduleAboutRes.js";
|
|
|
240
244
|
export * from "./OrderScheduleListRes.js";
|
|
241
245
|
export * from "./OrderScheduleOrchestratorScheduleActionResult.js";
|
|
242
246
|
export * from "./OrderScheduleOrchestratorScheduleStatus.js";
|
|
243
|
-
export * from "./OrderScheduleOrchestratorScheduleStatusEnum1.js";
|
|
244
247
|
export * from "./OrderScheduleSortByEnum.js";
|
|
248
|
+
export * from "./OrderScheduleSpec1.js";
|
|
245
249
|
export * from "./OrderScheduleStatusEnum1.js";
|
|
246
250
|
export * from "./OrderSortByEnum.js";
|
|
247
251
|
export * from "./OrderStatusEnum1.js";
|
|
@@ -294,9 +298,7 @@ export * from "./ScanPayloadKindEnum.js";
|
|
|
294
298
|
export * from "./ScheduleCalendarSpec.js";
|
|
295
299
|
export * from "./ScheduleIntervalSpec.js";
|
|
296
300
|
export * from "./ScheduleRange.js";
|
|
297
|
-
export * from "./ScheduleSpec.js";
|
|
298
301
|
export * from "./ScheduledOrdersNewDraftReq.js";
|
|
299
|
-
export * from "./ScheduledPingRes.js";
|
|
300
302
|
export * from "./Session1.js";
|
|
301
303
|
export * from "./SessionByDeviceDataPoint1.js";
|
|
302
304
|
export * from "./SessionByDeviceDataPointMetadata1.js";
|
|
@@ -164,6 +164,10 @@ __exportStar(require("./FlightAwareAlertFlight.js"), exports);
|
|
|
164
164
|
__exportStar(require("./FlightAwareAlertPayload.js"), exports);
|
|
165
165
|
__exportStar(require("./FlightAwareWebhookResponse.js"), exports);
|
|
166
166
|
__exportStar(require("./FlightInfoForTaskRes.js"), exports);
|
|
167
|
+
__exportStar(require("./FlightLeg1.js"), exports);
|
|
168
|
+
__exportStar(require("./FlightLegClientCreate1.js"), exports);
|
|
169
|
+
__exportStar(require("./FlightLegProvenanceEnum1.js"), exports);
|
|
170
|
+
__exportStar(require("./FlightLegWebhookInfo.js"), exports);
|
|
167
171
|
__exportStar(require("./FlightStatusEnum.js"), exports);
|
|
168
172
|
__exportStar(require("./GeometryCollectionGeometriesItem.js"), exports);
|
|
169
173
|
__exportStar(require("./GeometryCollection.js"), exports);
|
|
@@ -256,8 +260,8 @@ __exportStar(require("./OrderScheduleAboutRes.js"), exports);
|
|
|
256
260
|
__exportStar(require("./OrderScheduleListRes.js"), exports);
|
|
257
261
|
__exportStar(require("./OrderScheduleOrchestratorScheduleActionResult.js"), exports);
|
|
258
262
|
__exportStar(require("./OrderScheduleOrchestratorScheduleStatus.js"), exports);
|
|
259
|
-
__exportStar(require("./OrderScheduleOrchestratorScheduleStatusEnum1.js"), exports);
|
|
260
263
|
__exportStar(require("./OrderScheduleSortByEnum.js"), exports);
|
|
264
|
+
__exportStar(require("./OrderScheduleSpec1.js"), exports);
|
|
261
265
|
__exportStar(require("./OrderScheduleStatusEnum1.js"), exports);
|
|
262
266
|
__exportStar(require("./OrderSortByEnum.js"), exports);
|
|
263
267
|
__exportStar(require("./OrderStatusEnum1.js"), exports);
|
|
@@ -310,9 +314,7 @@ __exportStar(require("./ScanPayloadKindEnum.js"), exports);
|
|
|
310
314
|
__exportStar(require("./ScheduleCalendarSpec.js"), exports);
|
|
311
315
|
__exportStar(require("./ScheduleIntervalSpec.js"), exports);
|
|
312
316
|
__exportStar(require("./ScheduleRange.js"), exports);
|
|
313
|
-
__exportStar(require("./ScheduleSpec.js"), exports);
|
|
314
317
|
__exportStar(require("./ScheduledOrdersNewDraftReq.js"), exports);
|
|
315
|
-
__exportStar(require("./ScheduledPingRes.js"), exports);
|
|
316
318
|
__exportStar(require("./Session1.js"), exports);
|
|
317
319
|
__exportStar(require("./SessionByDeviceDataPoint1.js"), exports);
|
|
318
320
|
__exportStar(require("./SessionByDeviceDataPointMetadata1.js"), exports);
|
package/dist/cjs/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.
|
|
1
|
+
export declare const SDK_VERSION = "1.751.0";
|
package/dist/cjs/version.js
CHANGED
package/dist/esm/Client.mjs
CHANGED
|
@@ -20,8 +20,8 @@ export class ChrtClient {
|
|
|
20
20
|
this._options = Object.assign(Object.assign({}, _options), { headers: mergeHeaders({
|
|
21
21
|
"X-Fern-Language": "JavaScript",
|
|
22
22
|
"X-Fern-SDK-Name": "@chrt-inc/typescript-sdk",
|
|
23
|
-
"X-Fern-SDK-Version": "1.
|
|
24
|
-
"User-Agent": "@chrt-inc/typescript-sdk/1.
|
|
23
|
+
"X-Fern-SDK-Version": "1.751.0",
|
|
24
|
+
"User-Agent": "@chrt-inc/typescript-sdk/1.751.0",
|
|
25
25
|
"X-Fern-Runtime": core.RUNTIME.type,
|
|
26
26
|
"X-Fern-Runtime-Version": core.RUNTIME.version,
|
|
27
27
|
}, _options === null || _options === void 0 ? void 0 : _options.headers) });
|
|
@@ -43,5 +43,18 @@ export declare class Flights {
|
|
|
43
43
|
*/
|
|
44
44
|
getFlightInfoForTaskV1(taskId: string, requestOptions?: Flights.RequestOptions): core.HttpResponsePromise<Chrt.FlightInfoForTaskRes>;
|
|
45
45
|
private __getFlightInfoForTaskV1;
|
|
46
|
+
/**
|
|
47
|
+
* Returns the ordered list of flight legs for a task group. | authz_personas=[driver_for_executor, coordinator_org_operators, executor_org_operators, shipper_org_operators] | () -> (FlightInfoForTaskRes)
|
|
48
|
+
*
|
|
49
|
+
* @param {string} taskGroupId
|
|
50
|
+
* @param {Flights.RequestOptions} requestOptions - Request-specific configuration.
|
|
51
|
+
*
|
|
52
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* await client.shipping.flights.getFlightLegsForTaskGroupV1("task_group_id")
|
|
56
|
+
*/
|
|
57
|
+
getFlightLegsForTaskGroupV1(taskGroupId: string, requestOptions?: Flights.RequestOptions): core.HttpResponsePromise<Chrt.FlightInfoForTaskRes>;
|
|
58
|
+
private __getFlightLegsForTaskGroupV1;
|
|
46
59
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
47
60
|
}
|
|
@@ -78,6 +78,65 @@ export class Flights {
|
|
|
78
78
|
}
|
|
79
79
|
});
|
|
80
80
|
}
|
|
81
|
+
/**
|
|
82
|
+
* Returns the ordered list of flight legs for a task group. | authz_personas=[driver_for_executor, coordinator_org_operators, executor_org_operators, shipper_org_operators] | () -> (FlightInfoForTaskRes)
|
|
83
|
+
*
|
|
84
|
+
* @param {string} taskGroupId
|
|
85
|
+
* @param {Flights.RequestOptions} requestOptions - Request-specific configuration.
|
|
86
|
+
*
|
|
87
|
+
* @throws {@link Chrt.UnprocessableEntityError}
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* await client.shipping.flights.getFlightLegsForTaskGroupV1("task_group_id")
|
|
91
|
+
*/
|
|
92
|
+
getFlightLegsForTaskGroupV1(taskGroupId, requestOptions) {
|
|
93
|
+
return core.HttpResponsePromise.fromPromise(this.__getFlightLegsForTaskGroupV1(taskGroupId, requestOptions));
|
|
94
|
+
}
|
|
95
|
+
__getFlightLegsForTaskGroupV1(taskGroupId, requestOptions) {
|
|
96
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
97
|
+
var _a, _b, _c, _d;
|
|
98
|
+
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
99
|
+
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
100
|
+
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/flights/for_task_group/v1/${encodeURIComponent(taskGroupId)}`),
|
|
101
|
+
method: "GET",
|
|
102
|
+
headers: _headers,
|
|
103
|
+
queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
|
|
104
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
105
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
106
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
107
|
+
});
|
|
108
|
+
if (_response.ok) {
|
|
109
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
110
|
+
}
|
|
111
|
+
if (_response.error.reason === "status-code") {
|
|
112
|
+
switch (_response.error.statusCode) {
|
|
113
|
+
case 422:
|
|
114
|
+
throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
115
|
+
default:
|
|
116
|
+
throw new errors.ChrtError({
|
|
117
|
+
statusCode: _response.error.statusCode,
|
|
118
|
+
body: _response.error.body,
|
|
119
|
+
rawResponse: _response.rawResponse,
|
|
120
|
+
});
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
switch (_response.error.reason) {
|
|
124
|
+
case "non-json":
|
|
125
|
+
throw new errors.ChrtError({
|
|
126
|
+
statusCode: _response.error.statusCode,
|
|
127
|
+
body: _response.error.rawBody,
|
|
128
|
+
rawResponse: _response.rawResponse,
|
|
129
|
+
});
|
|
130
|
+
case "timeout":
|
|
131
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /shipping/flights/for_task_group/v1/{task_group_id}.");
|
|
132
|
+
case "unknown":
|
|
133
|
+
throw new errors.ChrtError({
|
|
134
|
+
message: _response.error.errorMessage,
|
|
135
|
+
rawResponse: _response.rawResponse,
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
});
|
|
139
|
+
}
|
|
81
140
|
_getAuthorizationHeader() {
|
|
82
141
|
return __awaiter(this, void 0, void 0, function* () {
|
|
83
142
|
const bearer = yield core.Supplier.get(this._options.token);
|
|
@@ -15,5 +15,5 @@ import * as Chrt from "../../../../../../../../index.mjs";
|
|
|
15
15
|
export interface OrderDraftAddCargoReq {
|
|
16
16
|
order_id: string;
|
|
17
17
|
cargo: Chrt.CargoClientCreate1;
|
|
18
|
-
|
|
18
|
+
order_schedule_template_path_idempotency_key?: string | null;
|
|
19
19
|
}
|
|
@@ -13,5 +13,5 @@ export interface OrderDraftAddTaskArtifactReq {
|
|
|
13
13
|
task_id: string;
|
|
14
14
|
task_artifact_type: Chrt.TaskArtifactTypeEnum1;
|
|
15
15
|
expected_scan_payloads?: string[];
|
|
16
|
-
|
|
16
|
+
order_schedule_template_path_idempotency_key?: string | null;
|
|
17
17
|
}
|
|
@@ -47,7 +47,7 @@ export declare class TaskGroup {
|
|
|
47
47
|
addV1(request: Chrt.shipping.orderDrafts.OrderDraftAddTaskGroupReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<string>;
|
|
48
48
|
private __addV1;
|
|
49
49
|
/**
|
|
50
|
-
*
|
|
50
|
+
* Replaces the ordered list of flights on a draft task group. | (SetFlightInfoReq) -> (bool)
|
|
51
51
|
*
|
|
52
52
|
* @param {string} taskGroupId
|
|
53
53
|
* @param {Chrt.SetFlightInfoReq} request
|
|
@@ -56,7 +56,13 @@ export declare class TaskGroup {
|
|
|
56
56
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
57
57
|
*
|
|
58
58
|
* @example
|
|
59
|
-
* await client.shipping.orderDrafts.taskGroup.setFlightInfoV1("task_group_id", {
|
|
59
|
+
* await client.shipping.orderDrafts.taskGroup.setFlightInfoV1("task_group_id", {
|
|
60
|
+
* flight_legs: [{
|
|
61
|
+
* schema_version: 1,
|
|
62
|
+
* flight_number: "flight_number",
|
|
63
|
+
* provenance: "manual"
|
|
64
|
+
* }]
|
|
65
|
+
* })
|
|
60
66
|
*/
|
|
61
67
|
setFlightInfoV1(taskGroupId: string, request: Chrt.SetFlightInfoReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
62
68
|
private __setFlightInfoV1;
|
package/dist/esm/api/resources/shipping/resources/orderDrafts/resources/taskGroup/client/Client.mjs
CHANGED
|
@@ -85,7 +85,7 @@ export class TaskGroup {
|
|
|
85
85
|
});
|
|
86
86
|
}
|
|
87
87
|
/**
|
|
88
|
-
*
|
|
88
|
+
* Replaces the ordered list of flights on a draft task group. | (SetFlightInfoReq) -> (bool)
|
|
89
89
|
*
|
|
90
90
|
* @param {string} taskGroupId
|
|
91
91
|
* @param {Chrt.SetFlightInfoReq} request
|
|
@@ -94,7 +94,13 @@ export class TaskGroup {
|
|
|
94
94
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
95
95
|
*
|
|
96
96
|
* @example
|
|
97
|
-
* await client.shipping.orderDrafts.taskGroup.setFlightInfoV1("task_group_id", {
|
|
97
|
+
* await client.shipping.orderDrafts.taskGroup.setFlightInfoV1("task_group_id", {
|
|
98
|
+
* flight_legs: [{
|
|
99
|
+
* schema_version: 1,
|
|
100
|
+
* flight_number: "flight_number",
|
|
101
|
+
* provenance: "manual"
|
|
102
|
+
* }]
|
|
103
|
+
* })
|
|
98
104
|
*/
|
|
99
105
|
setFlightInfoV1(taskGroupId, request, requestOptions) {
|
|
100
106
|
return core.HttpResponsePromise.fromPromise(this.__setFlightInfoV1(taskGroupId, request, requestOptions));
|
|
@@ -12,6 +12,6 @@ import * as Chrt from "../../../../../../../../index.mjs";
|
|
|
12
12
|
export interface OrderDraftAddTaskGroupReq {
|
|
13
13
|
task_group_type: Chrt.TaskGroupTypeEnum1;
|
|
14
14
|
order_id: string;
|
|
15
|
-
|
|
15
|
+
order_schedule_template_path_idempotency_key?: string | null;
|
|
16
16
|
vehicle_type?: Chrt.VehicleTypeEnum | null;
|
|
17
17
|
}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import * as environments from "../../../../../../environments.mjs";
|
|
5
5
|
import * as core from "../../../../../../core/index.mjs";
|
|
6
6
|
import * as Chrt from "../../../../../index.mjs";
|
|
7
|
+
import { Draft } from "../resources/draft/client/Client.mjs";
|
|
7
8
|
import { OrderManifest } from "../resources/orderManifest/client/Client.mjs";
|
|
8
9
|
export declare namespace OrderSchedules {
|
|
9
10
|
interface Options {
|
|
@@ -30,8 +31,10 @@ export declare namespace OrderSchedules {
|
|
|
30
31
|
}
|
|
31
32
|
export declare class OrderSchedules {
|
|
32
33
|
protected readonly _options: OrderSchedules.Options;
|
|
34
|
+
protected _draft: Draft | undefined;
|
|
33
35
|
protected _orderManifest: OrderManifest | undefined;
|
|
34
36
|
constructor(_options?: OrderSchedules.Options);
|
|
37
|
+
get draft(): Draft;
|
|
35
38
|
get orderManifest(): OrderManifest;
|
|
36
39
|
/**
|
|
37
40
|
* Lists order schedules for the caller's organization with filtering, sorting, and pagination. | authz: min_org_role=operator | () -> (OrderScheduleListRes)
|
|
@@ -70,7 +73,7 @@ export declare class OrderSchedules {
|
|
|
70
73
|
getByIdV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<Chrt.OrderSchedule1>;
|
|
71
74
|
private __getByIdV1;
|
|
72
75
|
/**
|
|
73
|
-
* Retrieves
|
|
76
|
+
* Retrieves the generated order count and live orchestrator status from Temporal. | authz: min_org_role=operator | () -> (OrderScheduleAboutRes)
|
|
74
77
|
*
|
|
75
78
|
* @param {string} orderScheduleId
|
|
76
79
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -83,39 +86,20 @@ export declare class OrderSchedules {
|
|
|
83
86
|
aboutV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<Chrt.OrderScheduleAboutRes>;
|
|
84
87
|
private __aboutV1;
|
|
85
88
|
/**
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
* @param {Chrt.shipping.OrderScheduleClientCreate1} request
|
|
89
|
-
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
90
|
-
*
|
|
91
|
-
* @throws {@link Chrt.UnprocessableEntityError}
|
|
92
|
-
*
|
|
93
|
-
* @example
|
|
94
|
-
* await client.shipping.orderSchedules.newV1({
|
|
95
|
-
* schema_version: 1,
|
|
96
|
-
* name: "name",
|
|
97
|
-
* order_manifest: {},
|
|
98
|
-
* schedule_spec: {}
|
|
99
|
-
* })
|
|
100
|
-
*/
|
|
101
|
-
newV1(request: Chrt.shipping.OrderScheduleClientCreate1, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<string>;
|
|
102
|
-
private __newV1;
|
|
103
|
-
/**
|
|
104
|
-
* Updates an order schedule. | authz: min_org_role=operator | (OrderScheduleClientUpdate1) -> (bool)
|
|
89
|
+
* Validates a draft order schedule, creates its Temporal orchestrator schedule, and activates it. | authz: min_org_role=operator | () -> (bool)
|
|
105
90
|
*
|
|
106
91
|
* @param {string} orderScheduleId
|
|
107
|
-
* @param {Chrt.shipping.OrderScheduleClientUpdate1} request
|
|
108
92
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
109
93
|
*
|
|
110
94
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
111
95
|
*
|
|
112
96
|
* @example
|
|
113
|
-
* await client.shipping.orderSchedules.
|
|
97
|
+
* await client.shipping.orderSchedules.activateV1("order_schedule_id")
|
|
114
98
|
*/
|
|
115
|
-
|
|
116
|
-
private
|
|
99
|
+
activateV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
100
|
+
private __activateV1;
|
|
117
101
|
/**
|
|
118
|
-
*
|
|
102
|
+
* Triggers an order schedule immediately. | authz: min_org_role=operator | () -> (bool)
|
|
119
103
|
*
|
|
120
104
|
* @param {string} orderScheduleId
|
|
121
105
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -123,12 +107,12 @@ export declare class OrderSchedules {
|
|
|
123
107
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
124
108
|
*
|
|
125
109
|
* @example
|
|
126
|
-
* await client.shipping.orderSchedules.
|
|
110
|
+
* await client.shipping.orderSchedules.triggerV1("order_schedule_id")
|
|
127
111
|
*/
|
|
128
|
-
|
|
129
|
-
private
|
|
112
|
+
triggerV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
113
|
+
private __triggerV1;
|
|
130
114
|
/**
|
|
131
|
-
*
|
|
115
|
+
* Pauses an active order schedule. | authz: min_org_role=operator | () -> (bool)
|
|
132
116
|
*
|
|
133
117
|
* @param {string} orderScheduleId
|
|
134
118
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -136,10 +120,10 @@ export declare class OrderSchedules {
|
|
|
136
120
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
137
121
|
*
|
|
138
122
|
* @example
|
|
139
|
-
* await client.shipping.orderSchedules.
|
|
123
|
+
* await client.shipping.orderSchedules.pauseV1("order_schedule_id")
|
|
140
124
|
*/
|
|
141
|
-
|
|
142
|
-
private
|
|
125
|
+
pauseV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
126
|
+
private __pauseV1;
|
|
143
127
|
/**
|
|
144
128
|
* Unpauses a paused order schedule. | authz: min_org_role=operator | () -> (bool)
|
|
145
129
|
*
|
|
@@ -154,7 +138,7 @@ export declare class OrderSchedules {
|
|
|
154
138
|
unpauseV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
155
139
|
private __unpauseV1;
|
|
156
140
|
/**
|
|
157
|
-
*
|
|
141
|
+
* Transfers order schedule workflow ownership to the caller. | authz: min_org_role=operator | () -> (bool)
|
|
158
142
|
*
|
|
159
143
|
* @param {string} orderScheduleId
|
|
160
144
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -162,12 +146,12 @@ export declare class OrderSchedules {
|
|
|
162
146
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
163
147
|
*
|
|
164
148
|
* @example
|
|
165
|
-
* await client.shipping.orderSchedules.
|
|
149
|
+
* await client.shipping.orderSchedules.takeOwnershipV1("order_schedule_id")
|
|
166
150
|
*/
|
|
167
|
-
|
|
168
|
-
private
|
|
151
|
+
takeOwnershipV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
152
|
+
private __takeOwnershipV1;
|
|
169
153
|
/**
|
|
170
|
-
* Archives an order schedule and
|
|
154
|
+
* Archives an order schedule and deletes its Temporal schedule, preventing future runs. | authz: min_org_role=operator | () -> (bool)
|
|
171
155
|
*
|
|
172
156
|
* @param {string} orderScheduleId
|
|
173
157
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -180,7 +164,7 @@ export declare class OrderSchedules {
|
|
|
180
164
|
archiveV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
181
165
|
private __archiveV1;
|
|
182
166
|
/**
|
|
183
|
-
*
|
|
167
|
+
* Re-syncs the Temporal schedule to match the order schedule's intended status. | authz: min_org_role=operator | () -> (bool)
|
|
184
168
|
*
|
|
185
169
|
* @param {string} orderScheduleId
|
|
186
170
|
* @param {OrderSchedules.RequestOptions} requestOptions - Request-specific configuration.
|
|
@@ -188,9 +172,9 @@ export declare class OrderSchedules {
|
|
|
188
172
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
189
173
|
*
|
|
190
174
|
* @example
|
|
191
|
-
* await client.shipping.orderSchedules.
|
|
175
|
+
* await client.shipping.orderSchedules.syncWithOrchestratorV1("order_schedule_id")
|
|
192
176
|
*/
|
|
193
|
-
|
|
194
|
-
private
|
|
177
|
+
syncWithOrchestratorV1(orderScheduleId: string, requestOptions?: OrderSchedules.RequestOptions): core.HttpResponsePromise<boolean>;
|
|
178
|
+
private __syncWithOrchestratorV1;
|
|
195
179
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
196
180
|
}
|