@chrt-inc/typescript-sdk 1.331.0 → 1.333.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.
Files changed (112) hide show
  1. package/dist/cjs/Client.d.ts +3 -0
  2. package/dist/cjs/Client.js +41 -36
  3. package/dist/cjs/api/resources/flights/client/Client.d.ts +47 -0
  4. package/dist/cjs/api/resources/flights/client/Client.js +127 -0
  5. package/dist/cjs/api/resources/index.d.ts +1 -0
  6. package/dist/cjs/api/resources/index.js +2 -1
  7. package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/Client.d.ts +5 -7
  8. package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/Client.js +8 -10
  9. package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/requests/index.d.ts +0 -1
  10. package/dist/cjs/api/resources/taskGroups/client/Client.d.ts +5 -7
  11. package/dist/cjs/api/resources/taskGroups/client/Client.js +8 -10
  12. package/dist/cjs/api/resources/taskGroups/client/requests/index.d.ts +0 -1
  13. package/dist/cjs/api/resources/tracking/client/Client.d.ts +3 -3
  14. package/dist/cjs/api/resources/tracking/client/Client.js +3 -3
  15. package/dist/cjs/api/resources/tracking/resources/driver/client/Client.d.ts +10 -13
  16. package/dist/cjs/api/resources/tracking/resources/driver/client/Client.js +9 -12
  17. package/dist/cjs/api/resources/tracking/resources/driver/client/index.d.ts +0 -1
  18. package/dist/cjs/api/resources/tracking/resources/driver/client/index.js +0 -15
  19. package/dist/cjs/api/resources/tracking/resources/index.d.ts +2 -3
  20. package/dist/cjs/api/resources/tracking/resources/index.js +3 -4
  21. package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.d.ts +16 -16
  22. package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.js +11 -11
  23. package/dist/cjs/api/resources/tracking/resources/sharingSettings/index.d.ts +1 -0
  24. package/dist/cjs/api/resources/tracking/resources/sharingSettings/index.js +17 -0
  25. package/dist/cjs/api/types/FlightInfoForTaskRes.d.ts +10 -0
  26. package/dist/cjs/api/types/SetFlightInfoReq.d.ts +9 -0
  27. package/dist/cjs/api/types/Task1.d.ts +0 -1
  28. package/dist/cjs/api/types/TaskClientCreate1.d.ts +0 -1
  29. package/dist/cjs/api/types/TaskClientUpdate1.d.ts +0 -1
  30. package/dist/cjs/api/types/TaskGroup1.d.ts +1 -0
  31. package/dist/cjs/api/types/index.d.ts +2 -0
  32. package/dist/cjs/api/types/index.js +2 -0
  33. package/dist/cjs/version.d.ts +1 -1
  34. package/dist/cjs/version.js +1 -1
  35. package/dist/esm/Client.d.mts +3 -0
  36. package/dist/esm/Client.mjs +7 -2
  37. package/dist/esm/api/resources/flights/client/Client.d.mts +47 -0
  38. package/dist/esm/api/resources/flights/client/Client.mjs +90 -0
  39. package/dist/esm/api/resources/flights/client/index.mjs +1 -0
  40. package/dist/esm/api/resources/index.d.mts +1 -0
  41. package/dist/esm/api/resources/index.mjs +1 -0
  42. package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/Client.d.mts +5 -7
  43. package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/Client.mjs +8 -10
  44. package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/requests/index.d.mts +0 -1
  45. package/dist/esm/api/resources/taskGroups/client/Client.d.mts +5 -7
  46. package/dist/esm/api/resources/taskGroups/client/Client.mjs +8 -10
  47. package/dist/esm/api/resources/taskGroups/client/requests/index.d.mts +0 -1
  48. package/dist/esm/api/resources/tracking/client/Client.d.mts +3 -3
  49. package/dist/esm/api/resources/tracking/client/Client.mjs +3 -3
  50. package/dist/esm/api/resources/tracking/resources/driver/client/Client.d.mts +10 -13
  51. package/dist/esm/api/resources/tracking/resources/driver/client/Client.mjs +9 -12
  52. package/dist/esm/api/resources/tracking/resources/driver/client/index.d.mts +0 -1
  53. package/dist/esm/api/resources/tracking/resources/driver/client/index.mjs +1 -1
  54. package/dist/esm/api/resources/tracking/resources/index.d.mts +2 -3
  55. package/dist/esm/api/resources/tracking/resources/index.mjs +2 -3
  56. package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.d.mts +16 -16
  57. package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/Client.mjs +9 -9
  58. package/dist/esm/api/resources/tracking/resources/sharingSettings/client/requests/index.mjs +1 -0
  59. package/dist/esm/api/resources/tracking/resources/sharingSettings/index.d.mts +1 -0
  60. package/dist/esm/api/resources/tracking/resources/sharingSettings/index.mjs +1 -0
  61. package/dist/esm/api/types/FlightInfoForTaskRes.d.mts +10 -0
  62. package/dist/esm/api/types/SetFlightInfoReq.d.mts +9 -0
  63. package/dist/esm/api/types/Task1.d.mts +0 -1
  64. package/dist/esm/api/types/TaskClientCreate1.d.mts +0 -1
  65. package/dist/esm/api/types/TaskClientUpdate1.d.mts +0 -1
  66. package/dist/esm/api/types/TaskGroup1.d.mts +1 -0
  67. package/dist/esm/api/types/index.d.mts +2 -0
  68. package/dist/esm/api/types/index.mjs +2 -0
  69. package/dist/esm/version.d.mts +1 -1
  70. package/dist/esm/version.mjs +1 -1
  71. package/package.json +1 -1
  72. package/reference.md +97 -39
  73. package/dist/cjs/api/resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.d.ts +0 -13
  74. package/dist/cjs/api/resources/taskGroups/client/requests/SetFlightNumberReq.d.ts +0 -13
  75. package/dist/cjs/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.d.ts +0 -24
  76. package/dist/cjs/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.js +0 -5
  77. package/dist/cjs/api/resources/tracking/resources/driver/client/requests/index.d.ts +0 -1
  78. package/dist/esm/api/resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.d.mts +0 -13
  79. package/dist/esm/api/resources/taskGroups/client/requests/SetFlightNumberReq.d.mts +0 -13
  80. package/dist/esm/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.d.mts +0 -24
  81. package/dist/esm/api/resources/tracking/resources/driver/client/requests/DriverUpdateReq.mjs +0 -4
  82. package/dist/esm/api/resources/tracking/resources/driver/client/requests/index.d.mts +0 -1
  83. /package/dist/{esm/api/resources/tracking/resources/driver/client/requests/index.mjs → cjs/api/resources/flights/client/index.d.ts} +0 -0
  84. /package/dist/cjs/api/resources/{tracking/resources/driver/client/requests → flights/client}/index.js +0 -0
  85. /package/dist/cjs/api/resources/{tracking/resources/sharing → flights}/index.d.ts +0 -0
  86. /package/dist/cjs/api/resources/{tracking/resources/sharing → flights}/index.js +0 -0
  87. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.d.ts +0 -0
  88. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.js +0 -0
  89. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.d.ts +0 -0
  90. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.js +0 -0
  91. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.d.ts +0 -0
  92. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.js +0 -0
  93. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.d.ts +0 -0
  94. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.js +0 -0
  95. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/index.d.ts +0 -0
  96. /package/dist/cjs/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/index.js +0 -0
  97. /package/dist/cjs/api/{resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.js → types/FlightInfoForTaskRes.js} +0 -0
  98. /package/dist/cjs/api/{resources/taskGroups/client/requests/SetFlightNumberReq.js → types/SetFlightInfoReq.js} +0 -0
  99. /package/dist/esm/api/resources/{tracking/resources/sharing/client/requests/index.mjs → flights/client/index.d.mts} +0 -0
  100. /package/dist/esm/api/resources/{tracking/resources/sharing → flights}/index.d.mts +0 -0
  101. /package/dist/esm/api/resources/{tracking/resources/sharing → flights}/index.mjs +0 -0
  102. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.d.mts +0 -0
  103. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/index.mjs +0 -0
  104. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.d.mts +0 -0
  105. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDeviceSharingSettingsUpdateReq.mjs +0 -0
  106. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.d.mts +0 -0
  107. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/CargoByDriverSharingSettingsUpdateReq.mjs +0 -0
  108. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.d.mts +0 -0
  109. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/TaskGroupByDriverSharingSettingsUpdateReq.mjs +0 -0
  110. /package/dist/esm/api/resources/tracking/resources/{sharing → sharingSettings}/client/requests/index.d.mts +0 -0
  111. /package/dist/esm/api/{resources/orderDrafts/resources/taskGroup/client/requests/SetFlightNumberDraftReq.mjs → types/FlightInfoForTaskRes.mjs} +0 -0
  112. /package/dist/esm/api/{resources/taskGroups/client/requests/SetFlightNumberReq.mjs → types/SetFlightInfoReq.mjs} +0 -0
