@chrt-inc/typescript-sdk 1.967.0 → 1.972.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 (86) hide show
  1. package/dist/cjs/Client.js +2 -2
  2. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.ts +20 -4
  3. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.js +72 -7
  4. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemClientUpdate1.d.ts +2 -2
  5. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemsCurrencyConversionUpdateManyReq.d.ts +18 -0
  6. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemsCurrencyConversionUpdateManyReq.js +5 -0
  7. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/index.d.ts +1 -0
  8. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/Client.d.ts +1 -1
  9. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/Client.js +1 -1
  10. package/dist/cjs/api/resources/shipping/resources/orderTemplatesNew/resources/tasks/client/requests/OrderTemplateNewTaskClientCreate1.d.ts +1 -0
  11. package/dist/cjs/api/resources/shipping/resources/orders/client/Client.d.ts +13 -0
  12. package/dist/cjs/api/resources/shipping/resources/orders/client/Client.js +59 -0
  13. package/dist/cjs/api/resources/shipping/resources/orders/resources/cargo/client/Client.d.ts +1 -1
  14. package/dist/cjs/api/resources/shipping/resources/orders/resources/cargo/client/Client.js +1 -1
  15. package/dist/cjs/api/resources/shipping/resources/orders/resources/expanded/client/Client.d.ts +1 -0
  16. package/dist/cjs/api/resources/shipping/resources/orders/resources/expanded/client/Client.js +5 -1
  17. package/dist/cjs/api/resources/shipping/resources/orders/resources/expanded/client/requests/ExpandedListForProviderOperatorsV1Request.d.ts +3 -0
  18. package/dist/cjs/api/resources/shipping/resources/orders/resources/task/client/Client.d.ts +1 -1
  19. package/dist/cjs/api/resources/shipping/resources/orders/resources/task/client/Client.js +1 -1
  20. package/dist/cjs/api/resources/shipping/resources/orders/resources/taskGroup/client/Client.d.ts +5 -5
  21. package/dist/cjs/api/resources/shipping/resources/orders/resources/taskGroup/client/Client.js +5 -5
  22. package/dist/cjs/api/types/DepartmentTypeEnum.d.ts +2 -1
  23. package/dist/cjs/api/types/DepartmentTypeEnum.js +1 -0
  24. package/dist/cjs/api/types/InvoiceExportListItem.d.ts +1 -1
  25. package/dist/cjs/api/types/InvoiceLineItem1.d.ts +1 -0
  26. package/dist/cjs/api/types/InvoiceLineItemCurrencyConversion1.d.ts +11 -0
  27. package/dist/cjs/api/types/InvoiceLineItemCurrencyConversion1.js +5 -0
  28. package/dist/cjs/api/types/InvoiceLineItemServerCreate1.d.ts +1 -0
  29. package/dist/cjs/api/types/OrderAndTaskGroupExpandedReq.d.ts +2 -0
  30. package/dist/cjs/api/types/OrderExpandedForProvider.d.ts +1 -0
  31. package/dist/cjs/api/types/OrderTemplateNewTask1.d.ts +1 -0
  32. package/dist/cjs/api/types/ShippingIntegrationOrderExpanded1.d.ts +3 -1
  33. package/dist/cjs/api/types/ShippingIntegrationOrderStatusTimestampProvenanceEnum1.d.ts +8 -0
  34. package/dist/cjs/api/types/{ShippingIntegrationOrderCompletedAtProvenanceEnum1.js → ShippingIntegrationOrderStatusTimestampProvenanceEnum1.js} +2 -2
  35. package/dist/cjs/api/types/Task1.d.ts +1 -0
  36. package/dist/cjs/api/types/TaskClientCreate1.d.ts +1 -0
  37. package/dist/cjs/api/types/TaskGroupExpanded.d.ts +1 -0
  38. package/dist/cjs/api/types/index.d.ts +2 -1
  39. package/dist/cjs/api/types/index.js +2 -1
  40. package/dist/cjs/version.d.ts +1 -1
  41. package/dist/cjs/version.js +1 -1
  42. package/dist/esm/Client.mjs +2 -2
  43. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.mts +20 -4
  44. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.mjs +72 -7
  45. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemClientUpdate1.d.mts +2 -2
  46. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemsCurrencyConversionUpdateManyReq.d.mts +18 -0
  47. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemsCurrencyConversionUpdateManyReq.mjs +4 -0
  48. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/index.d.mts +1 -0
  49. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/Client.d.mts +1 -1
  50. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/Client.mjs +1 -1
  51. package/dist/esm/api/resources/shipping/resources/orderTemplatesNew/resources/tasks/client/requests/OrderTemplateNewTaskClientCreate1.d.mts +1 -0
  52. package/dist/esm/api/resources/shipping/resources/orders/client/Client.d.mts +13 -0
  53. package/dist/esm/api/resources/shipping/resources/orders/client/Client.mjs +59 -0
  54. package/dist/esm/api/resources/shipping/resources/orders/resources/cargo/client/Client.d.mts +1 -1
  55. package/dist/esm/api/resources/shipping/resources/orders/resources/cargo/client/Client.mjs +1 -1
  56. package/dist/esm/api/resources/shipping/resources/orders/resources/expanded/client/Client.d.mts +1 -0
  57. package/dist/esm/api/resources/shipping/resources/orders/resources/expanded/client/Client.mjs +5 -1
  58. package/dist/esm/api/resources/shipping/resources/orders/resources/expanded/client/requests/ExpandedListForProviderOperatorsV1Request.d.mts +3 -0
  59. package/dist/esm/api/resources/shipping/resources/orders/resources/task/client/Client.d.mts +1 -1
  60. package/dist/esm/api/resources/shipping/resources/orders/resources/task/client/Client.mjs +1 -1
  61. package/dist/esm/api/resources/shipping/resources/orders/resources/taskGroup/client/Client.d.mts +5 -5
  62. package/dist/esm/api/resources/shipping/resources/orders/resources/taskGroup/client/Client.mjs +5 -5
  63. package/dist/esm/api/types/DepartmentTypeEnum.d.mts +2 -1
  64. package/dist/esm/api/types/DepartmentTypeEnum.mjs +1 -0
  65. package/dist/esm/api/types/InvoiceExportListItem.d.mts +1 -1
  66. package/dist/esm/api/types/InvoiceLineItem1.d.mts +1 -0
  67. package/dist/esm/api/types/InvoiceLineItemCurrencyConversion1.d.mts +11 -0
  68. package/dist/esm/api/types/InvoiceLineItemCurrencyConversion1.mjs +4 -0
  69. package/dist/esm/api/types/InvoiceLineItemServerCreate1.d.mts +1 -0
  70. package/dist/esm/api/types/OrderAndTaskGroupExpandedReq.d.mts +2 -0
  71. package/dist/esm/api/types/OrderExpandedForProvider.d.mts +1 -0
  72. package/dist/esm/api/types/OrderTemplateNewTask1.d.mts +1 -0
  73. package/dist/esm/api/types/ShippingIntegrationOrderExpanded1.d.mts +3 -1
  74. package/dist/esm/api/types/ShippingIntegrationOrderStatusTimestampProvenanceEnum1.d.mts +8 -0
  75. package/dist/esm/api/types/{ShippingIntegrationOrderCompletedAtProvenanceEnum1.mjs → ShippingIntegrationOrderStatusTimestampProvenanceEnum1.mjs} +1 -1
  76. package/dist/esm/api/types/Task1.d.mts +1 -0
  77. package/dist/esm/api/types/TaskClientCreate1.d.mts +1 -0
  78. package/dist/esm/api/types/TaskGroupExpanded.d.mts +1 -0
  79. package/dist/esm/api/types/index.d.mts +2 -1
  80. package/dist/esm/api/types/index.mjs +2 -1
  81. package/dist/esm/version.d.mts +1 -1
  82. package/dist/esm/version.mjs +1 -1
  83. package/package.json +1 -1
  84. package/reference.md +141 -11
  85. package/dist/cjs/api/types/ShippingIntegrationOrderCompletedAtProvenanceEnum1.d.ts +0 -8
  86. package/dist/esm/api/types/ShippingIntegrationOrderCompletedAtProvenanceEnum1.d.mts +0 -8
