@chrt-inc/typescript-sdk 1.331.0 → 1.334.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.d.ts +3 -0
- package/dist/cjs/Client.js +41 -36
- package/dist/cjs/api/resources/drivers/client/Client.d.ts +0 -24
- package/dist/cjs/api/resources/drivers/client/Client.js +0 -73
- package/dist/cjs/api/resources/drivers/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/flights/client/Client.d.ts +47 -0
- package/dist/cjs/api/resources/flights/client/Client.js +127 -0
- package/dist/cjs/api/resources/index.d.ts +1 -0
- package/dist/cjs/api/resources/index.js +2 -1
- package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/Client.d.ts +5 -7
- package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/Client.js +8 -10
- package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/taskGroups/client/Client.d.ts +5 -7
- package/dist/cjs/api/resources/taskGroups/client/Client.js +8 -10
- package/dist/cjs/api/resources/taskGroups/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/resources/tracking/client/Client.d.ts +3 -3
- package/dist/cjs/api/resources/tracking/client/Client.js +3 -3
- package/dist/cjs/api/resources/tracking/resources/driver/client/Client.d.ts +10 -13
- package/dist/cjs/api/resources/tracking/resources/driver/client/Client.js +9 -12
- package/dist/cjs/api/resources/tracking/resources/driver/client/index.d.ts +0 -1
- package/dist/cjs/api/resources/tracking/resources/driver/client/index.js +0 -15
- package/dist/cjs/api/resources/tracking/resources/index.d.ts +2 -3
- package/dist/cjs/api/resources/tracking/resources/index.js +3 -4
- package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.d.ts +16 -16
- package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.js +17 -17
- package/dist/cjs/api/resources/tracking/resources/sharingSettings/index.d.ts +1 -0
- package/dist/cjs/api/resources/tracking/resources/sharingSettings/index.js +17 -0
- package/dist/cjs/api/resources/tracking/resources/timeseries/resources/cargoByDevice/client/Client.js +10 -10
- package/dist/cjs/api/resources/tracking/resources/timeseries/resources/cargoByDriver/client/Client.js +8 -8
- package/dist/cjs/api/resources/tracking/resources/timeseries/resources/sessionByDevice/client/Client.js +10 -10
- package/dist/cjs/api/resources/tracking/resources/timeseries/resources/taskGroupByDriver/client/Client.js +8 -8
- package/dist/cjs/api/types/FlightInfoForTaskRes.d.ts +10 -0
- package/dist/cjs/api/types/SetFlightInfoReq.d.ts +9 -0
- package/dist/cjs/api/types/Task1.d.ts +0 -1
- package/dist/cjs/api/types/TaskClientCreate1.d.ts +0 -1
- package/dist/cjs/api/types/TaskClientUpdate1.d.ts +0 -1
- package/dist/cjs/api/types/TaskGroup1.d.ts +1 -0
- package/dist/cjs/api/types/index.d.ts +2 -0
- package/dist/cjs/api/types/index.js +2 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.d.mts +3 -0
- package/dist/esm/Client.mjs +7 -2
- package/dist/esm/api/resources/drivers/client/Client.d.mts +0 -24
- package/dist/esm/api/resources/drivers/client/Client.mjs +0 -73
- package/dist/esm/api/resources/drivers/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/flights/client/Client.d.mts +47 -0
- package/dist/esm/api/resources/flights/client/Client.mjs +90 -0
- package/dist/esm/api/resources/flights/client/index.mjs +1 -0
- package/dist/esm/api/resources/index.d.mts +1 -0
- package/dist/esm/api/resources/index.mjs +1 -0
- package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/Client.d.mts +5 -7
- package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/Client.mjs +8 -10
- package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/taskGroups/client/Client.d.mts +5 -7
- package/dist/esm/api/resources/taskGroups/client/Client.mjs +8 -10
- package/dist/esm/api/resources/taskGroups/client/requests/index.d.mts +0 -1
- package/dist/esm/api/resources/tracking/client/Client.d.mts +3 -3
- package/dist/esm/api/resources/tracking/client/Client.mjs +3 -3
- package/dist/esm/api/resources/tracking/resources/driver/client/Client.d.mts +10 -13
- package/dist/esm/api/resources/tracking/resources/driver/client/Client.mjs +9 -12
- package/dist/esm/api/resources/tracking/resources/driver/client/index.d.mts +0 -1
- package/dist/esm/api/resources/tracking/resources/driver/client/index.mjs +1 -1
- package/dist/esm/api/resources/tracking/resources/index.d.mts +2 -3
- package/dist/esm/api/resources/tracking/resources/index.mjs +2 -3
- package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.d.mts +16 -16
- package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.mjs +15 -15
- package/dist/esm/api/resources/tracking/resources/sharingSettings/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/tracking/resources/sharingSettings/index.d.mts +1 -0
- package/dist/esm/api/resources/tracking/resources/sharingSettings/index.mjs +1 -0
- package/dist/esm/api/resources/tracking/resources/timeseries/resources/cargoByDevice/client/Client.mjs +10 -10
- package/dist/esm/api/resources/tracking/resources/timeseries/resources/cargoByDriver/client/Client.mjs +8 -8
- package/dist/esm/api/resources/tracking/resources/timeseries/resources/sessionByDevice/client/Client.mjs +10 -10
- package/dist/esm/api/resources/tracking/resources/timeseries/resources/taskGroupByDriver/client/Client.mjs +8 -8
- package/dist/esm/api/types/FlightInfoForTaskRes.d.mts +10 -0
- package/dist/esm/api/types/SetFlightInfoReq.d.mts +9 -0
- package/dist/esm/api/types/Task1.d.mts +0 -1
- package/dist/esm/api/types/TaskClientCreate1.d.mts +0 -1
- package/dist/esm/api/types/TaskClientUpdate1.d.mts +0 -1
- package/dist/esm/api/types/TaskGroup1.d.mts +1 -0
- package/dist/esm/api/types/index.d.mts +2 -0
- package/dist/esm/api/types/index.mjs +2 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +97 -115
- package/dist/cjs/api/resources/drivers/client/requests/DriverLastSeenReq.d.ts +0 -23
- package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.d.ts +0 -13
- package/dist/cjs/api/resources/taskGroups/client/requests/SetFlightNumberReq.d.ts +0 -13
- package/dist/cjs/api/resources/taskGroups/client/requests/SetFlightNumberReq.js +0 -5
- package/dist/cjs/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.d.ts +0 -24
- package/dist/cjs/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.js +0 -5
- package/dist/cjs/api/resources/tracking/resources/driver/client/requests/index.d.ts +0 -1
- package/dist/esm/api/resources/drivers/client/requests/DriverLastSeenReq.d.mts +0 -23
- package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.d.mts +0 -13
- package/dist/esm/api/resources/taskGroups/client/requests/SetFlightNumberReq.d.mts +0 -13
- package/dist/esm/api/resources/taskGroups/client/requests/SetFlightNumberReq.mjs +0 -4
- package/dist/esm/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.d.mts +0 -24
- package/dist/esm/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.mjs +0 -4
- package/dist/esm/api/resources/tracking/resources/driver/client/requests/index.d.mts +0 -1
- /package/dist/{esm/api/resources/tracking/resources/driver/client/requests/index.mjs → cjs/api/resources/flights/client/index.d.ts} +0 -0
- /package/dist/cjs/api/resources/{tracking/resources/driver/client/requests → flights/client}/index.js +0 -0
- /package/dist/cjs/api/resources/{tracking/resources/sharing → flights}/index.d.ts +0 -0
- /package/dist/cjs/api/resources/{tracking/resources/sharing → flights}/index.js +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.d.ts +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.js +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.d.ts +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.js +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.d.ts +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.js +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.d.ts +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.js +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/index.d.ts +0 -0
- /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/index.js +0 -0
- /package/dist/cjs/api/{resources/drivers/client/requests/DriverLastSeenReq.js → types/FlightInfoForTaskRes.js} +0 -0
- /package/dist/cjs/api/{resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.js → types/SetFlightInfoReq.js} +0 -0
- /package/dist/esm/api/resources/{tracking/resources/sharing/client/requests/index.mjs → flights/client/index.d.mts} +0 -0
- /package/dist/esm/api/resources/{tracking/resources/sharing → flights}/index.d.mts +0 -0
- /package/dist/esm/api/resources/{tracking/resources/sharing → flights}/index.mjs +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.d.mts +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.mjs +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.d.mts +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.mjs +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.d.mts +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.mjs +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.d.mts +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.mjs +0 -0
- /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/index.d.mts +0 -0
- /package/dist/esm/api/{resources/drivers/client/requests/DriverLastSeenReq.mjs → types/FlightInfoForTaskRes.mjs} +0 -0
- /package/dist/esm/api/{resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.mjs → types/SetFlightInfoReq.mjs} +0 -0
|
@@ -195,28 +195,26 @@ class TaskGroups {
|
|
|
195
195
|
});
|
|
196
196
|
}
|
|
197
197
|
/**
|
|
198
|
-
* Sets the flight number
|
|
198
|
+
* Sets the flight number and/or fa_flight_id on a task group. | authz_personas=[lig_org_operators] | (SetFlightInfoReq) -> (bool)
|
|
199
199
|
*
|
|
200
200
|
* @param {string} taskGroupId
|
|
201
|
-
* @param {Chrt.
|
|
201
|
+
* @param {Chrt.SetFlightInfoReq} request
|
|
202
202
|
* @param {TaskGroups.RequestOptions} requestOptions - Request-specific configuration.
|
|
203
203
|
*
|
|
204
204
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
205
205
|
*
|
|
206
206
|
* @example
|
|
207
|
-
* await client.taskGroups.
|
|
208
|
-
* flight_number: "flight_number"
|
|
209
|
-
* })
|
|
207
|
+
* await client.taskGroups.setFlightInfoV1("task_group_id", {})
|
|
210
208
|
*/
|
|
211
|
-
|
|
212
|
-
return core.HttpResponsePromise.fromPromise(this.
|
|
209
|
+
setFlightInfoV1(taskGroupId, request, requestOptions) {
|
|
210
|
+
return core.HttpResponsePromise.fromPromise(this.__setFlightInfoV1(taskGroupId, request, requestOptions));
|
|
213
211
|
}
|
|
214
|
-
|
|
212
|
+
__setFlightInfoV1(taskGroupId, request, requestOptions) {
|
|
215
213
|
return __awaiter(this, void 0, void 0, function* () {
|
|
216
214
|
var _a, _b, _c, _d;
|
|
217
215
|
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);
|
|
218
216
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
219
|
-
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, `oort/task_groups/
|
|
217
|
+
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, `oort/task_groups/set_flight_info/v1/${encodeURIComponent(taskGroupId)}`),
|
|
220
218
|
method: "PATCH",
|
|
221
219
|
headers: _headers,
|
|
222
220
|
contentType: "application/json",
|
|
@@ -250,7 +248,7 @@ class TaskGroups {
|
|
|
250
248
|
rawResponse: _response.rawResponse,
|
|
251
249
|
});
|
|
252
250
|
case "timeout":
|
|
253
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /oort/task_groups/
|
|
251
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /oort/task_groups/set_flight_info/v1/{task_group_id}.");
|
|
254
252
|
case "unknown":
|
|
255
253
|
throw new errors.ChrtError({
|
|
256
254
|
message: _response.error.errorMessage,
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export { type SetTaskOrderingReq } from "./SetTaskOrderingReq.js";
|
|
2
|
-
export { type SetFlightNumberReq } from "./SetFlightNumberReq.js";
|
|
3
2
|
export { type UpdateDriverReq } from "./UpdateDriverReq.js";
|
|
4
3
|
export { type UpdateCourierOrgReq } from "./UpdateCourierOrgReq.js";
|
|
5
4
|
export { type AddMessageReq } from "./AddMessageReq.js";
|
|
@@ -6,7 +6,7 @@ import * as core from "../../../../core/index.js";
|
|
|
6
6
|
import { Devices } from "../resources/devices/client/Client.js";
|
|
7
7
|
import { Driver } from "../resources/driver/client/Client.js";
|
|
8
8
|
import { Sessions } from "../resources/sessions/client/Client.js";
|
|
9
|
-
import {
|
|
9
|
+
import { SharingSettings } from "../resources/sharingSettings/client/Client.js";
|
|
10
10
|
import { Timeseries } from "../resources/timeseries/client/Client.js";
|
|
11
11
|
export declare namespace Tracking {
|
|
12
12
|
interface Options {
|
|
@@ -24,12 +24,12 @@ export declare class Tracking {
|
|
|
24
24
|
protected _devices: Devices | undefined;
|
|
25
25
|
protected _driver: Driver | undefined;
|
|
26
26
|
protected _sessions: Sessions | undefined;
|
|
27
|
-
protected
|
|
27
|
+
protected _sharingSettings: SharingSettings | undefined;
|
|
28
28
|
protected _timeseries: Timeseries | undefined;
|
|
29
29
|
constructor(_options?: Tracking.Options);
|
|
30
30
|
get devices(): Devices;
|
|
31
31
|
get driver(): Driver;
|
|
32
32
|
get sessions(): Sessions;
|
|
33
|
-
get
|
|
33
|
+
get sharingSettings(): SharingSettings;
|
|
34
34
|
get timeseries(): Timeseries;
|
|
35
35
|
}
|
|
@@ -7,7 +7,7 @@ exports.Tracking = void 0;
|
|
|
7
7
|
const Client_js_1 = require("../resources/devices/client/Client.js");
|
|
8
8
|
const Client_js_2 = require("../resources/driver/client/Client.js");
|
|
9
9
|
const Client_js_3 = require("../resources/sessions/client/Client.js");
|
|
10
|
-
const Client_js_4 = require("../resources/
|
|
10
|
+
const Client_js_4 = require("../resources/sharingSettings/client/Client.js");
|
|
11
11
|
const Client_js_5 = require("../resources/timeseries/client/Client.js");
|
|
12
12
|
class Tracking {
|
|
13
13
|
constructor(_options = {}) {
|
|
@@ -25,9 +25,9 @@ class Tracking {
|
|
|
25
25
|
var _a;
|
|
26
26
|
return ((_a = this._sessions) !== null && _a !== void 0 ? _a : (this._sessions = new Client_js_3.Sessions(this._options)));
|
|
27
27
|
}
|
|
28
|
-
get
|
|
28
|
+
get sharingSettings() {
|
|
29
29
|
var _a;
|
|
30
|
-
return ((_a = this.
|
|
30
|
+
return ((_a = this._sharingSettings) !== null && _a !== void 0 ? _a : (this._sharingSettings = new Client_js_4.SharingSettings(this._options)));
|
|
31
31
|
}
|
|
32
32
|
get timeseries() {
|
|
33
33
|
var _a;
|
|
@@ -31,29 +31,26 @@ export declare class Driver {
|
|
|
31
31
|
protected readonly _options: Driver.Options;
|
|
32
32
|
constructor(_options?: Driver.Options);
|
|
33
33
|
/**
|
|
34
|
-
* Records driver location updates. Automatically
|
|
34
|
+
* Records driver location updates. Updates driver's last seen timestamp and location. Automatically records tracking data for all IN_PROGRESS task groups and their associated IN_TRANSIT cargos. | (LocationFeature) -> (DriverUpdateRes)
|
|
35
35
|
*
|
|
36
|
-
* @param {Chrt.
|
|
36
|
+
* @param {Chrt.LocationFeature} request
|
|
37
37
|
* @param {Driver.RequestOptions} requestOptions - Request-specific configuration.
|
|
38
38
|
*
|
|
39
39
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
40
40
|
*
|
|
41
41
|
* @example
|
|
42
42
|
* await client.tracking.driver.updateV1({
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
* type: "
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
* coordinates: [[]]
|
|
51
|
-
* }]
|
|
52
|
-
* }
|
|
43
|
+
* type: "Feature",
|
|
44
|
+
* geometry: {
|
|
45
|
+
* type: "GeometryCollection",
|
|
46
|
+
* geometries: [{
|
|
47
|
+
* type: "LineString",
|
|
48
|
+
* coordinates: [[]]
|
|
49
|
+
* }]
|
|
53
50
|
* }
|
|
54
51
|
* })
|
|
55
52
|
*/
|
|
56
|
-
updateV1(request: Chrt.
|
|
53
|
+
updateV1(request: Chrt.LocationFeature, requestOptions?: Driver.RequestOptions): core.HttpResponsePromise<Chrt.DriverUpdateRes>;
|
|
57
54
|
private __updateV1;
|
|
58
55
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
59
56
|
}
|
|
@@ -56,25 +56,22 @@ class Driver {
|
|
|
56
56
|
this._options = _options;
|
|
57
57
|
}
|
|
58
58
|
/**
|
|
59
|
-
* Records driver location updates. Automatically
|
|
59
|
+
* Records driver location updates. Updates driver's last seen timestamp and location. Automatically records tracking data for all IN_PROGRESS task groups and their associated IN_TRANSIT cargos. | (LocationFeature) -> (DriverUpdateRes)
|
|
60
60
|
*
|
|
61
|
-
* @param {Chrt.
|
|
61
|
+
* @param {Chrt.LocationFeature} request
|
|
62
62
|
* @param {Driver.RequestOptions} requestOptions - Request-specific configuration.
|
|
63
63
|
*
|
|
64
64
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
65
65
|
*
|
|
66
66
|
* @example
|
|
67
67
|
* await client.tracking.driver.updateV1({
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
* type: "
|
|
71
|
-
*
|
|
72
|
-
*
|
|
73
|
-
*
|
|
74
|
-
*
|
|
75
|
-
* coordinates: [[]]
|
|
76
|
-
* }]
|
|
77
|
-
* }
|
|
68
|
+
* type: "Feature",
|
|
69
|
+
* geometry: {
|
|
70
|
+
* type: "GeometryCollection",
|
|
71
|
+
* geometries: [{
|
|
72
|
+
* type: "LineString",
|
|
73
|
+
* coordinates: [[]]
|
|
74
|
+
* }]
|
|
78
75
|
* }
|
|
79
76
|
* })
|
|
80
77
|
*/
|
|
@@ -1,17 +1,2 @@
|
|
|
1
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
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./requests/index.js"), exports);
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
export * as devices from "./devices/index.js";
|
|
2
2
|
export * as driver from "./driver/index.js";
|
|
3
3
|
export * as sessions from "./sessions/index.js";
|
|
4
|
-
export * as
|
|
4
|
+
export * as sharingSettings from "./sharingSettings/index.js";
|
|
5
5
|
export * as timeseries from "./timeseries/index.js";
|
|
6
6
|
export * from "./devices/client/requests/index.js";
|
|
7
|
-
export * from "./driver/client/requests/index.js";
|
|
8
7
|
export * from "./sessions/client/requests/index.js";
|
|
9
|
-
export * from "./
|
|
8
|
+
export * from "./sharingSettings/client/requests/index.js";
|
|
@@ -36,13 +36,12 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
36
36
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.timeseries = exports.
|
|
39
|
+
exports.timeseries = exports.sharingSettings = exports.sessions = exports.driver = exports.devices = void 0;
|
|
40
40
|
exports.devices = __importStar(require("./devices/index.js"));
|
|
41
41
|
exports.driver = __importStar(require("./driver/index.js"));
|
|
42
42
|
exports.sessions = __importStar(require("./sessions/index.js"));
|
|
43
|
-
exports.
|
|
43
|
+
exports.sharingSettings = __importStar(require("./sharingSettings/index.js"));
|
|
44
44
|
exports.timeseries = __importStar(require("./timeseries/index.js"));
|
|
45
45
|
__exportStar(require("./devices/client/requests/index.js"), exports);
|
|
46
|
-
__exportStar(require("./driver/client/requests/index.js"), exports);
|
|
47
46
|
__exportStar(require("./sessions/client/requests/index.js"), exports);
|
|
48
|
-
__exportStar(require("./
|
|
47
|
+
__exportStar(require("./sharingSettings/client/requests/index.js"), exports);
|
package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.d.ts
RENAMED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
import * as environments from "../../../../../../environments.js";
|
|
5
5
|
import * as core from "../../../../../../core/index.js";
|
|
6
6
|
import * as Chrt from "../../../../../index.js";
|
|
7
|
-
export declare namespace
|
|
7
|
+
export declare namespace SharingSettings {
|
|
8
8
|
interface Options {
|
|
9
9
|
environment?: core.Supplier<environments.ChrtEnvironment | string>;
|
|
10
10
|
/** Specify a custom URL to connect the client to. */
|
|
@@ -27,74 +27,74 @@ export declare namespace Sharing {
|
|
|
27
27
|
headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
|
-
export declare class
|
|
31
|
-
protected readonly _options:
|
|
32
|
-
constructor(_options?:
|
|
30
|
+
export declare class SharingSettings {
|
|
31
|
+
protected readonly _options: SharingSettings.Options;
|
|
32
|
+
constructor(_options?: SharingSettings.Options);
|
|
33
33
|
/**
|
|
34
34
|
* Get all tracking datasets and their sharing settings for a given order. | authz_personas=[shipper_org_operators, forwarder_org_operators, courier_org_operators] | () -> (list[TrackingSharingSettingsRes])
|
|
35
35
|
*
|
|
36
36
|
* @param {string} orderIdOrShortId
|
|
37
|
-
* @param {
|
|
37
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
38
38
|
*
|
|
39
39
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
40
40
|
*
|
|
41
41
|
* @example
|
|
42
|
-
* await client.tracking.
|
|
42
|
+
* await client.tracking.sharingSettings.getSettingsV1("order_id_or_short_id")
|
|
43
43
|
*/
|
|
44
|
-
getSettingsV1(orderIdOrShortId: string, requestOptions?:
|
|
44
|
+
getSettingsV1(orderIdOrShortId: string, requestOptions?: SharingSettings.RequestOptions): core.HttpResponsePromise<Chrt.TrackingSharingSettingsRes[]>;
|
|
45
45
|
private __getSettingsV1;
|
|
46
46
|
/**
|
|
47
47
|
* Updates the sharing settings for a task group by driver tracking dataset. | authz_personas=[forwarder_org_operators, shipper_org_operators, courier_org_operators, courier_driver] | (TaskGroupByDriverSharingSettingsUpdateReq) -> (TaskGroupByDriverSharingSettings1)
|
|
48
48
|
*
|
|
49
49
|
* @param {Chrt.tracking.TaskGroupByDriverSharingSettingsUpdateReq} request
|
|
50
|
-
* @param {
|
|
50
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
51
51
|
*
|
|
52
52
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
53
53
|
*
|
|
54
54
|
* @example
|
|
55
|
-
* await client.tracking.
|
|
55
|
+
* await client.tracking.sharingSettings.taskGroupByDriverSharingSettingsV1({
|
|
56
56
|
* task_group_id: "task_group_id",
|
|
57
57
|
* driver_id: "driver_id",
|
|
58
58
|
* "public": true
|
|
59
59
|
* })
|
|
60
60
|
*/
|
|
61
|
-
taskGroupByDriverSharingSettingsV1(request: Chrt.tracking.TaskGroupByDriverSharingSettingsUpdateReq, requestOptions?:
|
|
61
|
+
taskGroupByDriverSharingSettingsV1(request: Chrt.tracking.TaskGroupByDriverSharingSettingsUpdateReq, requestOptions?: SharingSettings.RequestOptions): core.HttpResponsePromise<Chrt.TaskGroupByDriverSharingSettings1>;
|
|
62
62
|
private __taskGroupByDriverSharingSettingsV1;
|
|
63
63
|
/**
|
|
64
64
|
* Updates the sharing settings for a cargo by driver tracking dataset. | authz_personas=[forwarder_org_operators, shipper_org_operators, courier_org_operators, courier_driver] | (CargoByDriverSharingSettingsUpdateReq) -> (CargoByDriverSharingSettings1)
|
|
65
65
|
*
|
|
66
66
|
* @param {Chrt.tracking.CargoByDriverSharingSettingsUpdateReq} request
|
|
67
|
-
* @param {
|
|
67
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
68
68
|
*
|
|
69
69
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
70
70
|
*
|
|
71
71
|
* @example
|
|
72
|
-
* await client.tracking.
|
|
72
|
+
* await client.tracking.sharingSettings.cargoByDriverSettingsV1({
|
|
73
73
|
* task_group_id: "task_group_id",
|
|
74
74
|
* cargo_id: "cargo_id",
|
|
75
75
|
* driver_id: "driver_id",
|
|
76
76
|
* "public": true
|
|
77
77
|
* })
|
|
78
78
|
*/
|
|
79
|
-
cargoByDriverSettingsV1(request: Chrt.tracking.CargoByDriverSharingSettingsUpdateReq, requestOptions?:
|
|
79
|
+
cargoByDriverSettingsV1(request: Chrt.tracking.CargoByDriverSharingSettingsUpdateReq, requestOptions?: SharingSettings.RequestOptions): core.HttpResponsePromise<Chrt.CargoByDriverSharingSettings1>;
|
|
80
80
|
private __cargoByDriverSettingsV1;
|
|
81
81
|
/**
|
|
82
82
|
* Updates the sharing settings for a cargo by device tracking dataset. | authz_personas=[forwarder_org_operators, shipper_org_operators, order_creator_org_operators] | (CargoByDeviceSharingSettingsUpdateReq) -> (CargoByDeviceSharingSettings1)
|
|
83
83
|
*
|
|
84
84
|
* @param {Chrt.tracking.CargoByDeviceSharingSettingsUpdateReq} request
|
|
85
|
-
* @param {
|
|
85
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
86
86
|
*
|
|
87
87
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
88
88
|
*
|
|
89
89
|
* @example
|
|
90
|
-
* await client.tracking.
|
|
90
|
+
* await client.tracking.sharingSettings.cargoByDeviceSettingsV1({
|
|
91
91
|
* task_group_id: "task_group_id",
|
|
92
92
|
* cargo_id: "cargo_id",
|
|
93
93
|
* device_id: "device_id",
|
|
94
94
|
* "public": true
|
|
95
95
|
* })
|
|
96
96
|
*/
|
|
97
|
-
cargoByDeviceSettingsV1(request: Chrt.tracking.CargoByDeviceSharingSettingsUpdateReq, requestOptions?:
|
|
97
|
+
cargoByDeviceSettingsV1(request: Chrt.tracking.CargoByDeviceSharingSettingsUpdateReq, requestOptions?: SharingSettings.RequestOptions): core.HttpResponsePromise<Chrt.CargoByDeviceSharingSettings1>;
|
|
98
98
|
private __cargoByDeviceSettingsV1;
|
|
99
99
|
protected _getAuthorizationHeader(): Promise<string | undefined>;
|
|
100
100
|
}
|
package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.js
RENAMED
|
@@ -45,13 +45,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
45
45
|
});
|
|
46
46
|
};
|
|
47
47
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
|
-
exports.
|
|
48
|
+
exports.SharingSettings = void 0;
|
|
49
49
|
const environments = __importStar(require("../../../../../../environments.js"));
|
|
50
50
|
const core = __importStar(require("../../../../../../core/index.js"));
|
|
51
51
|
const Chrt = __importStar(require("../../../../../index.js"));
|
|
52
52
|
const headers_js_1 = require("../../../../../../core/headers.js");
|
|
53
53
|
const errors = __importStar(require("../../../../../../errors/index.js"));
|
|
54
|
-
class
|
|
54
|
+
class SharingSettings {
|
|
55
55
|
constructor(_options = {}) {
|
|
56
56
|
this._options = _options;
|
|
57
57
|
}
|
|
@@ -59,12 +59,12 @@ class Sharing {
|
|
|
59
59
|
* Get all tracking datasets and their sharing settings for a given order. | authz_personas=[shipper_org_operators, forwarder_org_operators, courier_org_operators] | () -> (list[TrackingSharingSettingsRes])
|
|
60
60
|
*
|
|
61
61
|
* @param {string} orderIdOrShortId
|
|
62
|
-
* @param {
|
|
62
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
63
63
|
*
|
|
64
64
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
65
65
|
*
|
|
66
66
|
* @example
|
|
67
|
-
* await client.tracking.
|
|
67
|
+
* await client.tracking.sharingSettings.getSettingsV1("order_id_or_short_id")
|
|
68
68
|
*/
|
|
69
69
|
getSettingsV1(orderIdOrShortId, requestOptions) {
|
|
70
70
|
return core.HttpResponsePromise.fromPromise(this.__getSettingsV1(orderIdOrShortId, requestOptions));
|
|
@@ -118,12 +118,12 @@ class Sharing {
|
|
|
118
118
|
* Updates the sharing settings for a task group by driver tracking dataset. | authz_personas=[forwarder_org_operators, shipper_org_operators, courier_org_operators, courier_driver] | (TaskGroupByDriverSharingSettingsUpdateReq) -> (TaskGroupByDriverSharingSettings1)
|
|
119
119
|
*
|
|
120
120
|
* @param {Chrt.tracking.TaskGroupByDriverSharingSettingsUpdateReq} request
|
|
121
|
-
* @param {
|
|
121
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
122
122
|
*
|
|
123
123
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
124
124
|
*
|
|
125
125
|
* @example
|
|
126
|
-
* await client.tracking.
|
|
126
|
+
* await client.tracking.sharingSettings.taskGroupByDriverSharingSettingsV1({
|
|
127
127
|
* task_group_id: "task_group_id",
|
|
128
128
|
* driver_id: "driver_id",
|
|
129
129
|
* "public": true
|
|
@@ -137,7 +137,7 @@ class Sharing {
|
|
|
137
137
|
var _a, _b, _c, _d;
|
|
138
138
|
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);
|
|
139
139
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
140
|
-
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, "tracking/task_group_by_driver/
|
|
140
|
+
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, "tracking/sharing_settings/task_group_by_driver/v1"),
|
|
141
141
|
method: "POST",
|
|
142
142
|
headers: _headers,
|
|
143
143
|
contentType: "application/json",
|
|
@@ -174,7 +174,7 @@ class Sharing {
|
|
|
174
174
|
rawResponse: _response.rawResponse,
|
|
175
175
|
});
|
|
176
176
|
case "timeout":
|
|
177
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/task_group_by_driver/
|
|
177
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/sharing_settings/task_group_by_driver/v1.");
|
|
178
178
|
case "unknown":
|
|
179
179
|
throw new errors.ChrtError({
|
|
180
180
|
message: _response.error.errorMessage,
|
|
@@ -187,12 +187,12 @@ class Sharing {
|
|
|
187
187
|
* Updates the sharing settings for a cargo by driver tracking dataset. | authz_personas=[forwarder_org_operators, shipper_org_operators, courier_org_operators, courier_driver] | (CargoByDriverSharingSettingsUpdateReq) -> (CargoByDriverSharingSettings1)
|
|
188
188
|
*
|
|
189
189
|
* @param {Chrt.tracking.CargoByDriverSharingSettingsUpdateReq} request
|
|
190
|
-
* @param {
|
|
190
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
191
191
|
*
|
|
192
192
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
193
193
|
*
|
|
194
194
|
* @example
|
|
195
|
-
* await client.tracking.
|
|
195
|
+
* await client.tracking.sharingSettings.cargoByDriverSettingsV1({
|
|
196
196
|
* task_group_id: "task_group_id",
|
|
197
197
|
* cargo_id: "cargo_id",
|
|
198
198
|
* driver_id: "driver_id",
|
|
@@ -207,7 +207,7 @@ class Sharing {
|
|
|
207
207
|
var _a, _b, _c, _d;
|
|
208
208
|
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);
|
|
209
209
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
210
|
-
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, "tracking/cargo_by_driver/
|
|
210
|
+
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, "tracking/sharing_settings/cargo_by_driver/v1"),
|
|
211
211
|
method: "POST",
|
|
212
212
|
headers: _headers,
|
|
213
213
|
contentType: "application/json",
|
|
@@ -241,7 +241,7 @@ class Sharing {
|
|
|
241
241
|
rawResponse: _response.rawResponse,
|
|
242
242
|
});
|
|
243
243
|
case "timeout":
|
|
244
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/cargo_by_driver/
|
|
244
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/sharing_settings/cargo_by_driver/v1.");
|
|
245
245
|
case "unknown":
|
|
246
246
|
throw new errors.ChrtError({
|
|
247
247
|
message: _response.error.errorMessage,
|
|
@@ -254,12 +254,12 @@ class Sharing {
|
|
|
254
254
|
* Updates the sharing settings for a cargo by device tracking dataset. | authz_personas=[forwarder_org_operators, shipper_org_operators, order_creator_org_operators] | (CargoByDeviceSharingSettingsUpdateReq) -> (CargoByDeviceSharingSettings1)
|
|
255
255
|
*
|
|
256
256
|
* @param {Chrt.tracking.CargoByDeviceSharingSettingsUpdateReq} request
|
|
257
|
-
* @param {
|
|
257
|
+
* @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
|
|
258
258
|
*
|
|
259
259
|
* @throws {@link Chrt.UnprocessableEntityError}
|
|
260
260
|
*
|
|
261
261
|
* @example
|
|
262
|
-
* await client.tracking.
|
|
262
|
+
* await client.tracking.sharingSettings.cargoByDeviceSettingsV1({
|
|
263
263
|
* task_group_id: "task_group_id",
|
|
264
264
|
* cargo_id: "cargo_id",
|
|
265
265
|
* device_id: "device_id",
|
|
@@ -274,7 +274,7 @@ class Sharing {
|
|
|
274
274
|
var _a, _b, _c, _d;
|
|
275
275
|
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);
|
|
276
276
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
277
|
-
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, "tracking/cargo_by_device/
|
|
277
|
+
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, "tracking/sharing_settings/cargo_by_device/v1"),
|
|
278
278
|
method: "POST",
|
|
279
279
|
headers: _headers,
|
|
280
280
|
contentType: "application/json",
|
|
@@ -308,7 +308,7 @@ class Sharing {
|
|
|
308
308
|
rawResponse: _response.rawResponse,
|
|
309
309
|
});
|
|
310
310
|
case "timeout":
|
|
311
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/cargo_by_device/
|
|
311
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/sharing_settings/cargo_by_device/v1.");
|
|
312
312
|
case "unknown":
|
|
313
313
|
throw new errors.ChrtError({
|
|
314
314
|
message: _response.error.errorMessage,
|
|
@@ -327,4 +327,4 @@ class Sharing {
|
|
|
327
327
|
});
|
|
328
328
|
}
|
|
329
329
|
}
|
|
330
|
-
exports.
|
|
330
|
+
exports.SharingSettings = SharingSettings;
|
|
@@ -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);
|
|
@@ -81,7 +81,7 @@ class CargoByDevice {
|
|
|
81
81
|
_queryParams["task_group_id"] = taskGroupId;
|
|
82
82
|
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);
|
|
83
83
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
84
|
-
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, "tracking/
|
|
84
|
+
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, "tracking/timeseries/cargo_by_device/last_seen/v1"),
|
|
85
85
|
method: "GET",
|
|
86
86
|
headers: _headers,
|
|
87
87
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
@@ -115,7 +115,7 @@ class CargoByDevice {
|
|
|
115
115
|
rawResponse: _response.rawResponse,
|
|
116
116
|
});
|
|
117
117
|
case "timeout":
|
|
118
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/
|
|
118
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/timeseries/cargo_by_device/last_seen/v1.");
|
|
119
119
|
case "unknown":
|
|
120
120
|
throw new errors.ChrtError({
|
|
121
121
|
message: _response.error.errorMessage,
|
|
@@ -154,7 +154,7 @@ class CargoByDevice {
|
|
|
154
154
|
}
|
|
155
155
|
let _headers = (0, headers_js_1.mergeHeaders)((_b = this._options) === null || _b === void 0 ? void 0 : _b.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
156
156
|
const _response = yield ((_c = this._options.fetcher) !== null && _c !== void 0 ? _c : core.fetcher)({
|
|
157
|
-
url: core.url.join((_e = (_d = (yield core.Supplier.get(this._options.baseUrl))) !== null && _d !== void 0 ? _d : (yield core.Supplier.get(this._options.environment))) !== null && _e !== void 0 ? _e : environments.ChrtEnvironment.Local, "tracking/
|
|
157
|
+
url: core.url.join((_e = (_d = (yield core.Supplier.get(this._options.baseUrl))) !== null && _d !== void 0 ? _d : (yield core.Supplier.get(this._options.environment))) !== null && _e !== void 0 ? _e : environments.ChrtEnvironment.Local, "tracking/timeseries/cargo_by_device/data_points/v1"),
|
|
158
158
|
method: "GET",
|
|
159
159
|
headers: _headers,
|
|
160
160
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
@@ -185,7 +185,7 @@ class CargoByDevice {
|
|
|
185
185
|
rawResponse: _response.rawResponse,
|
|
186
186
|
});
|
|
187
187
|
case "timeout":
|
|
188
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/
|
|
188
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/timeseries/cargo_by_device/data_points/v1.");
|
|
189
189
|
case "unknown":
|
|
190
190
|
throw new errors.ChrtError({
|
|
191
191
|
message: _response.error.errorMessage,
|
|
@@ -216,7 +216,7 @@ class CargoByDevice {
|
|
|
216
216
|
var _a, _b, _c, _d;
|
|
217
217
|
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);
|
|
218
218
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
219
|
-
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, "tracking/
|
|
219
|
+
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, "tracking/timeseries/cargo_by_device/outlier/v1"),
|
|
220
220
|
method: "POST",
|
|
221
221
|
headers: _headers,
|
|
222
222
|
contentType: "application/json",
|
|
@@ -253,7 +253,7 @@ class CargoByDevice {
|
|
|
253
253
|
rawResponse: _response.rawResponse,
|
|
254
254
|
});
|
|
255
255
|
case "timeout":
|
|
256
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/
|
|
256
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /tracking/timeseries/cargo_by_device/outlier/v1.");
|
|
257
257
|
case "unknown":
|
|
258
258
|
throw new errors.ChrtError({
|
|
259
259
|
message: _response.error.errorMessage,
|
|
@@ -288,7 +288,7 @@ class CargoByDevice {
|
|
|
288
288
|
_queryParams["task_group_id"] = taskGroupId;
|
|
289
289
|
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);
|
|
290
290
|
const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
|
|
291
|
-
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, "tracking/
|
|
291
|
+
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, "tracking/timeseries/cargo_by_device/last_seen_public/v1"),
|
|
292
292
|
method: "GET",
|
|
293
293
|
headers: _headers,
|
|
294
294
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
@@ -322,7 +322,7 @@ class CargoByDevice {
|
|
|
322
322
|
rawResponse: _response.rawResponse,
|
|
323
323
|
});
|
|
324
324
|
case "timeout":
|
|
325
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/
|
|
325
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/timeseries/cargo_by_device/last_seen_public/v1.");
|
|
326
326
|
case "unknown":
|
|
327
327
|
throw new errors.ChrtError({
|
|
328
328
|
message: _response.error.errorMessage,
|
|
@@ -361,7 +361,7 @@ class CargoByDevice {
|
|
|
361
361
|
}
|
|
362
362
|
let _headers = (0, headers_js_1.mergeHeaders)((_b = this._options) === null || _b === void 0 ? void 0 : _b.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
363
363
|
const _response = yield ((_c = this._options.fetcher) !== null && _c !== void 0 ? _c : core.fetcher)({
|
|
364
|
-
url: core.url.join((_e = (_d = (yield core.Supplier.get(this._options.baseUrl))) !== null && _d !== void 0 ? _d : (yield core.Supplier.get(this._options.environment))) !== null && _e !== void 0 ? _e : environments.ChrtEnvironment.Local, "tracking/
|
|
364
|
+
url: core.url.join((_e = (_d = (yield core.Supplier.get(this._options.baseUrl))) !== null && _d !== void 0 ? _d : (yield core.Supplier.get(this._options.environment))) !== null && _e !== void 0 ? _e : environments.ChrtEnvironment.Local, "tracking/timeseries/cargo_by_device/data_points_public/v1"),
|
|
365
365
|
method: "GET",
|
|
366
366
|
headers: _headers,
|
|
367
367
|
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
@@ -392,7 +392,7 @@ class CargoByDevice {
|
|
|
392
392
|
rawResponse: _response.rawResponse,
|
|
393
393
|
});
|
|
394
394
|
case "timeout":
|
|
395
|
-
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/
|
|
395
|
+
throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /tracking/timeseries/cargo_by_device/data_points_public/v1.");
|
|
396
396
|
case "unknown":
|
|
397
397
|
throw new errors.ChrtError({
|
|
398
398
|
message: _response.error.errorMessage,
|