@chrt-inc/typescript-sdk 1.961.0 → 1.963.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 (130) hide show
  1. package/dist/cjs/Client.js +2 -2
  2. package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.d.ts +3 -0
  3. package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.js +5 -0
  4. package/dist/cjs/api/resources/billingNew/resources/invoices/index.d.ts +1 -0
  5. package/dist/cjs/api/resources/billingNew/resources/invoices/index.js +1 -0
  6. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/Client.d.ts +51 -0
  7. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/Client.js +139 -0
  8. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/index.d.ts +2 -0
  9. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/index.js +17 -0
  10. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/requests/ExportListV1Request.d.ts +14 -0
  11. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/requests/ExportListV1Request.js +5 -0
  12. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.d.ts +1 -0
  13. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.js +2 -0
  14. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/index.d.ts +1 -0
  15. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/index.js +17 -0
  16. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/index.d.ts +2 -0
  17. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/index.js +41 -0
  18. package/dist/cjs/api/resources/shipping/resources/index.d.ts +1 -0
  19. package/dist/cjs/api/resources/shipping/resources/index.js +1 -0
  20. package/dist/cjs/api/resources/shipping/resources/orders/resources/orderEvents/client/Client.d.ts +2 -2
  21. package/dist/cjs/api/resources/shipping/resources/orders/resources/orderEvents/client/Client.js +2 -2
  22. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/Client.d.ts +15 -0
  23. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/Client.js +63 -0
  24. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/index.d.ts +1 -0
  25. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/index.js +15 -0
  26. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/requests/TaskArtifactCustodyPartiesUpdateReq.d.ts +14 -0
  27. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/requests/TaskArtifactCustodyPartiesUpdateReq.js +5 -0
  28. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/requests/index.d.ts +1 -0
  29. package/dist/cjs/api/resources/shipping/resources/taskArtifacts/client/requests/index.js +2 -0
  30. package/dist/cjs/api/resources/shipping/resources/tasks/client/Client.d.ts +14 -0
  31. package/dist/cjs/api/resources/shipping/resources/tasks/client/Client.js +63 -0
  32. package/dist/cjs/api/resources/shipping/resources/tasks/client/requests/TaskCustodyPartiesUpdateReq.d.ts +14 -0
  33. package/dist/cjs/api/resources/shipping/resources/tasks/client/requests/TaskCustodyPartiesUpdateReq.js +5 -0
  34. package/dist/cjs/api/resources/shipping/resources/tasks/client/requests/index.d.ts +1 -0
  35. package/dist/cjs/api/resources/trackingIntegrations/resources/reelables/resources/assets/client/Client.d.ts +26 -0
  36. package/dist/cjs/api/resources/trackingIntegrations/resources/reelables/resources/assets/client/Client.js +118 -0
  37. package/dist/cjs/api/resources/users/resources/privateData/client/Client.d.ts +15 -0
  38. package/dist/cjs/api/resources/users/resources/privateData/client/Client.js +64 -0
  39. package/dist/cjs/api/resources/users/resources/privateData/client/requests/UserPrivateDataNameUpdateReq.d.ts +12 -0
  40. package/dist/cjs/api/resources/users/resources/privateData/client/requests/UserPrivateDataNameUpdateReq.js +5 -0
  41. package/dist/cjs/api/resources/users/resources/privateData/client/requests/index.d.ts +1 -0
  42. package/dist/cjs/api/types/CustodyParty1.d.ts +10 -0
  43. package/dist/cjs/api/types/CustodyParty1.js +5 -0
  44. package/dist/cjs/api/types/CustodyPartyExpanded.d.ts +13 -0
  45. package/dist/cjs/api/types/CustodyPartyExpanded.js +5 -0
  46. package/dist/cjs/api/types/InvoiceExportListItem.d.ts +46 -0
  47. package/dist/cjs/api/types/InvoiceExportListItem.js +5 -0
  48. package/dist/cjs/api/types/InvoiceExportListRes.d.ts +8 -0
  49. package/dist/cjs/api/types/InvoiceExportListRes.js +5 -0
  50. package/dist/cjs/api/types/OrderEventActionEnum1.d.ts +2 -1
  51. package/dist/cjs/api/types/OrderEventActionEnum1.js +1 -0
  52. package/dist/cjs/api/types/OrderEventExpanded1.d.ts +1 -1
  53. package/dist/cjs/api/types/ReelablesAsset1.d.ts +3 -0
  54. package/dist/cjs/api/types/ReelablesAssetPausedTimeWindow1.d.ts +7 -0
  55. package/dist/cjs/api/types/ReelablesAssetPausedTimeWindow1.js +5 -0
  56. package/dist/cjs/api/types/ReelablesDataPointMetadata1.d.ts +1 -0
  57. package/dist/cjs/api/types/Task1.d.ts +2 -0
  58. package/dist/cjs/api/types/TaskArtifact1.d.ts +2 -0
  59. package/dist/cjs/api/types/TaskExpanded.d.ts +2 -0
  60. package/dist/cjs/api/types/UserPrivateData1.d.ts +1 -0
  61. package/dist/cjs/api/types/index.d.ts +5 -0
  62. package/dist/cjs/api/types/index.js +5 -0
  63. package/dist/cjs/version.d.ts +1 -1
  64. package/dist/cjs/version.js +1 -1
  65. package/dist/esm/Client.mjs +2 -2
  66. package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.d.mts +3 -0
  67. package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.mjs +5 -0
  68. package/dist/esm/api/resources/billingNew/resources/invoices/index.d.mts +1 -0
  69. package/dist/esm/api/resources/billingNew/resources/invoices/index.mjs +1 -0
  70. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/Client.d.mts +51 -0
  71. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/Client.mjs +102 -0
  72. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/index.d.mts +2 -0
  73. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/index.mjs +1 -0
  74. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/requests/ExportListV1Request.d.mts +14 -0
  75. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/requests/ExportListV1Request.mjs +4 -0
  76. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.d.mts +1 -0
  77. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.mjs +1 -0
  78. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/index.d.mts +1 -0
  79. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/index.mjs +1 -0
  80. package/dist/esm/api/resources/billingNew/resources/invoices/resources/index.d.mts +2 -0
  81. package/dist/esm/api/resources/billingNew/resources/invoices/resources/index.mjs +2 -0
  82. package/dist/esm/api/resources/shipping/resources/index.d.mts +1 -0
  83. package/dist/esm/api/resources/shipping/resources/index.mjs +1 -0
  84. package/dist/esm/api/resources/shipping/resources/orders/resources/orderEvents/client/Client.d.mts +2 -2
  85. package/dist/esm/api/resources/shipping/resources/orders/resources/orderEvents/client/Client.mjs +2 -2
  86. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/Client.d.mts +15 -0
  87. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/Client.mjs +63 -0
  88. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/index.d.mts +1 -0
  89. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/index.mjs +1 -1
  90. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/requests/TaskArtifactCustodyPartiesUpdateReq.d.mts +14 -0
  91. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/requests/TaskArtifactCustodyPartiesUpdateReq.mjs +4 -0
  92. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/requests/index.d.mts +1 -0
  93. package/dist/esm/api/resources/shipping/resources/taskArtifacts/client/requests/index.mjs +1 -0
  94. package/dist/esm/api/resources/shipping/resources/tasks/client/Client.d.mts +14 -0
  95. package/dist/esm/api/resources/shipping/resources/tasks/client/Client.mjs +63 -0
  96. package/dist/esm/api/resources/shipping/resources/tasks/client/requests/TaskCustodyPartiesUpdateReq.d.mts +14 -0
  97. package/dist/esm/api/resources/shipping/resources/tasks/client/requests/TaskCustodyPartiesUpdateReq.mjs +4 -0
  98. package/dist/esm/api/resources/shipping/resources/tasks/client/requests/index.d.mts +1 -0
  99. package/dist/esm/api/resources/trackingIntegrations/resources/reelables/resources/assets/client/Client.d.mts +26 -0
  100. package/dist/esm/api/resources/trackingIntegrations/resources/reelables/resources/assets/client/Client.mjs +118 -0
  101. package/dist/esm/api/resources/users/resources/privateData/client/Client.d.mts +15 -0
  102. package/dist/esm/api/resources/users/resources/privateData/client/Client.mjs +64 -0
  103. package/dist/esm/api/resources/users/resources/privateData/client/requests/UserPrivateDataNameUpdateReq.d.mts +12 -0
  104. package/dist/esm/api/resources/users/resources/privateData/client/requests/UserPrivateDataNameUpdateReq.mjs +4 -0
  105. package/dist/esm/api/resources/users/resources/privateData/client/requests/index.d.mts +1 -0
  106. package/dist/esm/api/types/CustodyParty1.d.mts +10 -0
  107. package/dist/esm/api/types/CustodyParty1.mjs +4 -0
  108. package/dist/esm/api/types/CustodyPartyExpanded.d.mts +13 -0
  109. package/dist/esm/api/types/CustodyPartyExpanded.mjs +4 -0
  110. package/dist/esm/api/types/InvoiceExportListItem.d.mts +46 -0
  111. package/dist/esm/api/types/InvoiceExportListItem.mjs +4 -0
  112. package/dist/esm/api/types/InvoiceExportListRes.d.mts +8 -0
  113. package/dist/esm/api/types/InvoiceExportListRes.mjs +4 -0
  114. package/dist/esm/api/types/OrderEventActionEnum1.d.mts +2 -1
  115. package/dist/esm/api/types/OrderEventActionEnum1.mjs +1 -0
  116. package/dist/esm/api/types/OrderEventExpanded1.d.mts +1 -1
  117. package/dist/esm/api/types/ReelablesAsset1.d.mts +3 -0
  118. package/dist/esm/api/types/ReelablesAssetPausedTimeWindow1.d.mts +7 -0
  119. package/dist/esm/api/types/ReelablesAssetPausedTimeWindow1.mjs +4 -0
  120. package/dist/esm/api/types/ReelablesDataPointMetadata1.d.mts +1 -0
  121. package/dist/esm/api/types/Task1.d.mts +2 -0
  122. package/dist/esm/api/types/TaskArtifact1.d.mts +2 -0
  123. package/dist/esm/api/types/TaskExpanded.d.mts +2 -0
  124. package/dist/esm/api/types/UserPrivateData1.d.mts +1 -0
  125. package/dist/esm/api/types/index.d.mts +5 -0
  126. package/dist/esm/api/types/index.mjs +5 -0
  127. package/dist/esm/version.d.mts +1 -1
  128. package/dist/esm/version.mjs +1 -1
  129. package/package.json +1 -1
  130. package/reference.md +411 -2