@@ -60,8 +60,8 @@ class ChrtClient {
60
60
  this._options = Object.assign(Object.assign({}, _options), { headers: (0, headers_js_1.mergeHeaders)({
61
61
  "X-Fern-Language": "JavaScript",
62
62
  "X-Fern-SDK-Name": "@chrt-inc/typescript-sdk",
63
- "X-Fern-SDK-Version": "1.967.0",
64
- "User-Agent": "@chrt-inc/typescript-sdk/1.967.0",
63
+ "X-Fern-SDK-Version": "1.972.0",
64
+ "User-Agent": "@chrt-inc/typescript-sdk/1.972.0",
65
65
  "X-Fern-Runtime": core.RUNTIME.type,
66
66
  "X-Fern-Runtime-Version": core.RUNTIME.version,
67
67
  }, _options === null || _options === void 0 ? void 0 : _options.headers) });
@@ -285,7 +285,23 @@ export declare class InvoiceLineItems {
285
285
  recalculateTaxesV1(request: Chrt.billingNew.RecalculateOrderTaxInvoiceLineItemsReq, requestOptions?: InvoiceLineItems.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItem1[]>;
286
286
  private __recalculateTaxesV1;
287
287
  /**
288
- * Updates an owner-scoped line item and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (bool)
288
+ * Applies or reverts one currency conversion on line items from their original source values and moves attached items to the matching target-currency draft invoice. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemsCurrencyConversionUpdateManyReq) -> (list[InvoiceLineItem1])
289
+ *
290
+ * @param {Chrt.billingNew.InvoiceLineItemsCurrencyConversionUpdateManyReq} request
291
+ * @param {InvoiceLineItems.RequestOptions} requestOptions - Request-specific configuration.
292
+ *
293
+ * @throws {@link Chrt.UnprocessableEntityError}
294
+ *
295
+ * @example
296
+ * await client.billingNew.invoiceLineItems.updateCurrencyConversionManyV1({
297
+ * invoice_line_item_ids: ["invoice_line_item_ids"],
298
+ * target_currency_code: "USD"
299
+ * })
300
+ */
301
+ updateCurrencyConversionManyV1(request: Chrt.billingNew.InvoiceLineItemsCurrencyConversionUpdateManyReq, requestOptions?: InvoiceLineItems.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItem1[]>;
302
+ private __updateCurrencyConversionManyV1;
303
+ /**
304
+ * Updates an owner-scoped line item's source fields, reapplies any existing currency conversion, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
289
305
  *
290
306
  * @param {string} invoiceLineItemId
291
307
  * @param {Chrt.billingNew.InvoiceLineItemClientUpdate1} request
@@ -294,9 +310,9 @@ export declare class InvoiceLineItems {
294
310
  * @throws {@link Chrt.UnprocessableEntityError}
295
311
  *
296
312
  * @example
297
- * await client.billingNew.invoiceLineItems.updateV1("invoice_line_item_id")
313
+ * await client.billingNew.invoiceLineItems.updateSourceV1("invoice_line_item_id")
298
314
  */
299
- updateV1(invoiceLineItemId: string, request?: Chrt.billingNew.InvoiceLineItemClientUpdate1, requestOptions?: InvoiceLineItems.RequestOptions): core.HttpResponsePromise<boolean>;
300
- private __updateV1;
315
+ updateSourceV1(invoiceLineItemId: string, request?: Chrt.billingNew.InvoiceLineItemClientUpdate1, requestOptions?: InvoiceLineItems.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItem1>;
316
+ private __updateSourceV1;
301
317
  protected _getAuthorizationHeader(): Promise<string | undefined>;
302
318
  }
@@ -989,7 +989,72 @@ class InvoiceLineItems {
989
989
  });
990
990
  }
991
991
  /**
992
- * Updates an owner-scoped line item and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (bool)
992
+ * Applies or reverts one currency conversion on line items from their original source values and moves attached items to the matching target-currency draft invoice. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemsCurrencyConversionUpdateManyReq) -> (list[InvoiceLineItem1])
993
+ *
994
+ * @param {Chrt.billingNew.InvoiceLineItemsCurrencyConversionUpdateManyReq} request
995
+ * @param {InvoiceLineItems.RequestOptions} requestOptions - Request-specific configuration.
996
+ *
997
+ * @throws {@link Chrt.UnprocessableEntityError}
998
+ *
999
+ * @example
1000
+ * await client.billingNew.invoiceLineItems.updateCurrencyConversionManyV1({
1001
+ * invoice_line_item_ids: ["invoice_line_item_ids"],
1002
+ * target_currency_code: "USD"
1003
+ * })
1004
+ */
1005
+ updateCurrencyConversionManyV1(request, requestOptions) {
1006
+ return core.HttpResponsePromise.fromPromise(this.__updateCurrencyConversionManyV1(request, requestOptions));
1007
+ }
1008
+ __updateCurrencyConversionManyV1(request, requestOptions) {
1009
+ return __awaiter(this, void 0, void 0, function* () {
1010
+ var _a, _b, _c, _d;
1011
+ 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);
1012
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
1013
+ 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, "billing_new/invoice_line_items/update_currency_conversion_many/v1"),
1014
+ method: "PATCH",
1015
+ headers: _headers,
1016
+ contentType: "application/json",
1017
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
1018
+ requestType: "json",
1019
+ body: request,
1020
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
1021
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
1022
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
1023
+ });
1024
+ if (_response.ok) {
1025
+ return { data: _response.body, rawResponse: _response.rawResponse };
1026
+ }
1027
+ if (_response.error.reason === "status-code") {
1028
+ switch (_response.error.statusCode) {
1029
+ case 422:
1030
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
1031
+ default:
1032
+ throw new errors.ChrtError({
1033
+ statusCode: _response.error.statusCode,
1034
+ body: _response.error.body,
1035
+ rawResponse: _response.rawResponse,
1036
+ });
1037
+ }
1038
+ }
1039
+ switch (_response.error.reason) {
1040
+ case "non-json":
1041
+ throw new errors.ChrtError({
1042
+ statusCode: _response.error.statusCode,
1043
+ body: _response.error.rawBody,
1044
+ rawResponse: _response.rawResponse,
1045
+ });
1046
+ case "timeout":
1047
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /billing_new/invoice_line_items/update_currency_conversion_many/v1.");
1048
+ case "unknown":
1049
+ throw new errors.ChrtError({
1050
+ message: _response.error.errorMessage,
1051
+ rawResponse: _response.rawResponse,
1052
+ });
1053
+ }
1054
+ });
1055
+ }
1056
+ /**
1057
+ * Updates an owner-scoped line item's source fields, reapplies any existing currency conversion, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
993
1058
  *
994
1059
  * @param {string} invoiceLineItemId
995
1060
  * @param {Chrt.billingNew.InvoiceLineItemClientUpdate1} request
@@ -998,17 +1063,17 @@ class InvoiceLineItems {
998
1063
  * @throws {@link Chrt.UnprocessableEntityError}
999
1064
  *
1000
1065
  * @example
1001
- * await client.billingNew.invoiceLineItems.updateV1("invoice_line_item_id")
1066
+ * await client.billingNew.invoiceLineItems.updateSourceV1("invoice_line_item_id")
1002
1067
  */