@@ -47,21 +47,19 @@ export declare class TaskGroup {
47
47
  addV1(request: Chrt.orderDrafts.OrderDraftAddTaskGroupReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<string>;
48
48
  private __addV1;
49
49
  /**
50
- * Sets the flight number on a draft task group. | (SetFlightNumberDraftReq) -> (bool)
50
+ * Sets the flight number and/or fa_flight_id on a draft task group. | (SetFlightInfoReq) -> (bool)
51
51
  *
52
52
  * @param {string} taskGroupId
53
- * @param {Chrt.orderDrafts.SetFlightNumberDraftReq} request
53
+ * @param {Chrt.SetFlightInfoReq} request
54
54
  * @param {TaskGroup.RequestOptions} requestOptions - Request-specific configuration.
55
55
  *
56
56
  * @throws {@link Chrt.UnprocessableEntityError}
57
57
  *
58
58
  * @example
59
- * await client.orderDrafts.taskGroup.setFlightNumberV1("task_group_id", {
60
- * flight_number: "flight_number"
61
- * })
59
+ * await client.orderDrafts.taskGroup.setFlightInfoV1("task_group_id", {})
62
60
  */
63
- setFlightNumberV1(taskGroupId: string, request: Chrt.orderDrafts.SetFlightNumberDraftReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
64
- private __setFlightNumberV1;
61
+ setFlightInfoV1(taskGroupId: string, request: Chrt.SetFlightInfoReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
62
+ private __setFlightInfoV1;
65
63
  /**
66
64
  * Updates the courier organization assigned to a draft task group. | (UpdateCourierOrgDraftReq) -> (bool)
67
65
  *
@@ -85,28 +85,26 @@ export class TaskGroup {
85
85
  });
86
86
  }
87
87
  /**
88
- * Sets the flight number on a draft task group. | (SetFlightNumberDraftReq) -> (bool)
88
+ * Sets the flight number and/or fa_flight_id on a draft task group. | (SetFlightInfoReq) -> (bool)
89
89
  *
90
90
  * @param {string} taskGroupId
91
- * @param {Chrt.orderDrafts.SetFlightNumberDraftReq} request
91
+ * @param {Chrt.SetFlightInfoReq} request
92
92
  * @param {TaskGroup.RequestOptions} requestOptions - Request-specific configuration.
93
93
  *
94
94
  * @throws {@link Chrt.UnprocessableEntityError}
95
95
  *
96
96
  * @example
97
- * await client.orderDrafts.taskGroup.setFlightNumberV1("task_group_id", {
98
- * flight_number: "flight_number"
99
- * })
97
+ * await client.orderDrafts.taskGroup.setFlightInfoV1("task_group_id", {})
100
98
  */
101
- setFlightNumberV1(taskGroupId, request, requestOptions) {
102
- return core.HttpResponsePromise.fromPromise(this.__setFlightNumberV1(taskGroupId, request, requestOptions));
99
+ setFlightInfoV1(taskGroupId, request, requestOptions) {
100
+ return core.HttpResponsePromise.fromPromise(this.__setFlightInfoV1(taskGroupId, request, requestOptions));
103
101
  }
104
- __setFlightNumberV1(taskGroupId, request, requestOptions) {
102
+ __setFlightInfoV1(taskGroupId, request, requestOptions) {
105
103
  return __awaiter(this, void 0, void 0, function* () {
106
104
  var _a, _b, _c, _d;
107
105
  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);
108
106
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
109
- 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/order_drafts/task_group/set_flight_number/v1/${encodeURIComponent(taskGroupId)}`),
107
+ 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/order_drafts/task_group/set_flight_info/v1/${encodeURIComponent(taskGroupId)}`),
110
108
  method: "PATCH",
111
109
  headers: _headers,
112
110
  contentType: "application/json",
@@ -140,7 +138,7 @@ export class TaskGroup {
140
138
  rawResponse: _response.rawResponse,
141
139
  });
142
140
  case "timeout":
143
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /oort/order_drafts/task_group/set_flight_number/v1/{task_group_id}.");
141
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /oort/order_drafts/task_group/set_flight_info/v1/{task_group_id}.");
144
142
  case "unknown":
145
143
  throw new errors.ChrtError({
146
144
  message: _response.error.errorMessage,
@@ -1,4 +1,3 @@
1
1
  export { type OrderDraftAddTaskGroupReq } from "./OrderDraftAddTaskGroupReq.mjs";
2
- export { type SetFlightNumberDraftReq } from "./SetFlightNumberDraftReq.mjs";
3
2
  export { type UpdateCourierOrgDraftReq } from "./UpdateCourierOrgDraftReq.mjs";
4
3
  export { type SetTaskOrderingDraftReq } from "./SetTaskOrderingDraftReq.mjs";
@@ -69,21 +69,19 @@ export declare class TaskGroups {
69
69
  setTaskOrderingV1(taskGroupId: string, request: Chrt.SetTaskOrderingReq, requestOptions?: TaskGroups.RequestOptions): core.HttpResponsePromise<boolean>;
70
70
  private __setTaskOrderingV1;
71
71
  /**
72
- * Sets the flight number on a task group, plus any TENDER_TO_AIRLINE tasks in the immediately preceding task group and RECOVER_FROM_AIRLINE tasks in the immediately following task group. | authz_personas=[lig_org_operators] | (SetFlightNumberReq) -> (bool)
72
+ * Sets the flight number and/or fa_flight_id on a task group. | authz_personas=[lig_org_operators] | (SetFlightInfoReq) -> (bool)
73
73
  *
74
74
  * @param {string} taskGroupId
75
- * @param {Chrt.SetFlightNumberReq} request
75
+ * @param {Chrt.SetFlightInfoReq} request
76
76
  * @param {TaskGroups.RequestOptions} requestOptions - Request-specific configuration.
77
77
  *
78
78
  * @throws {@link Chrt.UnprocessableEntityError}
79
79
  *
80
80
  * @example
81
- * await client.taskGroups.setFlightNumberV1("task_group_id", {
82
- * flight_number: "flight_number"
83
- * })
81
+ * await client.taskGroups.setFlightInfoV1("task_group_id", {})
84
82
  */
85
- setFlightNumberV1(taskGroupId: string, request: Chrt.SetFlightNumberReq, requestOptions?: TaskGroups.RequestOptions): core.HttpResponsePromise<boolean>;
86
- private __setFlightNumberV1;
83
+ setFlightInfoV1(taskGroupId: string, request: Chrt.SetFlightInfoReq, requestOptions?: TaskGroups.RequestOptions): core.HttpResponsePromise<boolean>;
84
+ private __setFlightInfoV1;
87
85
  /**
88
86
  * Updates the driver assigned to a task group. | authz_personas=[courier_org_operators] | (UpdateDriverReq) -> (bool)
89
87
  *
@@ -159,28 +159,26 @@ export class TaskGroups {
159
159
  });
160
160
  }
161
161
  /**
162
- * Sets the flight number on a task group, plus any TENDER_TO_AIRLINE tasks in the immediately preceding task group and RECOVER_FROM_AIRLINE tasks in the immediately following task group. | authz_personas=[lig_org_operators] | (SetFlightNumberReq) -> (bool)
162
+ * Sets the flight number and/or fa_flight_id on a task group. | authz_personas=[lig_org_operators] | (SetFlightInfoReq) -> (bool)
163
163
  *
164
164
  * @param {string} taskGroupId
165
- * @param {Chrt.SetFlightNumberReq} request
165
+ * @param {Chrt.SetFlightInfoReq} request
166
166
  * @param {TaskGroups.RequestOptions} requestOptions - Request-specific configuration.
167
167
  *
168
168
  * @throws {@link Chrt.UnprocessableEntityError}
169
169
  *
170
170
  * @example
171
- * await client.taskGroups.setFlightNumberV1("task_group_id", {
172
- * flight_number: "flight_number"
173
- * })
171
+ * await client.taskGroups.setFlightInfoV1("task_group_id", {})
174
172
  */
175
- setFlightNumberV1(taskGroupId, request, requestOptions) {
176
- return core.HttpResponsePromise.fromPromise(this.__setFlightNumberV1(taskGroupId, request, requestOptions));
173
+ setFlightInfoV1(taskGroupId, request, requestOptions) {
174
+ return core.HttpResponsePromise.fromPromise(this.__setFlightInfoV1(taskGroupId, request, requestOptions));
177
175
  }
178
- __setFlightNumberV1(taskGroupId, request, requestOptions) {
176
+ __setFlightInfoV1(taskGroupId, request, requestOptions) {
179
177
  return __awaiter(this, void 0, void 0, function* () {
180
178
  var _a, _b, _c, _d;
181
179
  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);
182
180
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
183
- 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_number/v1/${encodeURIComponent(taskGroupId)}`),
181
+ 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)}`),
184
182
  method: "PATCH",
185
183
  headers: _headers,
186
184
  contentType: "application/json",
@@ -214,7 +212,7 @@ export class TaskGroups {
214
212
  rawResponse: _response.rawResponse,
215
213
  });
216
214
  case "timeout":
217
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /oort/task_groups/set_flight_number/v1/{task_group_id}.");
215
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /oort/task_groups/set_flight_info/v1/{task_group_id}.");
218
216
  case "unknown":
219
217
  throw new errors.ChrtError({
220
218
  message: _response.error.errorMessage,
@@ -1,5 +1,4 @@
1
1
  export { type SetTaskOrderingReq } from "./SetTaskOrderingReq.mjs";
2
- export { type SetFlightNumberReq } from "./SetFlightNumberReq.mjs";
3
2
  export { type UpdateDriverReq } from "./UpdateDriverReq.mjs";
4
3
  export { type UpdateCourierOrgReq } from "./UpdateCourierOrgReq.mjs";
5
4
  export { type AddMessageReq } from "./AddMessageReq.mjs";
@@ -6,7 +6,7 @@ import * as core from "../../../../core/index.mjs";
6
6
  import { Devices } from "../resources/devices/client/Client.mjs";
7
7
  import { Driver } from "../resources/driver/client/Client.mjs";
8
8
  import { Sessions } from "../resources/sessions/client/Client.mjs";
9
- import { Sharing } from "../resources/sharing/client/Client.mjs";
9
+ import { SharingSettings } from "../resources/sharingSettings/client/Client.mjs";
10
10
  import { Timeseries } from "../resources/timeseries/client/Client.mjs";
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 _sharing: Sharing | undefined;
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 sharing(): Sharing;
33
+ get sharingSettings(): SharingSettings;
34
34
  get timeseries(): Timeseries;
35
35
  }
@@ -4,7 +4,7 @@
4
4
  import { Devices } from "../resources/devices/client/Client.mjs";
5
5
  import { Driver } from "../resources/driver/client/Client.mjs";
6
6
  import { Sessions } from "../resources/sessions/client/Client.mjs";
7
- import { Sharing } from "../resources/sharing/client/Client.mjs";
7
+ import { SharingSettings } from "../resources/sharingSettings/client/Client.mjs";
8
8
  import { Timeseries } from "../resources/timeseries/client/Client.mjs";
9
9
  export class Tracking {
10
10
  constructor(_options = {}) {
@@ -22,9 +22,9 @@ export class Tracking {
22
22
  var _a;
23
23
  return ((_a = this._sessions) !== null && _a !== void 0 ? _a : (this._sessions = new Sessions(this._options)));
24
24
  }
25
- get sharing() {
25
+ get sharingSettings() {
26
26
  var _a;
27
- return ((_a = this._sharing) !== null && _a !== void 0 ? _a : (this._sharing = new Sharing(this._options)));
27
+ return ((_a = this._sharingSettings) !== null && _a !== void 0 ? _a : (this._sharingSettings = new SharingSettings(this._options)));
28
28
  }
29
29
  get timeseries() {
30
30
  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 writes to all IN_PROGRESS task groups and their associated cargos. Updates driver's last seen timestamp and location. | (DriverUpdateReq) -> (DriverUpdateRes)
34
+ * Records driver location updates. Automatically writes to all IN_PROGRESS task groups and their associated IN_TRANSIT cargos. Updates driver's last seen timestamp and location. | (DriverUpdateReq) -> (DriverUpdateRes)
35
35
  *
36
- * @param {Chrt.tracking.DriverUpdateReq} request
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
- * timestamp: "2024-01-15T09:30:00Z",
44
- * location: {
45
- * type: "Feature",
46
- * geometry: {
47
- * type: "GeometryCollection",
48
- * geometries: [{
49
- * type: "LineString",
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.tracking.DriverUpdateReq, requestOptions?: Driver.RequestOptions): core.HttpResponsePromise<Chrt.DriverUpdateRes>;
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
  }
@@ -20,25 +20,22 @@ export class Driver {
20
20
  this._options = _options;
21
21
  }
22
22
  /**
23
- * Records driver location updates. Automatically writes to all IN_PROGRESS task groups and their associated cargos. Updates driver's last seen timestamp and location. | (DriverUpdateReq) -> (DriverUpdateRes)
23
+ * Records driver location updates. Automatically writes to all IN_PROGRESS task groups and their associated IN_TRANSIT cargos. Updates driver's last seen timestamp and location. | (DriverUpdateReq) -> (DriverUpdateRes)
24
24
  *
25
- * @param {Chrt.tracking.DriverUpdateReq} request
25
+ * @param {Chrt.LocationFeature} request
26
26
  * @param {Driver.RequestOptions} requestOptions - Request-specific configuration.
27
27
  *
28
28
  * @throws {@link Chrt.UnprocessableEntityError}
29
29
  *
30
30
  * @example
31
31
  * await client.tracking.driver.updateV1({
32
- * timestamp: "2024-01-15T09:30:00Z",
33
- * location: {
34
- * type: "Feature",
35
- * geometry: {
36
- * type: "GeometryCollection",
37
- * geometries: [{
38
- * type: "LineString",
39
- * coordinates: [[]]
40
- * }]
41
- * }
32
+ * type: "Feature",
33
+ * geometry: {
34
+ * type: "GeometryCollection",
35
+ * geometries: [{
36
+ * type: "LineString",
37
+ * coordinates: [[]]
38
+ * }]
42
39
  * }
43
40
  * })
44
41
  */
@@ -1,2 +1 @@
1
1
  export {};
2
- export * from "./requests/index.mjs";
@@ -1 +1 @@
1
- export * from "./requests/index.mjs";
1
+ export {};
@@ -1,9 +1,8 @@
1
1
  export * as devices from "./devices/index.mjs";
2
2
  export * as driver from "./driver/index.mjs";
3
3
  export * as sessions from "./sessions/index.mjs";
4
- export * as sharing from "./sharing/index.mjs";
4
+ export * as sharingSettings from "./sharingSettings/index.mjs";
5
5
  export * as timeseries from "./timeseries/index.mjs";
6
6
  export * from "./devices/client/requests/index.mjs";
7
- export * from "./driver/client/requests/index.mjs";
8
7
  export * from "./sessions/client/requests/index.mjs";
9
- export * from "./sharing/client/requests/index.mjs";
8
+ export * from "./sharingSettings/client/requests/index.mjs";
@@ -1,9 +1,8 @@
1
1
  export * as devices from "./devices/index.mjs";
2
2
  export * as driver from "./driver/index.mjs";
3
3
  export * as sessions from "./sessions/index.mjs";
4
- export * as sharing from "./sharing/index.mjs";
4
+ export * as sharingSettings from "./sharingSettings/index.mjs";
5
5
  export * as timeseries from "./timeseries/index.mjs";
6
6
  export * from "./devices/client/requests/index.mjs";
7
- export * from "./driver/client/requests/index.mjs";
8
7
  export * from "./sessions/client/requests/index.mjs";
9
- export * from "./sharing/client/requests/index.mjs";
8
+ export * from "./sharingSettings/client/requests/index.mjs";
@@ -4,7 +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
- export declare namespace Sharing {
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 Sharing {
31
- protected readonly _options: Sharing.Options;
32
- constructor(_options?: Sharing.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 {Sharing.RequestOptions} requestOptions - Request-specific configuration.
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.sharing.getSettingsV1("order_id_or_short_id")
42
+ * await client.tracking.sharingSettings.getSettingsV1("order_id_or_short_id")
43
43
  */
44
- getSettingsV1(orderIdOrShortId: string, requestOptions?: Sharing.RequestOptions): core.HttpResponsePromise<Chrt.TrackingSharingSettingsRes[]>;
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 {Sharing.RequestOptions} requestOptions - Request-specific configuration.
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.sharing.taskGroupByDriverSharingSettingsV1({
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?: Sharing.RequestOptions): core.HttpResponsePromise<Chrt.TaskGroupByDriverSharingSettings1>;
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 {Sharing.RequestOptions} requestOptions - Request-specific configuration.
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.sharing.cargoByDriverSettingsV1({
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?: Sharing.RequestOptions): core.HttpResponsePromise<Chrt.CargoByDriverSharingSettings1>;
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 {Sharing.RequestOptions} requestOptions - Request-specific configuration.
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.sharing.cargoByDeviceSettingsV1({
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?: Sharing.RequestOptions): core.HttpResponsePromise<Chrt.CargoByDeviceSharingSettings1>;
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
  }
@@ -15,7 +15,7 @@ import * as core from "../../../../../../core/index.mjs";
15
15
  import * as Chrt from "../../../../../index.mjs";
16
16
  import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../core/headers.mjs";
17
17
  import * as errors from "../../../../../../errors/index.mjs";
18
- export class Sharing {
18
+ export class SharingSettings {
19
19
  constructor(_options = {}) {
20
20
  this._options = _options;
21
21
  }
@@ -23,12 +23,12 @@ export class Sharing {
23
23
  * 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])
24
24
  *
25
25
  * @param {string} orderIdOrShortId
26
- * @param {Sharing.RequestOptions} requestOptions - Request-specific configuration.
26
+ * @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
27
27
  *
28
28
  * @throws {@link Chrt.UnprocessableEntityError}
29
29
  *
30
30
  * @example
31
- * await client.tracking.sharing.getSettingsV1("order_id_or_short_id")
31
+ * await client.tracking.sharingSettings.getSettingsV1("order_id_or_short_id")
32
32
  */
33
33
  getSettingsV1(orderIdOrShortId, requestOptions) {
34
34
  return core.HttpResponsePromise.fromPromise(this.__getSettingsV1(orderIdOrShortId, requestOptions));
@@ -82,12 +82,12 @@ export class Sharing {
82
82
  * 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)
83
83
  *
84
84
  * @param {Chrt.tracking.TaskGroupByDriverSharingSettingsUpdateReq} request
85
- * @param {Sharing.RequestOptions} requestOptions - Request-specific configuration.
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.sharing.taskGroupByDriverSharingSettingsV1({
90
+ * await client.tracking.sharingSettings.taskGroupByDriverSharingSettingsV1({
91
91
  * task_group_id: "task_group_id",
92
92
  * driver_id: "driver_id",
93
93
  * "public": true
@@ -151,12 +151,12 @@ export class Sharing {
151
151
  * 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)
152
152
  *
153
153
  * @param {Chrt.tracking.CargoByDriverSharingSettingsUpdateReq} request
154
- * @param {Sharing.RequestOptions} requestOptions - Request-specific configuration.
154
+ * @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
155
155
  *
156
156
  * @throws {@link Chrt.UnprocessableEntityError}
157
157
  *
158
158
  * @example
159
- * await client.tracking.sharing.cargoByDriverSettingsV1({
159
+ * await client.tracking.sharingSettings.cargoByDriverSettingsV1({
160
160
  * task_group_id: "task_group_id",
161
161
  * cargo_id: "cargo_id",
162
162
  * driver_id: "driver_id",
@@ -218,12 +218,12 @@ export class Sharing {
218
218
  * 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)
219
219
  *
220
220
  * @param {Chrt.tracking.CargoByDeviceSharingSettingsUpdateReq} request
221
- * @param {Sharing.RequestOptions} requestOptions - Request-specific configuration.
221
+ * @param {SharingSettings.RequestOptions} requestOptions - Request-specific configuration.
222
222
  *
223
223
  * @throws {@link Chrt.UnprocessableEntityError}
224
224
  *
225
225
  * @example
226
- * await client.tracking.sharing.cargoByDeviceSettingsV1({
226
+ * await client.tracking.sharingSettings.cargoByDeviceSettingsV1({
227
227
  * task_group_id: "task_group_id",
228
228
  * cargo_id: "cargo_id",
229
229
  * device_id: "device_id",
@@ -0,0 +1 @@
1
+ export * from "./client/index.mjs";
@@ -0,0 +1 @@
1
+ export * from "./client/index.mjs";
@@ -0,0 +1,10 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * Response model for flight info lookup by task.
6
+ */
7
+ export interface FlightInfoForTaskRes {
8
+ flight_number?: string | null;
9
+ fa_flight_id?: string | null;
10
+ }
@@ -0,0 +1,9 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export interface SetFlightInfoReq {
5
+ /** Flight number to set on the task group */
6
+ flight_number?: string | null;
7
+ /** Flight Aware's uuid for flights */
8
+ fa_flight_id?: string | null;
9
+ }
@@ -9,7 +9,6 @@ export interface Task1 {
9
9
  time_windows?: Chrt.TimeWindow1[];
10
10
  order_placer_comments?: string | null;
11
11
  shipper_contact_ids?: string[];
12
- flight_number?: string | null;
13
12
  _id: string;
14
13
  order_id: string;
15
14
  order_short_id: string;
@@ -9,7 +9,6 @@ export interface TaskClientCreate1 {
9
9
  time_windows?: Chrt.TimeWindow1[];
10
10
  order_placer_comments?: string | null;
11
11
  shipper_contact_ids?: string[];
12
- flight_number?: string | null;
13
12
  }
14
13
  export declare namespace TaskClientCreate1 {
15
14
  type Action = Chrt.ChrtGroundCourierTaskActionEnum1 | Chrt.FlightTaskActionEnum1 | Chrt.OnboardCourierTaskActionEnum1;
@@ -7,7 +7,6 @@ export interface TaskClientUpdate1 {
7
7
  action?: TaskClientUpdate1.Action | null;
8
8
  time_windows?: Chrt.TimeWindow1[];
9
9
  shipper_contact_ids?: string[];
10
- flight_number?: string | null;
11
10
  }
12
11
  export declare namespace TaskClientUpdate1 {
13
12
  type Action = Chrt.ChrtGroundCourierTaskActionEnum1 | Chrt.FlightTaskActionEnum1 | Chrt.OnboardCourierTaskActionEnum1;
@@ -27,5 +27,6 @@ export interface TaskGroup1 {
27
27
  task_group_type: Chrt.TaskGroupTypeEnum1;
28
28
  task_group_mileage?: Chrt.TaskGroupMileage1 | null;
29
29
  flight_number?: string | null;
30
+ fa_flight_id?: string | null;
30
31
  messages?: Chrt.TaskGroupMessage1[];
31
32
  }
@@ -37,6 +37,7 @@ export * from "./Driver1.mjs";
37
37
  export * from "./DriverStatusEnum.mjs";
38
38
  export * from "./DriverUpdateAvailabilityReq.mjs";
39
39
  export * from "./DriverUpdateRes.mjs";
40
+ export * from "./FlightInfoForTaskRes.mjs";
40
41
  export * from "./FlightTaskActionEnum1.mjs";
41
42
  export * from "./ForwarderConnectionRes.mjs";
42
43
  export * from "./ForwarderCourierConnection1.mjs";
@@ -92,6 +93,7 @@ export * from "./SessionByDeviceDataPoint1.mjs";
92
93
  export * from "./SessionByDeviceDataPointMetadata1.mjs";
93
94
  export * from "./SessionByDeviceMarkOutliersResponse1.mjs";
94
95
  export * from "./SessionDeleteResponse1.mjs";
96
+ export * from "./SetFlightInfoReq.mjs";
95
97
  export * from "./ShipperConnectionRes.mjs";
96
98
  export * from "./ShipperContact1.mjs";
97
99
  export * from "./ShipperContactClientCreate1.mjs";
@@ -37,6 +37,7 @@ export * from "./Driver1.mjs";
37
37
  export * from "./DriverStatusEnum.mjs";
38
38
  export * from "./DriverUpdateAvailabilityReq.mjs";
39
39
  export * from "./DriverUpdateRes.mjs";
40
+ export * from "./FlightInfoForTaskRes.mjs";
40
41
  export * from "./FlightTaskActionEnum1.mjs";
41
42
  export * from "./ForwarderConnectionRes.mjs";
42
43
  export * from "./ForwarderCourierConnection1.mjs";
@@ -92,6 +93,7 @@ export * from "./SessionByDeviceDataPoint1.mjs";
92
93
  export * from "./SessionByDeviceDataPointMetadata1.mjs";
93
94
  export * from "./SessionByDeviceMarkOutliersResponse1.mjs";
94
95
  export * from "./SessionDeleteResponse1.mjs";
96
+ export * from "./SetFlightInfoReq.mjs";
95
97
  export * from "./ShipperConnectionRes.mjs";
96
98
  export * from "./ShipperContact1.mjs";
97
99
  export * from "./ShipperContactClientCreate1.mjs";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.331.0";
1
+ export declare const SDK_VERSION = "1.333.0";
@@ -1 +1 @@
1
- export const SDK_VERSION = "1.331.0";
1
+ export const SDK_VERSION = "1.333.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chrt-inc/typescript-sdk",
3
- "version": "1.331.0",
3
+ "version": "1.333.0",
4
4
  "private": false,
5
5
  "repository": "github:chrt-inc/typescript-sdk",
6
6
  "type": "commonjs",