@@ -175,6 +175,8 @@ __exportStar(require("./CreateInvoiceLineItemsFromLineItemsRes.js"), exports);
175
175
  __exportStar(require("./CreateOffChrtOrgRes.js"), exports);
176
176
  __exportStar(require("./CreateStripeConnectAccountRes.js"), exports);
177
177
  __exportStar(require("./CredentialInfoRes.js"), exports);
178
+ __exportStar(require("./CustodyParty1.js"), exports);
179
+ __exportStar(require("./CustodyPartyExpanded.js"), exports);
178
180
  __exportStar(require("./CxtAuthTypeEnum1.js"), exports);
179
181
  __exportStar(require("./CxtCredsLimited1.js"), exports);
180
182
  __exportStar(require("./CxtCredsListRes.js"), exports);
@@ -270,6 +272,8 @@ __exportStar(require("./InternalDelegationJwtRes.js"), exports);
270
272
  __exportStar(require("./Invoice1.js"), exports);
271
273
  __exportStar(require("./InvoiceExpandedListItem.js"), exports);
272
274
  __exportStar(require("./InvoiceExpandedRes.js"), exports);
275
+ __exportStar(require("./InvoiceExportListItem.js"), exports);
276
+ __exportStar(require("./InvoiceExportListRes.js"), exports);
273
277
  __exportStar(require("./InvoiceLineItem1.js"), exports);