1003
- updateV1(invoiceLineItemId, request = {}, requestOptions) {
1004
- return core.HttpResponsePromise.fromPromise(this.__updateV1(invoiceLineItemId, request, requestOptions));
1068
+ updateSourceV1(invoiceLineItemId, request = {}, requestOptions) {
1069
+ return core.HttpResponsePromise.fromPromise(this.__updateSourceV1(invoiceLineItemId, request, requestOptions));
1005
1070
  }
1006
- __updateV1(invoiceLineItemId_1) {
1071
+ __updateSourceV1(invoiceLineItemId_1) {
1007
1072
  return __awaiter(this, arguments, void 0, function* (invoiceLineItemId, request = {}, requestOptions) {
1008
1073
  var _a, _b, _c, _d;
1009
1074
  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);
1010
1075
  const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
1011
- 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, `billing_new/invoice_line_items/update/v1/${encodeURIComponent(invoiceLineItemId)}`),
1076
+ 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, `billing_new/invoice_line_items/update_source/v1/${encodeURIComponent(invoiceLineItemId)}`),
1012
1077
  method: "PATCH",
1013
1078
  headers: _headers,
1014
1079
  contentType: "application/json",
@@ -1042,7 +1107,7 @@ class InvoiceLineItems {
1042
1107
  rawResponse: _response.rawResponse,
1043
1108
  });
1044
1109
  case "timeout":
1045
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /billing_new/invoice_line_items/update/v1/{invoice_line_item_id}.");
1110
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /billing_new/invoice_line_items/update_source/v1/{invoice_line_item_id}.");
1046
1111
  case "unknown":
1047
1112
  throw new errors.ChrtError({
1048
1113
  message: _response.error.errorMessage,
@@ -7,13 +7,13 @@ import * as Chrt from "../../../../../../index.js";
7
7
  * {}
8
8
  */
9
9
  export interface InvoiceLineItemClientUpdate1 {
10
- currency_code?: Chrt.BillingCurrencyCodeEnum1 | null;
11
10
  description?: string | null;
12
11
  export_ref__sage__item_id?: string | null;
13
12
  export_ref__sage__item_id__set_to_None?: boolean;
14
13
  invoice_type?: Chrt.InvoiceTypeEnum1 | null;
15
14
  quantity?: number | null;
15
+ source_currency_code?: Chrt.BillingCurrencyCodeEnum1 | null;
16
+ source_unit_price?: number | null;
16
17
  unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
17
18
  unit__set_to_None?: boolean;
18
- unit_price?: number | null;
19
19
  }
@@ -0,0 +1,18 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../../../../../../index.js";
5
+ /**
6
+ * @example
7
+ * {
8
+ * invoice_line_item_ids: ["invoice_line_item_ids"],
9
+ * target_currency_code: "USD"
10
+ * }
11
+ */
12
+ export interface InvoiceLineItemsCurrencyConversionUpdateManyReq {
13
+ /** Units of target_currency_code per one unit of the line items' original source currency -- their currency_conversion.source_currency_code if already converted, otherwise their current currency_code. Always relative to that original source, never to an intermediate converted currency, so conversions never compound. Omitted when target_currency_code is the original source currency, which reverts the conversion. */
14
+ conversion_rate?: number | null;
15
+ description?: string | null;
16
+ invoice_line_item_ids: string[];
17
+ target_currency_code: Chrt.BillingCurrencyCodeEnum1;
18
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -5,4 +5,5 @@ export { type CreateInvoiceLineItemsFromLineItemsReq } from "./CreateInvoiceLine
5
5
  export { type InvoiceLineItemsDeleteManyReq } from "./InvoiceLineItemsDeleteManyReq.js";
6
6
  export { type InvoiceLineItemsListV1Request } from "./InvoiceLineItemsListV1Request.js";
7
7
  export { type RecalculateOrderTaxInvoiceLineItemsReq } from "./RecalculateOrderTaxInvoiceLineItemsReq.js";
8
+ export { type InvoiceLineItemsCurrencyConversionUpdateManyReq } from "./InvoiceLineItemsCurrencyConversionUpdateManyReq.js";
8
9
  export { type InvoiceLineItemClientUpdate1 } from "./InvoiceLineItemClientUpdate1.js";
@@ -31,7 +31,7 @@ export declare class Export {
31
31
  protected readonly _options: Export.Options;
32
32
  constructor(_options?: Export.Options);
33
33
  /**
34
- * Lists up to 1,000 shipment-level export rows for one approved accounts-receivable invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExportListRes)
34
+ * Lists up to 1,000 shipment-level export rows for one accounts-receivable invoice owned by the caller's organization, regardless of invoice status. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExportListRes)
35
35
  *
36
36
  * @param {string} invoiceId
37
37
  * @param {Chrt.billingNew.invoices.ExportListV1Request} request
@@ -56,7 +56,7 @@ class Export {
56
56
  this._options = _options;
57
57
  }
58
58
  /**
59
- * Lists up to 1,000 shipment-level export rows for one approved accounts-receivable invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExportListRes)
59
+ * Lists up to 1,000 shipment-level export rows for one accounts-receivable invoice owned by the caller's organization, regardless of invoice status. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExportListRes)
60
60
  *
61
61
  * @param {string} invoiceId
62
62
  * @param {Chrt.billingNew.invoices.ExportListV1Request} request
@@ -12,6 +12,7 @@ export interface OrderTemplateNewTaskClientCreate1 {
12
12
  contact_ids?: string[];
13
13
  coordinator_shipper_account_ids?: string[];
14
14
  datetime_windows_dateparser_str?: Chrt.OrderTemplateNewDateTimeWindow1[];
15
+ flight_leg_id?: string | null;
15
16
  geofence_distance_miles?: number;
16
17
  location?: Chrt.LocationFeature | null;
17
18
  order_placer_comments?: string | null;
@@ -248,6 +248,19 @@ export declare class Orders {
248
248
  */
249
249
  unassignV1(orderId: string, request: Chrt.shipping.OrdersUnassignReq, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<boolean>;
250
250
  private __unassignV1;
251
+ /**
252
+ * Reopens a cancelled order, restaging every cancelled task group, task, task artifact, operations task, and cargo on it regardless of when each was cancelled, then re-deriving order, cargo, and driver status from the surviving work. | authz_personas=[task_group_operating_org_operators] | () -> (bool)
253
+ *
254
+ * @param {string} orderId
255
+ * @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
256
+ *
257
+ * @throws {@link Chrt.UnprocessableEntityError}
258
+ *
259
+ * @example
260
+ * await client.shipping.orders.undoCancelV1("order_id")
261
+ */
262
+ undoCancelV1(orderId: string, requestOptions?: Orders.RequestOptions): core.HttpResponsePromise<boolean>;
263
+ private __undoCancelV1;
251
264
  /**
252
265
  * Updates department_id for the caller's role on the order. Coordinator writes coordinator_department_id; executor writes executor_department_id on matching task_group_details rows. | authz_personas=[coordinator_org_operators, order_executor_org_operators] | (OrdersUpdateDepartmentReq) -> (bool)
253
266
  *
@@ -922,6 +922,65 @@ class Orders {
922
922
  }
923
923
  });
924
924
  }
925
+ /**
926
+ * Reopens a cancelled order, restaging every cancelled task group, task, task artifact, operations task, and cargo on it regardless of when each was cancelled, then re-deriving order, cargo, and driver status from the surviving work. | authz_personas=[task_group_operating_org_operators] | () -> (bool)
927
+ *
928
+ * @param {string} orderId
929
+ * @param {Orders.RequestOptions} requestOptions - Request-specific configuration.
930
+ *
931
+ * @throws {@link Chrt.UnprocessableEntityError}
932
+ *
933
+ * @example
934
+ * await client.shipping.orders.undoCancelV1("order_id")
935
+ */
936
+ undoCancelV1(orderId, requestOptions) {
937
+ return core.HttpResponsePromise.fromPromise(this.__undoCancelV1(orderId, requestOptions));
938
+ }
939
+ __undoCancelV1(orderId, requestOptions) {
940
+ return __awaiter(this, void 0, void 0, function* () {
941
+ var _a, _b, _c, _d;
942
+ 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);
943
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
944
+ 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/orders/undo_cancel/v1/${encodeURIComponent(orderId)}`),
945
+ method: "PUT",
946
+ headers: _headers,
947
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
948
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
949
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
950
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
951
+ });
952
+ if (_response.ok) {
953
+ return { data: _response.body, rawResponse: _response.rawResponse };
954
+ }
955
+ if (_response.error.reason === "status-code") {
956
+ switch (_response.error.statusCode) {
957
+ case 422:
958
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
959
+ default:
960
+ throw new errors.ChrtError({
961
+ statusCode: _response.error.statusCode,
962
+ body: _response.error.body,
963
+ rawResponse: _response.rawResponse,
964
+ });
965
+ }
966
+ }
967
+ switch (_response.error.reason) {
968
+ case "non-json":
969
+ throw new errors.ChrtError({
970
+ statusCode: _response.error.statusCode,
971
+ body: _response.error.rawBody,
972
+ rawResponse: _response.rawResponse,
973
+ });
974
+ case "timeout":
975
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PUT /shipping/orders/undo_cancel/v1/{order_id}.");
976
+ case "unknown":
977
+ throw new errors.ChrtError({
978
+ message: _response.error.errorMessage,
979
+ rawResponse: _response.rawResponse,
980
+ });
981
+ }
982
+ });
983
+ }
925
984
  /**
926
985
  * Updates department_id for the caller's role on the order. Coordinator writes coordinator_department_id; executor writes executor_department_id on matching task_group_details rows. | authz_personas=[coordinator_org_operators, order_executor_org_operators] | (OrdersUpdateDepartmentReq) -> (bool)
927
986
  *
@@ -67,7 +67,7 @@ export declare class Cargo {
67
67
  associateWithTaskV1(request: Chrt.shipping.orders.OrdersAssociateCargoWithTaskReq, requestOptions?: Cargo.RequestOptions): core.HttpResponsePromise<boolean>;
68
68
  private __associateWithTaskV1;
69
69
  /**
70
- * Deletes active cargo without completed task associations and resynchronizes the order AWB cache. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
70
+ * Deletes cargo in any lifecycle state, removes task associations, and resynchronizes the order AWB cache. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
71
71
  *
72
72
  * @param {string} cargoId
73
73
  * @param {Cargo.RequestOptions} requestOptions - Request-specific configuration.
@@ -190,7 +190,7 @@ class Cargo {
190
190
  });
191
191
  }
192
192
  /**
193
- * Deletes active cargo without completed task associations and resynchronizes the order AWB cache. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
193
+ * Deletes cargo in any lifecycle state, removes task associations, and resynchronizes the order AWB cache. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
194
194
  *
195
195
  * @param {string} cargoId
196
196
  * @param {Cargo.RequestOptions} requestOptions - Request-specific configuration.
@@ -92,6 +92,7 @@ export declare class Expanded {
92
92
  * filter_exception_at_timestamp_lte: "2024-01-15T09:30:00Z",
93
93
  * filter_exception_at_timestamp_gte: "2024-01-15T09:30:00Z",
94
94
  * filter_executor_org_id: "filter_executor_org_id",
95
+ * filter_executor_department_id: "filter_executor_department_id",
95
96
  * filter_off_chrt_executor_org_data_id: "filter_off_chrt_executor_org_data_id",
96
97
  * filter_coordinator_org_id: "filter_coordinator_org_id",
97
98
  * filter_shipper_org_id: "filter_shipper_org_id",
@@ -215,6 +215,7 @@ class Expanded {
215
215
  * filter_exception_at_timestamp_lte: "2024-01-15T09:30:00Z",
216
216
  * filter_exception_at_timestamp_gte: "2024-01-15T09:30:00Z",
217
217
  * filter_executor_org_id: "filter_executor_org_id",
218
+ * filter_executor_department_id: "filter_executor_department_id",
218
219
  * filter_off_chrt_executor_org_data_id: "filter_off_chrt_executor_org_data_id",
219
220
  * filter_coordinator_org_id: "filter_coordinator_org_id",
220
221
  * filter_shipper_org_id: "filter_shipper_org_id",
@@ -232,7 +233,7 @@ class Expanded {
232
233
  __listForProviderOperatorsV1(request, requestOptions) {
233
234
  return __awaiter(this, void 0, void 0, function* () {
234
235
  var _a, _b, _c, _d, _e, _f, _g;
235
- const { provider_role: providerRole, sort_by: sortBy, sort_order: sortOrder, page, page_size: pageSize, search, filter_status: filterStatus, filter_service_line: filterServiceLine, filter_order_classification_by_task_group_type: filterOrderClassificationByTaskGroupType, filter_awb_number: filterAwbNumber, filter_has_invoice: filterHasInvoice, filter_draft_started_at_timestamp_lte: filterDraftStartedAtTimestampLte, filter_draft_started_at_timestamp_gte: filterDraftStartedAtTimestampGte, filter_staged_at_timestamp_lte: filterStagedAtTimestampLte, filter_staged_at_timestamp_gte: filterStagedAtTimestampGte, filter_in_progress_at_timestamp_lte: filterInProgressAtTimestampLte, filter_in_progress_at_timestamp_gte: filterInProgressAtTimestampGte, filter_completed_at_timestamp_lte: filterCompletedAtTimestampLte, filter_completed_at_timestamp_gte: filterCompletedAtTimestampGte, filter_cancelled_at_timestamp_lte: filterCancelledAtTimestampLte, filter_cancelled_at_timestamp_gte: filterCancelledAtTimestampGte, filter_exception_at_timestamp_lte: filterExceptionAtTimestampLte, filter_exception_at_timestamp_gte: filterExceptionAtTimestampGte, filter_executor_org_id: filterExecutorOrgId, filter_off_chrt_executor_org_data_id: filterOffChrtExecutorOrgDataId, filter_coordinator_org_id: filterCoordinatorOrgId, filter_shipper_org_id: filterShipperOrgId, filter_off_chrt_shipper_org_data_id: filterOffChrtShipperOrgDataId, filter_coordinator_shipper_account_ids: filterCoordinatorShipperAccountIds, filter_coordinator_department_id: filterCoordinatorDepartmentId, filter_coordinator_assigned_user_ids: filterCoordinatorAssignedUserIds, filter_coordinator_label: filterCoordinatorLabel, body: _body, } = request;
236
+ const { provider_role: providerRole, sort_by: sortBy, sort_order: sortOrder, page, page_size: pageSize, search, filter_status: filterStatus, filter_service_line: filterServiceLine, filter_order_classification_by_task_group_type: filterOrderClassificationByTaskGroupType, filter_awb_number: filterAwbNumber, filter_has_invoice: filterHasInvoice, filter_draft_started_at_timestamp_lte: filterDraftStartedAtTimestampLte, filter_draft_started_at_timestamp_gte: filterDraftStartedAtTimestampGte, filter_staged_at_timestamp_lte: filterStagedAtTimestampLte, filter_staged_at_timestamp_gte: filterStagedAtTimestampGte, filter_in_progress_at_timestamp_lte: filterInProgressAtTimestampLte, filter_in_progress_at_timestamp_gte: filterInProgressAtTimestampGte, filter_completed_at_timestamp_lte: filterCompletedAtTimestampLte, filter_completed_at_timestamp_gte: filterCompletedAtTimestampGte, filter_cancelled_at_timestamp_lte: filterCancelledAtTimestampLte, filter_cancelled_at_timestamp_gte: filterCancelledAtTimestampGte, filter_exception_at_timestamp_lte: filterExceptionAtTimestampLte, filter_exception_at_timestamp_gte: filterExceptionAtTimestampGte, filter_executor_org_id: filterExecutorOrgId, filter_executor_department_id: filterExecutorDepartmentId, filter_off_chrt_executor_org_data_id: filterOffChrtExecutorOrgDataId, filter_coordinator_org_id: filterCoordinatorOrgId, filter_shipper_org_id: filterShipperOrgId, filter_off_chrt_shipper_org_data_id: filterOffChrtShipperOrgDataId, filter_coordinator_shipper_account_ids: filterCoordinatorShipperAccountIds, filter_coordinator_department_id: filterCoordinatorDepartmentId, filter_coordinator_assigned_user_ids: filterCoordinatorAssignedUserIds, filter_coordinator_label: filterCoordinatorLabel, body: _body, } = request;
236
237
  const _queryParams = {};
237
238
  if (providerRole !== undefined) {
238
239
  _queryParams["provider_role"] = providerRole;
@@ -323,6 +324,9 @@ class Expanded {
323
324
  if (filterExecutorOrgId !== undefined) {
324
325
  _queryParams["filter_executor_org_id"] = filterExecutorOrgId;
325
326
  }
327
+ if (filterExecutorDepartmentId !== undefined) {
328
+ _queryParams["filter_executor_department_id"] = filterExecutorDepartmentId;
329
+ }
326
330
  if (filterOffChrtExecutorOrgDataId !== undefined) {
327
331
  _queryParams["filter_off_chrt_executor_org_data_id"] = filterOffChrtExecutorOrgDataId;
328
332
  }
@@ -29,6 +29,7 @@ import * as Chrt from "../../../../../../../../index.js";
29
29
  * filter_exception_at_timestamp_lte: "2024-01-15T09:30:00Z",
30
30
  * filter_exception_at_timestamp_gte: "2024-01-15T09:30:00Z",
31
31
  * filter_executor_org_id: "filter_executor_org_id",
32
+ * filter_executor_department_id: "filter_executor_department_id",
32
33
  * filter_off_chrt_executor_org_data_id: "filter_off_chrt_executor_org_data_id",
33
34
  * filter_coordinator_org_id: "filter_coordinator_org_id",
34
35
  * filter_shipper_org_id: "filter_shipper_org_id",
@@ -71,6 +72,8 @@ export interface ExpandedListForProviderOperatorsV1Request {
71
72
  filter_exception_at_timestamp_lte?: string | null;
72
73
  filter_exception_at_timestamp_gte?: string | null;
73
74
  filter_executor_org_id?: string | null;
75
+ /** Filter by executor department ID */
76
+ filter_executor_department_id?: string | null;
74
77
  /** Filter by off-CHRT executor org data ID */
75
78
  filter_off_chrt_executor_org_data_id?: string | null;
76
79
  filter_coordinator_org_id?: string | null;
@@ -49,7 +49,7 @@ export declare class Task {
49
49
  addV1(request: Chrt.shipping.orders.OrdersAddTaskReq, requestOptions?: Task.RequestOptions): core.HttpResponsePromise<string>;
50
50
  private __addV1;
51
51
  /**
52
- * Deletes a task, recalculates task-group mileage, and rejects operational deletion while artifacts remain. | () -> (bool)
52
+ * Deletes a task in any lifecycle state and synchronizes affected shipping state. | () -> (bool)
53
53
  *
54
54
  * @param {string} taskId
55
55
  * @param {Task.RequestOptions} requestOptions - Request-specific configuration.
@@ -123,7 +123,7 @@ class Task {
123
123
  });
124
124
  }
125
125
  /**
126
- * Deletes a task, recalculates task-group mileage, and rejects operational deletion while artifacts remain. | () -> (bool)
126
+ * Deletes a task in any lifecycle state and synchronizes affected shipping state. | () -> (bool)
127
127
  *
128
128
  * @param {string} taskId
129
129
  * @param {Task.RequestOptions} requestOptions - Request-specific configuration.
@@ -31,7 +31,7 @@ export declare class TaskGroup {
31
31
  protected readonly _options: TaskGroup.Options;
32
32
  constructor(_options?: TaskGroup.Options);
33
33
  /**
34
- * Adds a task group to a non-terminal order. Groups added to DRAFT orders are DRAFT; groups added to STAGED or IN_PROGRESS orders are STAGED. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | (OrdersAddTaskGroupReq) -> (PydanticObjectId)
34
+ * Adds a task group to an order. Draft groups are DRAFT; all later lifecycle groups are STAGED and parent state is synchronized. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | (OrdersAddTaskGroupReq) -> (PydanticObjectId)
35
35
  *
36
36
  * @param {Chrt.shipping.orders.OrdersAddTaskGroupReq} request
37
37
  * @param {TaskGroup.RequestOptions} requestOptions - Request-specific configuration.
@@ -61,7 +61,7 @@ export declare class TaskGroup {
61
61
  addExecutorV1(taskGroupId: string, request?: Chrt.shipping.orders.OrdersAddTaskGroupExecutorReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
62
62
  private __addExecutorV1;
63
63
  /**
64
- * Deletes a task group from an active order and synchronizes affected order, driver, cargo, and account state. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
64
+ * Deletes a task group in any lifecycle state and synchronizes affected shipping state. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
65
65
  *
66
66
  * @param {string} taskGroupId
67
67
  * @param {TaskGroup.RequestOptions} requestOptions - Request-specific configuration.
@@ -100,7 +100,7 @@ export declare class TaskGroup {
100
100
  removeExecutorV1(taskGroupId: string, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
101
101
  private __removeExecutorV1;
102
102
  /**
103
- * Replaces the ordered flight legs on an order task group. | (OrdersSetTaskGroupFlightInfoReq) -> (bool)
103
+ * Replaces the ordered flight legs on an order task group. A submitted leg that is the same physical flight (carrier, flight number, origin, destination, UTC departure date) as an existing leg keeps its id, so tasks reporting on it stay attached. Changing any of those five details is a different flight: the old leg is deleted and any task referencing it has its flight_leg_id cleared. Because flight_leg_id is not editable, re-attaching such a task requires deleting and recreating it. | (OrdersSetTaskGroupFlightInfoReq) -> (bool)
104
104
  *
105
105
  * @param {string} taskGroupId
106
106
  * @param {Chrt.shipping.orders.OrdersSetTaskGroupFlightInfoReq} request
@@ -124,7 +124,7 @@ export declare class TaskGroup {
124
124
  setFlightInfoV1(taskGroupId: string, request: Chrt.shipping.orders.OrdersSetTaskGroupFlightInfoReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
125
125
  private __setFlightInfoV1;
126
126
  /**
127
- * Sets the ordering of tasks within an order task group and recalculates estimated mileage. DRAFT orders require draft_creator_org_operator; operational orders require task_group_operating_org_operators and a STAGED or IN_PROGRESS task group. | authz_personas=[draft_creator_org_operator, task_group_operating_org_operators] | (OrdersSetTaskGroupTaskOrderingReq) -> (bool)
127
+ * Sets task ordering in any lifecycle state, recalculating mileage and affected cargo state. | authz_personas=[draft_creator_org_operator, task_group_operating_org_operators] | (OrdersSetTaskGroupTaskOrderingReq) -> (bool)
128
128
  *
129
129
  * @param {string} taskGroupId
130
130
  * @param {Chrt.shipping.orders.OrdersSetTaskGroupTaskOrderingReq} request
@@ -140,7 +140,7 @@ export declare class TaskGroup {
140
140
  setTaskOrderingV1(taskGroupId: string, request: Chrt.shipping.orders.OrdersSetTaskGroupTaskOrderingReq, requestOptions?: TaskGroup.RequestOptions): core.HttpResponsePromise<boolean>;
141
141
  private __setTaskOrderingV1;
142
142
  /**
143
- * Sets the vehicle type until the task group reaches a terminal status. | authz_personas=[draft_creator_org_operator, task_group_coordinator_operators] | (OrdersSetTaskGroupVehicleTypeReq) -> (bool)
143
+ * Sets the task-group vehicle type in any lifecycle state. | authz_personas=[draft_creator_org_operator, task_group_coordinator_operators] | (OrdersSetTaskGroupVehicleTypeReq) -> (bool)
144
144
  *
145
145
  * @param {string} taskGroupId
146
146
  * @param {Chrt.shipping.orders.OrdersSetTaskGroupVehicleTypeReq} request
@@ -56,7 +56,7 @@ class TaskGroup {
56
56
  this._options = _options;
57
57
  }
58
58
  /**
59
- * Adds a task group to a non-terminal order. Groups added to DRAFT orders are DRAFT; groups added to STAGED or IN_PROGRESS orders are STAGED. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | (OrdersAddTaskGroupReq) -> (PydanticObjectId)
59
+ * Adds a task group to an order. Draft groups are DRAFT; all later lifecycle groups are STAGED and parent state is synchronized. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | (OrdersAddTaskGroupReq) -> (PydanticObjectId)
60
60
  *
61
61
  * @param {Chrt.shipping.orders.OrdersAddTaskGroupReq} request
62
62
  * @param {TaskGroup.RequestOptions} requestOptions - Request-specific configuration.
@@ -184,7 +184,7 @@ class TaskGroup {
184
184
  });
185
185
  }
186
186
  /**
187
- * Deletes a task group from an active order and synchronizes affected order, driver, cargo, and account state. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
187
+ * Deletes a task group in any lifecycle state and synchronizes affected shipping state. | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (bool)
188
188
  *
189
189
  * @param {string} taskGroupId
190
190
  * @param {TaskGroup.RequestOptions} requestOptions - Request-specific configuration.
@@ -361,7 +361,7 @@ class TaskGroup {
361
361
  });
362
362
  }
363
363
  /**
364
- * Replaces the ordered flight legs on an order task group. | (OrdersSetTaskGroupFlightInfoReq) -> (bool)
364
+ * Replaces the ordered flight legs on an order task group. A submitted leg that is the same physical flight (carrier, flight number, origin, destination, UTC departure date) as an existing leg keeps its id, so tasks reporting on it stay attached. Changing any of those five details is a different flight: the old leg is deleted and any task referencing it has its flight_leg_id cleared. Because flight_leg_id is not editable, re-attaching such a task requires deleting and recreating it. | (OrdersSetTaskGroupFlightInfoReq) -> (bool)
365
365
  *
366
366
  * @param {string} taskGroupId
367
367
  * @param {Chrt.shipping.orders.OrdersSetTaskGroupFlightInfoReq} request
@@ -434,7 +434,7 @@ class TaskGroup {
434
434
  });
435
435
  }
436
436
  /**
437
- * Sets the ordering of tasks within an order task group and recalculates estimated mileage. DRAFT orders require draft_creator_org_operator; operational orders require task_group_operating_org_operators and a STAGED or IN_PROGRESS task group. | authz_personas=[draft_creator_org_operator, task_group_operating_org_operators] | (OrdersSetTaskGroupTaskOrderingReq) -> (bool)
437
+ * Sets task ordering in any lifecycle state, recalculating mileage and affected cargo state. | authz_personas=[draft_creator_org_operator, task_group_operating_org_operators] | (OrdersSetTaskGroupTaskOrderingReq) -> (bool)
438
438
  *
439
439
  * @param {string} taskGroupId
440
440
  * @param {Chrt.shipping.orders.OrdersSetTaskGroupTaskOrderingReq} request
@@ -499,7 +499,7 @@ class TaskGroup {
499
499
  });
500
500
  }
501
501
  /**
502
- * Sets the vehicle type until the task group reaches a terminal status. | authz_personas=[draft_creator_org_operator, task_group_coordinator_operators] | (OrdersSetTaskGroupVehicleTypeReq) -> (bool)
502
+ * Sets the task-group vehicle type in any lifecycle state. | authz_personas=[draft_creator_org_operator, task_group_coordinator_operators] | (OrdersSetTaskGroupVehicleTypeReq) -> (bool)
503
503
  *
504
504
  * @param {string} taskGroupId
505
505
  * @param {Chrt.shipping.orders.OrdersSetTaskGroupVehicleTypeReq} request
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
- export type DepartmentTypeEnum = "aerospace" | "agriculture" | "automotive" | "chemicals" | "electronics" | "energy" | "food_and_beverage" | "general" | "healthcare" | "industrials" | "life_sciences" | "live_animals" | "manufacturing" | "pharmaceutical" | "radiopharma" | "retail" | "semiconductor";
4
+ export type DepartmentTypeEnum = "aerospace" | "agriculture" | "automotive" | "chemicals" | "electronics" | "energy" | "food_and_beverage" | "general" | "healthcare" | "industrials" | "life_sciences" | "live_animals" | "manufacturing" | "marine" | "pharmaceutical" | "radiopharma" | "retail" | "semiconductor";
5
5
  export declare const DepartmentTypeEnum: {
6
6
  readonly Aerospace: "aerospace";
7
7
  readonly Agriculture: "agriculture";
@@ -16,6 +16,7 @@ export declare const DepartmentTypeEnum: {
16
16
  readonly LifeSciences: "life_sciences";
17
17
  readonly LiveAnimals: "live_animals";
18
18
  readonly Manufacturing: "manufacturing";
19
+ readonly Marine: "marine";
19
20
  readonly Pharmaceutical: "pharmaceutical";
20
21
  readonly Radiopharma: "radiopharma";
21
22
  readonly Retail: "retail";
@@ -18,6 +18,7 @@ exports.DepartmentTypeEnum = {
18
18
  LifeSciences: "life_sciences",
19
19
  LiveAnimals: "live_animals",
20
20
  Manufacturing: "manufacturing",
21
+ Marine: "marine",
21
22
  Pharmaceutical: "pharmaceutical",
22
23
  Radiopharma: "radiopharma",
23
24
  Retail: "retail",
@@ -21,7 +21,7 @@ export interface InvoiceExportListItem {
21
21
  delivery_stops_on_order?: number | null;
22
22
  destination_iata?: string | null;
23
23
  flight_numbers?: string[];
24
- invoice_approval_timestamp: string;
24
+ invoice_approval_timestamp?: string | null;
25
25
  invoice_number: string;
26
26
  mileage_estimated?: number | null;
27
27
  net_billing: number;
@@ -15,6 +15,7 @@ export interface InvoiceLineItem1 {
15
15
  /** Must be a string starting with `user_` */
16
16
  created_by_user_id: string;
17
17
  currency_code: Chrt.BillingCurrencyCodeEnum1;
18
+ currency_conversion?: Chrt.InvoiceLineItemCurrencyConversion1 | null;
18
19
  description: string;
19
20
  export_ref__sage__item_id?: string | null;
20
21
  invoice_id?: string | null;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../index.js";
5
+ export interface InvoiceLineItemCurrencyConversion1 {
6
+ /** Units of the target currency per one unit of source_currency_code. unit_price = source_unit_price * conversion_rate. */
7
+ conversion_rate: number;
8
+ description?: string | null;
9
+ source_currency_code: Chrt.BillingCurrencyCodeEnum1;
10
+ source_unit_price: number;
11
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -14,6 +14,7 @@ export interface InvoiceLineItemServerCreate1 {
14
14
  /** Must be a string starting with `user_` */
15
15
  created_by_user_id: string;
16
16
  currency_code: Chrt.BillingCurrencyCodeEnum1;
17
+ currency_conversion?: Chrt.InvoiceLineItemCurrencyConversion1 | null;
17
18
  description: string;
18
19
  export_ref__sage__item_id?: string | null;
19
20
  invoice_id?: string | null;
@@ -5,10 +5,12 @@ export interface OrderAndTaskGroupExpandedReq {
5
5
  expand_accounts?: boolean;
6
6
  expand_cargos?: boolean;
7
7
  expand_contacts?: boolean;
8
+ expand_coordinator_department?: boolean;
8
9
  expand_coordinator_org_company_name?: boolean;
9
10
  expand_coordinator_org_handle?: boolean;
10
11
  expand_coordinator_task_lists_to_apply_at_order_staging?: boolean;
11
12
  expand_driver?: boolean;
13
+ expand_executor_department?: boolean;
12
14
  expand_executor_org_company_name?: boolean;
13
15
  expand_executor_org_handle?: boolean;
14
16
  expand_notification_intents_ad_hoc?: boolean;