274
278
  __exportStar(require("./InvoiceLineItemAmountTransformation1.js"), exports);
275
279
  __exportStar(require("./InvoiceLineItemAmountTransformationTypeEnum1.js"), exports);
@@ -456,6 +460,7 @@ __exportStar(require("./ProFormaLineItem1.js"), exports);
456
460
  __exportStar(require("./ProFormaLineItemProvenanceEnum1.js"), exports);
457
461
  __exportStar(require("./ReelablesAsset1.js"), exports);
458
462
  __exportStar(require("./ReelablesAssetListRes.js"), exports);
463
+ __exportStar(require("./ReelablesAssetPausedTimeWindow1.js"), exports);
459
464
  __exportStar(require("./ReelablesAssetSortByEnum.js"), exports);
460
465
  __exportStar(require("./ReelablesDataPoint1.js"), exports);
461
466
  __exportStar(require("./ReelablesDataPointMetadata1.js"), exports);
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.961.0";
1
+ export declare const SDK_VERSION = "1.963.0";
@@ -1,4 +1,4 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SDK_VERSION = void 0;
4
- exports.SDK_VERSION = "1.961.0";
4
+ exports.SDK_VERSION = "1.963.0";
@@ -24,8 +24,8 @@ export class ChrtClient {
24
24
  this._options = Object.assign(Object.assign({}, _options), { headers: mergeHeaders({
25
25
  "X-Fern-Language": "JavaScript",
26
26
  "X-Fern-SDK-Name": "@chrt-inc/typescript-sdk",
27
- "X-Fern-SDK-Version": "1.961.0",
28
- "User-Agent": "@chrt-inc/typescript-sdk/1.961.0",
27
+ "X-Fern-SDK-Version": "1.963.0",
28
+ "User-Agent": "@chrt-inc/typescript-sdk/1.963.0",
29
29
  "X-Fern-Runtime": core.RUNTIME.type,
30
30
  "X-Fern-Runtime-Version": core.RUNTIME.version,
31
31
  }, _options === null || _options === void 0 ? void 0 : _options.headers) });
@@ -4,6 +4,7 @@
4
4
  import * as environments from "../../../../../../environments.mjs";
5
5
  import * as core from "../../../../../../core/index.mjs";
6
6
  import * as Chrt from "../../../../../index.mjs";
7
+ import { Export } from "../resources/export/client/Client.mjs";
7
8
  export declare namespace Invoices {
8
9
  interface Options {
9
10
  environment?: core.Supplier<environments.ChrtEnvironment | string>;
@@ -29,7 +30,9 @@ export declare namespace Invoices {
29
30
  }
30
31
  export declare class Invoices {
31
32
  protected readonly _options: Invoices.Options;
33
+ protected _export: Export | undefined;
32
34
  constructor(_options?: Invoices.Options);
35
+ get export(): Export;
33
36
  /**
34
37
  * Approves a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
35
38
  *
@@ -15,10 +15,15 @@ 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
+ import { Export } from "../resources/export/client/Client.mjs";
18
19
  export class Invoices {
19
20
  constructor(_options = {}) {
20
21
  this._options = _options;
21
22
  }
23
+ get export() {
24
+ var _a;
25
+ return ((_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Export(this._options)));
26
+ }
22
27
  /**
23
28
  * Approves a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
24
29
  *
@@ -1 +1,2 @@
1
1
  export * from "./client/index.mjs";
2
+ export * from "./resources/index.mjs";
@@ -1 +1,2 @@
1
1
  export * from "./client/index.mjs";
2
+ export * from "./resources/index.mjs";
@@ -0,0 +1,51 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as environments from "../../../../../../../../environments.mjs";
5
+ import * as core from "../../../../../../../../core/index.mjs";
6
+ import * as Chrt from "../../../../../../../index.mjs";
7
+ export declare namespace Export {
8
+ interface Options {
9
+ environment?: core.Supplier<environments.ChrtEnvironment | string>;
10
+ /** Specify a custom URL to connect the client to. */
11
+ baseUrl?: core.Supplier<string>;
12
+ token?: core.Supplier<core.BearerToken | undefined>;
13
+ /** Additional headers to include in requests. */
14
+ headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
15
+ fetcher?: core.FetchFunction;
16
+ }
17
+ interface RequestOptions {
18
+ /** The maximum time to wait for a response in seconds. */
19
+ timeoutInSeconds?: number;
20
+ /** The number of times to retry the request. Defaults to 2. */
21
+ maxRetries?: number;
22
+ /** A hook to abort the request. */
23
+ abortSignal?: AbortSignal;
24
+ /** Additional query string parameters to include in the request. */
25
+ queryParams?: Record<string, unknown>;
26
+ /** Additional headers to include in the request. */
27
+ headers?: Record<string, string | core.Supplier<string | null | undefined> | null | undefined>;
28
+ }
29
+ }
30
+ export declare class Export {
31
+ protected readonly _options: Export.Options;
32
+ constructor(_options?: Export.Options);
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)
35
+ *
36
+ * @param {string} invoiceId
37
+ * @param {Chrt.billingNew.invoices.ExportListV1Request} request
38
+ * @param {Export.RequestOptions} requestOptions - Request-specific configuration.
39
+ *
40
+ * @throws {@link Chrt.UnprocessableEntityError}
41
+ *
42
+ * @example
43
+ * await client.billingNew.invoices.export.listV1("invoice_id", {
44
+ * page: 1,
45
+ * page_size: 1
46
+ * })
47
+ */
48
+ listV1(invoiceId: string, request?: Chrt.billingNew.invoices.ExportListV1Request, requestOptions?: Export.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceExportListRes>;
49
+ private __listV1;
50
+ protected _getAuthorizationHeader(): Promise<string | undefined>;
51
+ }
@@ -0,0 +1,102 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
5
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
6
+ return new (P || (P = Promise))(function (resolve, reject) {
7
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
8
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
9
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
10
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
11
+ });
12
+ };
13
+ import * as environments from "../../../../../../../../environments.mjs";
14
+ import * as core from "../../../../../../../../core/index.mjs";
15
+ import * as Chrt from "../../../../../../../index.mjs";
16
+ import { mergeHeaders, mergeOnlyDefinedHeaders } from "../../../../../../../../core/headers.mjs";
17
+ import * as errors from "../../../../../../../../errors/index.mjs";
18
+ export class Export {
19
+ constructor(_options = {}) {
20
+ this._options = _options;
21
+ }
22
+ /**
23
+ * 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)
24
+ *
25
+ * @param {string} invoiceId
26
+ * @param {Chrt.billingNew.invoices.ExportListV1Request} request
27
+ * @param {Export.RequestOptions} requestOptions - Request-specific configuration.
28
+ *
29
+ * @throws {@link Chrt.UnprocessableEntityError}
30
+ *
31
+ * @example
32
+ * await client.billingNew.invoices.export.listV1("invoice_id", {
33
+ * page: 1,
34
+ * page_size: 1
35
+ * })
36
+ */
37
+ listV1(invoiceId, request = {}, requestOptions) {
38
+ return core.HttpResponsePromise.fromPromise(this.__listV1(invoiceId, request, requestOptions));
39
+ }
40
+ __listV1(invoiceId_1) {
41
+ return __awaiter(this, arguments, void 0, function* (invoiceId, request = {}, requestOptions) {
42
+ var _a, _b, _c, _d, _e, _f;
43
+ const { page, page_size: pageSize } = request;
44
+ const _queryParams = {};
45
+ if (page !== undefined) {
46
+ _queryParams["page"] = (_a = page === null || page === void 0 ? void 0 : page.toString()) !== null && _a !== void 0 ? _a : null;
47
+ }
48
+ if (pageSize !== undefined) {
49
+ _queryParams["page_size"] = (_b = pageSize === null || pageSize === void 0 ? void 0 : pageSize.toString()) !== null && _b !== void 0 ? _b : null;
50
+ }
51
+ let _headers = mergeHeaders((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
52
+ const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
53
+ url: core.url.join((_f = (_e = (yield core.Supplier.get(this._options.baseUrl))) !== null && _e !== void 0 ? _e : (yield core.Supplier.get(this._options.environment))) !== null && _f !== void 0 ? _f : environments.ChrtEnvironment.Local, `billing_new/invoices/export/list/v1/${encodeURIComponent(invoiceId)}`),
54
+ method: "GET",
55
+ headers: _headers,
56
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
57
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
58
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
59
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
60
+ });
61
+ if (_response.ok) {
62
+ return { data: _response.body, rawResponse: _response.rawResponse };
63
+ }
64
+ if (_response.error.reason === "status-code") {
65
+ switch (_response.error.statusCode) {
66
+ case 422:
67
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
68
+ default:
69
+ throw new errors.ChrtError({
70
+ statusCode: _response.error.statusCode,
71
+ body: _response.error.body,
72
+ rawResponse: _response.rawResponse,
73
+ });
74
+ }
75
+ }
76
+ switch (_response.error.reason) {
77
+ case "non-json":
78
+ throw new errors.ChrtError({
79
+ statusCode: _response.error.statusCode,
80
+ body: _response.error.rawBody,
81
+ rawResponse: _response.rawResponse,
82
+ });
83
+ case "timeout":
84
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /billing_new/invoices/export/list/v1/{invoice_id}.");
85
+ case "unknown":
86
+ throw new errors.ChrtError({
87
+ message: _response.error.errorMessage,
88
+ rawResponse: _response.rawResponse,
89
+ });
90
+ }
91
+ });
92
+ }
93
+ _getAuthorizationHeader() {
94
+ return __awaiter(this, void 0, void 0, function* () {
95
+ const bearer = yield core.Supplier.get(this._options.token);
96
+ if (bearer != null) {
97
+ return `Bearer ${bearer}`;
98
+ }
99
+ return undefined;
100
+ });
101
+ }
102
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ export * from "./requests/index.mjs";
@@ -0,0 +1 @@
1
+ export * from "./requests/index.mjs";
@@ -0,0 +1,14 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * @example
6
+ * {
7
+ * page: 1,
8
+ * page_size: 1
9
+ * }
10
+ */
11
+ export interface ExportListV1Request {
12
+ page?: number | null;
13
+ page_size?: number | null;
14
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export {};
@@ -0,0 +1 @@
1
+ export { type ExportListV1Request } from "./ExportListV1Request.mjs";
@@ -0,0 +1 @@
1
+ export * from "./client/index.mjs";
@@ -0,0 +1 @@
1
+ export * from "./client/index.mjs";
@@ -0,0 +1,2 @@
1
+ export * as export_ from "./export/index.mjs";
2
+ export * from "./export/client/requests/index.mjs";
@@ -0,0 +1,2 @@
1
+ export * as export_ from "./export/index.mjs";
2
+ export * from "./export/client/requests/index.mjs";
@@ -10,5 +10,6 @@ export * from "./drivers/client/requests/index.mjs";
10
10
  export * from "./flights/client/requests/index.mjs";
11
11
  export * from "./orderTemplatesNew/client/requests/index.mjs";
12
12
  export * from "./orders/client/requests/index.mjs";
13
+ export * from "./taskArtifacts/client/requests/index.mjs";
13
14
  export * from "./taskGroups/client/requests/index.mjs";
14
15
  export * from "./tasks/client/requests/index.mjs";
@@ -10,5 +10,6 @@ export * from "./drivers/client/requests/index.mjs";
10
10
  export * from "./flights/client/requests/index.mjs";
11
11
  export * from "./orderTemplatesNew/client/requests/index.mjs";
12
12
  export * from "./orders/client/requests/index.mjs";
13
+ export * from "./taskArtifacts/client/requests/index.mjs";
13
14
  export * from "./taskGroups/client/requests/index.mjs";
14
15
  export * from "./tasks/client/requests/index.mjs";
@@ -31,7 +31,7 @@ export declare class OrderEvents {
31
31
  protected readonly _options: OrderEvents.Options;
32
32
  constructor(_options?: OrderEvents.Options);
33
33
  /**
34
- * Lists event log entries for an order with organization and user public data hydrated, filtering, sorting, and pagination. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventListRes)
34
+ * Lists event log entries for an order with organization and user display data hydrated, filtering, sorting, and pagination. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventListRes)
35
35
  *
36
36
  * @param {string} orderId
37
37
  * @param {Chrt.shipping.orders.OrderEventsListV1Request} request
@@ -55,7 +55,7 @@ export declare class OrderEvents {
55
55
  listV1(orderId: string, request?: Chrt.shipping.orders.OrderEventsListV1Request, requestOptions?: OrderEvents.RequestOptions): core.HttpResponsePromise<Chrt.OrderEventListRes>;
56
56
  private __listV1;
57
57
  /**
58
- * Retrieves a single order event log entry by its ID with organization and user public data hydrated. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventExpanded1)
58
+ * Retrieves a single order event log entry by its ID with organization and user name hydrated. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventExpanded1)
59
59
  *
60
60
  * @param {string} orderEventId
61
61
  * @param {OrderEvents.RequestOptions} requestOptions - Request-specific configuration.
@@ -20,7 +20,7 @@ export class OrderEvents {
20
20
  this._options = _options;
21
21
  }
22
22
  /**
23
- * Lists event log entries for an order with organization and user public data hydrated, filtering, sorting, and pagination. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventListRes)
23
+ * Lists event log entries for an order with organization and user display data hydrated, filtering, sorting, and pagination. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventListRes)
24
24
  *
25
25
  * @param {string} orderId
26
26
  * @param {Chrt.shipping.orders.OrderEventsListV1Request} request
@@ -124,7 +124,7 @@ export class OrderEvents {
124
124
  });
125
125
  }
126
126
  /**
127
- * Retrieves a single order event log entry by its ID with organization and user public data hydrated. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventExpanded1)
127
+ * Retrieves a single order event log entry by its ID with organization and user name hydrated. | authz: min_org_role=administrator | authz_personas=[draft_creator_org_operator, coordinator_org_operators] | () -> (OrderEventExpanded1)
128
128
  *
129
129
  * @param {string} orderEventId
130
130
  * @param {OrderEvents.RequestOptions} requestOptions - Request-specific configuration.
@@ -3,6 +3,7 @@
3
3
  */
4
4
  import * as environments from "../../../../../../environments.mjs";
5
5
  import * as core from "../../../../../../core/index.mjs";
6
+ import * as Chrt from "../../../../../index.mjs";
6
7
  import { S3Object } from "../resources/s3Object/client/Client.mjs";
7
8
  import { Scan } from "../resources/scan/client/Client.mjs";
8
9
  export declare namespace TaskArtifacts {
@@ -48,6 +49,20 @@ export declare class TaskArtifacts {
48
49
  */
49
50
  completeV1(taskArtifactId: string, requestOptions?: TaskArtifacts.RequestOptions): core.HttpResponsePromise<boolean>;
50
51
  private __completeV1;
52
+ /**
53
+ * Updates or clears the parties that provided or received cargo for a task artifact. Contact references must belong to the caller's organization. | authz_personas=[draft_creator_org_operator, driver_for_executor, executor_org_operators, coordinator_org_operators] (depending on status) | (TaskArtifactCustodyPartiesUpdateReq) -> (bool)
54
+ *
55
+ * @param {string} taskArtifactId
56
+ * @param {Chrt.shipping.TaskArtifactCustodyPartiesUpdateReq} request
57
+ * @param {TaskArtifacts.RequestOptions} requestOptions - Request-specific configuration.
58
+ *
59
+ * @throws {@link Chrt.UnprocessableEntityError}
60
+ *
61
+ * @example
62
+ * await client.shipping.taskArtifacts.updateCustodyPartiesV1("task_artifact_id")
63
+ */
64
+ updateCustodyPartiesV1(taskArtifactId: string, request?: Chrt.shipping.TaskArtifactCustodyPartiesUpdateReq, requestOptions?: TaskArtifacts.RequestOptions): core.HttpResponsePromise<boolean>;
65
+ private __updateCustodyPartiesV1;
51
66
  /**
52
67
  * Marks a task artifact as SKIPPED. | authz_personas=[driver_for_executor, executor_org_operators, coordinator_org_operators] | () -> (bool)
53
68
  *
@@ -88,6 +88,69 @@ export class TaskArtifacts {
88
88
  }
89
89
  });
90
90
  }
91
+ /**
92
+ * Updates or clears the parties that provided or received cargo for a task artifact. Contact references must belong to the caller's organization. | authz_personas=[draft_creator_org_operator, driver_for_executor, executor_org_operators, coordinator_org_operators] (depending on status) | (TaskArtifactCustodyPartiesUpdateReq) -> (bool)
93
+ *
94
+ * @param {string} taskArtifactId
95
+ * @param {Chrt.shipping.TaskArtifactCustodyPartiesUpdateReq} request
96
+ * @param {TaskArtifacts.RequestOptions} requestOptions - Request-specific configuration.
97
+ *
98
+ * @throws {@link Chrt.UnprocessableEntityError}
99
+ *
100
+ * @example
101
+ * await client.shipping.taskArtifacts.updateCustodyPartiesV1("task_artifact_id")
102
+ */
103
+ updateCustodyPartiesV1(taskArtifactId, request = {}, requestOptions) {
104
+ return core.HttpResponsePromise.fromPromise(this.__updateCustodyPartiesV1(taskArtifactId, request, requestOptions));
105
+ }
106
+ __updateCustodyPartiesV1(taskArtifactId_1) {
107
+ return __awaiter(this, arguments, void 0, function* (taskArtifactId, request = {}, requestOptions) {
108
+ var _a, _b, _c, _d;
109
+ 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);
110
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
111
+ 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/task_artifacts/custody_parties/update/v1/${encodeURIComponent(taskArtifactId)}`),
112
+ method: "PATCH",
113
+ headers: _headers,
114
+ contentType: "application/json",
115
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
116
+ requestType: "json",
117
+ body: request,
118
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
119
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
120
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
121
+ });
122
+ if (_response.ok) {
123
+ return { data: _response.body, rawResponse: _response.rawResponse };
124
+ }
125
+ if (_response.error.reason === "status-code") {
126
+ switch (_response.error.statusCode) {
127
+ case 422:
128
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
129
+ default:
130
+ throw new errors.ChrtError({
131
+ statusCode: _response.error.statusCode,
132
+ body: _response.error.body,
133
+ rawResponse: _response.rawResponse,
134
+ });
135
+ }
136
+ }
137
+ switch (_response.error.reason) {
138
+ case "non-json":
139
+ throw new errors.ChrtError({
140
+ statusCode: _response.error.statusCode,
141
+ body: _response.error.rawBody,
142
+ rawResponse: _response.rawResponse,
143
+ });
144
+ case "timeout":
145
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /shipping/task_artifacts/custody_parties/update/v1/{task_artifact_id}.");
146
+ case "unknown":
147
+ throw new errors.ChrtError({
148
+ message: _response.error.errorMessage,
149
+ rawResponse: _response.rawResponse,
150
+ });
151
+ }
152
+ });
153
+ }
91
154
  /**
92
155
  * Marks a task artifact as SKIPPED. | authz_personas=[driver_for_executor, executor_org_operators, coordinator_org_operators] | () -> (bool)
93
156
  *
@@ -1 +1,2 @@
1
1
  export {};
2
+ export * from "./requests/index.mjs";
@@ -1 +1 @@
1
- export {};
1
+ export * from "./requests/index.mjs";
@@ -0,0 +1,14 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../../../../../../index.mjs";
5
+ /**
6
+ * @example
7
+ * {}
8
+ */
9
+ export interface TaskArtifactCustodyPartiesUpdateReq {
10
+ provided_by?: Chrt.CustodyParty1 | null;
11
+ provided_by__set_to_None?: boolean;
12
+ received_by?: Chrt.CustodyParty1 | null;
13
+ received_by__set_to_None?: boolean;
14
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export {};
@@ -0,0 +1 @@
1
+ export { type TaskArtifactCustodyPartiesUpdateReq } from "./TaskArtifactCustodyPartiesUpdateReq.mjs";
@@ -77,6 +77,20 @@ export declare class Tasks {
77
77
  */
78
78
  updateCompletionTimestampV1(taskId: string, request: Chrt.shipping.TaskCompletionTimestampUpdateReq, requestOptions?: Tasks.RequestOptions): core.HttpResponsePromise<boolean>;
79
79
  private __updateCompletionTimestampV1;
80
+ /**
81
+ * Updates or clears the parties that provided or received cargo for a task. Contact references must belong to the caller's organization. | authz_personas=[draft_creator_org_operator, driver_for_executor, executor_org_operators, coordinator_org_operators] (depending on status) | (TaskCustodyPartiesUpdateReq) -> (bool)
82
+ *
83
+ * @param {string} taskId
84
+ * @param {Chrt.shipping.TaskCustodyPartiesUpdateReq} request
85
+ * @param {Tasks.RequestOptions} requestOptions - Request-specific configuration.
86
+ *
87
+ * @throws {@link Chrt.UnprocessableEntityError}
88
+ *
89
+ * @example
90
+ * await client.shipping.tasks.updateCustodyPartiesV1("task_id")
91
+ */
92
+ updateCustodyPartiesV1(taskId: string, request?: Chrt.shipping.TaskCustodyPartiesUpdateReq, requestOptions?: Tasks.RequestOptions): core.HttpResponsePromise<boolean>;
93
+ private __updateCustodyPartiesV1;
80
94
  /**
81
95
  * Overrides a draft or staged task location from a contact or coordinator shipper account and associates the reference. | authz_personas=[draft_creator_org_operator, order_creator_org_operators, task_group_operating_org_operators, coordinator_org_operators] | (TaskLocationFromReferenceReq) -> (PydanticObjectId)
82
96
  *
@@ -215,6 +215,69 @@ export class Tasks {
215
215
  }
216
216
  });
217
217
  }
218
+ /**
219
+ * Updates or clears the parties that provided or received cargo for a task. Contact references must belong to the caller's organization. | authz_personas=[draft_creator_org_operator, driver_for_executor, executor_org_operators, coordinator_org_operators] (depending on status) | (TaskCustodyPartiesUpdateReq) -> (bool)
220
+ *
221
+ * @param {string} taskId
222
+ * @param {Chrt.shipping.TaskCustodyPartiesUpdateReq} request
223
+ * @param {Tasks.RequestOptions} requestOptions - Request-specific configuration.
224
+ *
225
+ * @throws {@link Chrt.UnprocessableEntityError}
226
+ *
227
+ * @example
228
+ * await client.shipping.tasks.updateCustodyPartiesV1("task_id")
229
+ */
230
+ updateCustodyPartiesV1(taskId, request = {}, requestOptions) {
231
+ return core.HttpResponsePromise.fromPromise(this.__updateCustodyPartiesV1(taskId, request, requestOptions));
232
+ }
233
+ __updateCustodyPartiesV1(taskId_1) {
234
+ return __awaiter(this, arguments, void 0, function* (taskId, request = {}, requestOptions) {
235
+ var _a, _b, _c, _d;
236
+ 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);
237
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
238
+ 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/tasks/custody_parties/update/v1/${encodeURIComponent(taskId)}`),
239
+ method: "PATCH",
240
+ headers: _headers,
241
+ contentType: "application/json",
242
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
243
+ requestType: "json",
244
+ body: request,
245
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
246
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
247
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
248
+ });
249
+ if (_response.ok) {
250
+ return { data: _response.body, rawResponse: _response.rawResponse };
251
+ }
252
+ if (_response.error.reason === "status-code") {
253
+ switch (_response.error.statusCode) {
254
+ case 422:
255
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
256
+ default:
257
+ throw new errors.ChrtError({
258
+ statusCode: _response.error.statusCode,
259
+ body: _response.error.body,
260
+ rawResponse: _response.rawResponse,
261
+ });
262
+ }
263
+ }
264
+ switch (_response.error.reason) {
265
+ case "non-json":
266
+ throw new errors.ChrtError({
267
+ statusCode: _response.error.statusCode,
268
+ body: _response.error.rawBody,
269
+ rawResponse: _response.rawResponse,
270
+ });
271
+ case "timeout":
272
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling PATCH /shipping/tasks/custody_parties/update/v1/{task_id}.");
273
+ case "unknown":
274
+ throw new errors.ChrtError({
275
+ message: _response.error.errorMessage,
276
+ rawResponse: _response.rawResponse,
277
+ });
278
+ }
279
+ });
280
+ }
218
281
  /**
219
282
  * Overrides a draft or staged task location from a contact or coordinator shipper account and associates the reference. | authz_personas=[draft_creator_org_operator, order_creator_org_operators, task_group_operating_org_operators, coordinator_org_operators] | (TaskLocationFromReferenceReq) -> (PydanticObjectId)
220
283
  *
@@ -0,0 +1,14 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../../../../../../index.mjs";
5
+ /**
6
+ * @example
7
+ * {}
8
+ */
9
+ export interface TaskCustodyPartiesUpdateReq {
10
+ provided_by?: Chrt.CustodyParty1 | null;
11
+ provided_by__set_to_None?: boolean;
12
+ received_by?: Chrt.CustodyParty1 | null;
13
+ received_by__set_to_None?: boolean;
14
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export {};
@@ -1,5 +1,6 @@
1
1
  export { type AttemptTaskReq } from "./AttemptTaskReq.mjs";
2
2
  export { type TaskCompleteReq } from "./TaskCompleteReq.mjs";
3
3
  export { type TaskCompletionTimestampUpdateReq } from "./TaskCompletionTimestampUpdateReq.mjs";
4
+ export { type TaskCustodyPartiesUpdateReq } from "./TaskCustodyPartiesUpdateReq.mjs";
4
5
  export { type TaskLocationFromReferenceReq } from "./TaskLocationFromReferenceReq.mjs";
5
6
  export { type WaitTimeOverrideReq } from "./WaitTimeOverrideReq.mjs";