@chrt-inc/typescript-sdk 1.982.0 → 1.984.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 (66) hide show
  1. package/dist/cjs/Client.js +2 -2
  2. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.ts +4 -1
  3. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.js +6 -1
  4. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemClientUpdate1.d.ts +2 -0
  5. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/index.d.ts +1 -0
  6. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/index.js +1 -0
  7. package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.d.ts +6 -6
  8. package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.js +27 -13
  9. package/dist/cjs/api/resources/billingNew/resources/{invoices/resources/export/client/requests/ExportListV1Request.d.ts → invoiceLineItems/resources/export/client/requests/InvoiceLineItemExportListReq.d.ts} +4 -2
  10. package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/requests/index.d.ts +1 -0
  11. package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.d.ts +0 -3
  12. package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.js +0 -5
  13. package/dist/cjs/api/resources/billingNew/resources/invoices/index.d.ts +0 -1
  14. package/dist/cjs/api/resources/billingNew/resources/invoices/index.js +0 -1
  15. package/dist/cjs/api/types/InvoiceLineItemExportListItem.d.ts +50 -0
  16. package/dist/cjs/api/types/{InvoiceExportListRes.d.ts → InvoiceLineItemExportListRes.d.ts} +2 -2
  17. package/dist/cjs/api/types/index.d.ts +2 -2
  18. package/dist/cjs/api/types/index.js +2 -2
  19. package/dist/cjs/version.d.ts +1 -1
  20. package/dist/cjs/version.js +1 -1
  21. package/dist/esm/Client.mjs +2 -2
  22. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.mts +4 -1
  23. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.mjs +6 -1
  24. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemClientUpdate1.d.mts +2 -0
  25. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/index.d.mts +1 -0
  26. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/index.mjs +1 -0
  27. package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.d.mts +6 -6
  28. package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.mjs +27 -13
  29. package/dist/esm/api/resources/billingNew/resources/{invoices/resources/export/client/requests/ExportListV1Request.d.mts → invoiceLineItems/resources/export/client/requests/InvoiceLineItemExportListReq.d.mts} +4 -2
  30. package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/requests/index.d.mts +1 -0
  31. package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.d.mts +0 -3
  32. package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.mjs +0 -5
  33. package/dist/esm/api/resources/billingNew/resources/invoices/index.d.mts +0 -1
  34. package/dist/esm/api/resources/billingNew/resources/invoices/index.mjs +0 -1
  35. package/dist/esm/api/types/InvoiceLineItemExportListItem.d.mts +50 -0
  36. package/dist/esm/api/types/{InvoiceExportListRes.d.mts → InvoiceLineItemExportListRes.d.mts} +2 -2
  37. package/dist/esm/api/types/index.d.mts +2 -2
  38. package/dist/esm/api/types/index.mjs +2 -2
  39. package/dist/esm/version.d.mts +1 -1
  40. package/dist/esm/version.mjs +1 -1
  41. package/package.json +1 -1
  42. package/reference.md +7 -14
  43. package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.d.ts +0 -1
  44. package/dist/cjs/api/types/InvoiceExportListItem.d.ts +0 -46
  45. package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.d.mts +0 -1
  46. package/dist/esm/api/types/InvoiceExportListItem.d.mts +0 -46
  47. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.d.ts +0 -0
  48. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.js +0 -0
  49. /package/dist/cjs/api/resources/billingNew/resources/{invoices/resources/export/client/requests/ExportListV1Request.js → invoiceLineItems/resources/export/client/requests/InvoiceLineItemExportListReq.js} +0 -0
  50. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/requests/index.js +0 -0
  51. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.d.ts +0 -0
  52. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.js +0 -0
  53. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.d.ts +0 -0
  54. /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.js +0 -0
  55. /package/dist/cjs/api/types/{InvoiceExportListItem.js → InvoiceLineItemExportListItem.js} +0 -0
  56. /package/dist/cjs/api/types/{InvoiceExportListRes.js → InvoiceLineItemExportListRes.js} +0 -0
  57. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.d.mts +0 -0
  58. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.mjs +0 -0
  59. /package/dist/esm/api/resources/billingNew/resources/{invoices/resources/export/client/requests/ExportListV1Request.mjs → invoiceLineItems/resources/export/client/requests/InvoiceLineItemExportListReq.mjs} +0 -0
  60. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/requests/index.mjs +0 -0
  61. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.d.mts +0 -0
  62. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.mjs +0 -0
  63. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.d.mts +0 -0
  64. /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.mjs +0 -0
  65. /package/dist/esm/api/types/{InvoiceExportListItem.mjs → InvoiceLineItemExportListItem.mjs} +0 -0
  66. /package/dist/esm/api/types/{InvoiceExportListRes.mjs → InvoiceLineItemExportListRes.mjs} +0 -0
@@ -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.982.0",
64
- "User-Agent": "@chrt-inc/typescript-sdk/1.982.0",
63
+ "X-Fern-SDK-Version": "1.984.0",
64
+ "User-Agent": "@chrt-inc/typescript-sdk/1.984.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) });
@@ -4,6 +4,7 @@
4
4
  import * as environments from "../../../../../../environments.js";
5
5
  import * as core from "../../../../../../core/index.js";
6
6
  import * as Chrt from "../../../../../index.js";
7
+ import { Export } from "../resources/export/client/Client.js";
7
8
  export declare namespace InvoiceLineItems {
8
9
  interface Options {
9
10
  environment?: core.Supplier<environments.ChrtEnvironment | string>;
@@ -29,7 +30,9 @@ export declare namespace InvoiceLineItems {
29
30
  }
30
31
  export declare class InvoiceLineItems {
31
32
  protected readonly _options: InvoiceLineItems.Options;
33
+ protected _export: Export | undefined;
32
34
  constructor(_options?: InvoiceLineItems.Options);
35
+ get export(): Export;
33
36
  /**
34
37
  * Creates account-split ad-hoc line items and attaches them to matching draft invoices. | authz: allowed_org_types=[provider], min_org_role=operator | (AdHocInvoiceLineItemsReq) -> (list[InvoiceLineItem1])
35
38
  *
@@ -317,7 +320,7 @@ export declare class InvoiceLineItems {
317
320
  updateCurrencyConversionManyV1(request: Chrt.billingNew.InvoiceLineItemsCurrencyConversionUpdateManyReq, requestOptions?: InvoiceLineItems.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItem1[]>;
318
321
  private __updateCurrencyConversionManyV1;
319
322
  /**
320
- * 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)
323
+ * Updates an owner-scoped line item's source fields, including its caller-owned shipper account when not rate-sheet-derived, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
321
324
  *
322
325
  * @param {string} invoiceLineItemId
323
326
  * @param {Chrt.billingNew.InvoiceLineItemClientUpdate1} request
@@ -51,10 +51,15 @@ const core = __importStar(require("../../../../../../core/index.js"));
51
51
  const Chrt = __importStar(require("../../../../../index.js"));
52
52
  const headers_js_1 = require("../../../../../../core/headers.js");
53
53
  const errors = __importStar(require("../../../../../../errors/index.js"));
54
+ const Client_js_1 = require("../resources/export/client/Client.js");
54
55
  class InvoiceLineItems {
55
56
  constructor(_options = {}) {
56
57
  this._options = _options;
57
58
  }
59
+ get export() {
60
+ var _a;
61
+ return ((_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Client_js_1.Export(this._options)));
62
+ }
58
63
  /**
59
64
  * Creates account-split ad-hoc line items and attaches them to matching draft invoices. | authz: allowed_org_types=[provider], min_org_role=operator | (AdHocInvoiceLineItemsReq) -> (list[InvoiceLineItem1])
60
65
  *
@@ -1122,7 +1127,7 @@ class InvoiceLineItems {
1122
1127
  });
1123
1128
  }
1124
1129
  /**
1125
- * 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)
1130
+ * Updates an owner-scoped line item's source fields, including its caller-owned shipper account when not rate-sheet-derived, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
1126
1131
  *
1127
1132
  * @param {string} invoiceLineItemId
1128
1133
  * @param {Chrt.billingNew.InvoiceLineItemClientUpdate1} request
@@ -12,6 +12,8 @@ export interface InvoiceLineItemClientUpdate1 {
12
12
  export_ref__sage__item_id__set_to_None?: boolean;
13
13
  invoice_type?: Chrt.InvoiceTypeEnum1 | null;
14
14
  quantity?: number | null;
15
+ shipper_account_id?: string | null;
16
+ shipper_account_id__set_to_None?: boolean;
15
17
  source_currency_code?: Chrt.BillingCurrencyCodeEnum1 | null;
16
18
  source_unit_price?: number | null;
17
19
  unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
@@ -1 +1,2 @@
1
1
  export * from "./client/index.js";
2
+ export * from "./resources/index.js";
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./client/index.js"), exports);
18
+ __exportStar(require("./resources/index.js"), exports);
@@ -31,21 +31,21 @@ 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 accounts-receivable invoice owned by the caller's organization, regardless of invoice status. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExportListRes)
34
+ * Lists up to 1,000 accounts-receivable and accounts-payable line items for the selected Orders, with shipment context. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemExportListReq) -> (InvoiceLineItemExportListRes)
35
35
  *
36
- * @param {string} invoiceId
37
- * @param {Chrt.billingNew.invoices.ExportListV1Request} request
36
+ * @param {Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq} request
38
37
  * @param {Export.RequestOptions} requestOptions - Request-specific configuration.
39
38
  *
40
39
  * @throws {@link Chrt.UnprocessableEntityError}
41
40
  *
42
41
  * @example
43
- * await client.billingNew.invoices.export.listV1("invoice_id", {
42
+ * await client.billingNew.invoiceLineItems.export.listV1({
44
43
  * page: 1,
45
- * page_size: 1
44
+ * page_size: 1,
45
+ * order_ids: ["order_ids"]
46
46
  * })
47
47
  */
48
- listV1(invoiceId: string, request?: Chrt.billingNew.invoices.ExportListV1Request, requestOptions?: Export.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceExportListRes>;
48
+ listV1(request: Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq, requestOptions?: Export.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItemExportListRes>;
49
49
  private __listV1;
50
50
  protected _getAuthorizationHeader(): Promise<string | undefined>;
51
51
  }
@@ -44,6 +44,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
44
44
  step((generator = generator.apply(thisArg, _arguments || [])).next());
45
45
  });
46
46
  };
47
+ var __rest = (this && this.__rest) || function (s, e) {
48
+ var t = {};
49
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
50
+ t[p] = s[p];
51
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
52
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
53
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
54
+ t[p[i]] = s[p[i]];
55
+ }
56
+ return t;
57
+ };
47
58
  Object.defineProperty(exports, "__esModule", { value: true });
48
59
  exports.Export = void 0;
49
60
  const environments = __importStar(require("../../../../../../../../environments.js"));
@@ -56,27 +67,27 @@ class Export {
56
67
  this._options = _options;
57
68
  }
58
69
  /**
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)
70
+ * Lists up to 1,000 accounts-receivable and accounts-payable line items for the selected Orders, with shipment context. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemExportListReq) -> (InvoiceLineItemExportListRes)
60
71
  *
61
- * @param {string} invoiceId
62
- * @param {Chrt.billingNew.invoices.ExportListV1Request} request
72
+ * @param {Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq} request
63
73
  * @param {Export.RequestOptions} requestOptions - Request-specific configuration.
64
74
  *
65
75
  * @throws {@link Chrt.UnprocessableEntityError}
66
76
  *
67
77
  * @example
68
- * await client.billingNew.invoices.export.listV1("invoice_id", {
78
+ * await client.billingNew.invoiceLineItems.export.listV1({
69
79
  * page: 1,
70
- * page_size: 1
80
+ * page_size: 1,
81
+ * order_ids: ["order_ids"]
71
82
  * })
72
83
  */
73
- listV1(invoiceId, request = {}, requestOptions) {
74
- return core.HttpResponsePromise.fromPromise(this.__listV1(invoiceId, request, requestOptions));
84
+ listV1(request, requestOptions) {
85
+ return core.HttpResponsePromise.fromPromise(this.__listV1(request, requestOptions));
75
86
  }
76
- __listV1(invoiceId_1) {
77
- return __awaiter(this, arguments, void 0, function* (invoiceId, request = {}, requestOptions) {
87
+ __listV1(request, requestOptions) {
88
+ return __awaiter(this, void 0, void 0, function* () {
78
89
  var _a, _b, _c, _d, _e, _f;
79
- const { page, page_size: pageSize } = request;
90
+ const { page, page_size: pageSize } = request, _body = __rest(request, ["page", "page_size"]);
80
91
  const _queryParams = {};
81
92
  if (page !== undefined) {
82
93
  _queryParams["page"] = (_a = page === null || page === void 0 ? void 0 : page.toString()) !== null && _a !== void 0 ? _a : null;
@@ -86,10 +97,13 @@ class Export {
86
97
  }
87
98
  let _headers = (0, headers_js_1.mergeHeaders)((_c = this._options) === null || _c === void 0 ? void 0 : _c.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
88
99
  const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
89
- 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)}`),
90
- method: "GET",
100
+ 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/invoice_line_items/export/list/v1"),
101
+ method: "POST",
91
102
  headers: _headers,
103
+ contentType: "application/json",
92
104
  queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
105
+ requestType: "json",
106
+ body: _body,
93
107
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
94
108
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
95
109
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -117,7 +131,7 @@ class Export {
117
131
  rawResponse: _response.rawResponse,
118
132
  });
119
133
  case "timeout":
120
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /billing_new/invoices/export/list/v1/{invoice_id}.");
134
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/invoice_line_items/export/list/v1.");
121
135
  case "unknown":
122
136
  throw new errors.ChrtError({
123
137
  message: _response.error.errorMessage,
@@ -5,10 +5,12 @@
5
5
  * @example
6
6
  * {
7
7
  * page: 1,
8
- * page_size: 1
8
+ * page_size: 1,
9
+ * order_ids: ["order_ids"]
9
10
  * }
10
11
  */
11
- export interface ExportListV1Request {
12
+ export interface InvoiceLineItemExportListReq {
12
13
  page?: number | null;
13
14
  page_size?: number | null;
15
+ order_ids: string[];
14
16
  }
@@ -0,0 +1 @@
1
+ export { type InvoiceLineItemExportListReq } from "./InvoiceLineItemExportListReq.js";
@@ -4,7 +4,6 @@
4
4
  import * as environments from "../../../../../../environments.js";
5
5
  import * as core from "../../../../../../core/index.js";
6
6
  import * as Chrt from "../../../../../index.js";
7
- import { Export } from "../resources/export/client/Client.js";
8
7
  export declare namespace Invoices {
9
8
  interface Options {
10
9
  environment?: core.Supplier<environments.ChrtEnvironment | string>;
@@ -30,9 +29,7 @@ export declare namespace Invoices {
30
29
  }
31
30
  export declare class Invoices {
32
31
  protected readonly _options: Invoices.Options;
33
- protected _export: Export | undefined;
34
32
  constructor(_options?: Invoices.Options);
35
- get export(): Export;
36
33
  /**
37
34
  * Approves a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
38
35
  *
@@ -51,15 +51,10 @@ const core = __importStar(require("../../../../../../core/index.js"));
51
51
  const Chrt = __importStar(require("../../../../../index.js"));
52
52
  const headers_js_1 = require("../../../../../../core/headers.js");
53
53
  const errors = __importStar(require("../../../../../../errors/index.js"));
54
- const Client_js_1 = require("../resources/export/client/Client.js");
55
54
  class Invoices {
56
55
  constructor(_options = {}) {
57
56
  this._options = _options;
58
57
  }
59
- get export() {
60
- var _a;
61
- return ((_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Client_js_1.Export(this._options)));
62
- }
63
58
  /**
64
59
  * Approves a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
65
60
  *
@@ -1,2 +1 @@
1
1
  export * from "./client/index.js";
2
- export * from "./resources/index.js";
@@ -15,4 +15,3 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./client/index.js"), exports);
18
- __exportStar(require("./resources/index.js"), exports);
@@ -0,0 +1,50 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../index.js";
5
+ export interface InvoiceLineItemExportListItem {
6
+ account_name?: string | null;
7
+ airlines?: string[];
8
+ awb_numbers?: string[];
9
+ billing_period_end_at_timestamp?: string | null;
10
+ billing_period_start_at_timestamp?: string | null;
11
+ cargo_descriptions?: string[];
12
+ cargo_quantity?: number | null;
13
+ cargo_types?: string[];
14
+ conversion_rate?: number | null;
15
+ counterparty_name?: string | null;
16
+ currency_code: Chrt.BillingCurrencyCodeEnum1;
17
+ currency_conversion_description?: string | null;
18
+ delivery_address?: string | null;
19
+ delivery_location_name?: string | null;
20
+ delivery_status?: string | null;
21
+ delivery_stop_number?: number | null;
22
+ delivery_stops_on_order?: number | null;
23
+ destination_iata?: string | null;
24
+ flight_numbers?: string[];
25
+ invoice_approval_timestamp?: string | null;
26
+ invoice_line_item_id: string;
27
+ invoice_line_item_status: Chrt.InvoiceLineItemStatusEnum1;
28
+ invoice_number?: string | null;
29
+ invoice_status?: Chrt.InvoiceStatusEnum1 | null;
30
+ invoice_type: Chrt.InvoiceTypeEnum1;
31
+ /** IATA Air Waybill number: 3-digit airline prefix + 8-digit serial, e.g. '020-12345678'. */
32
+ line_item_awb_number?: string | null;
33
+ line_item_description: string;
34
+ line_item_quantity: number;
35
+ line_item_total_amount: number;
36
+ line_item_type: Chrt.InvoiceLineItemTypeEnum1;
37
+ line_item_unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
38
+ line_item_unit_price: number;
39
+ mileage_estimated?: number | null;
40
+ off_chrt_reference_id?: string | null;
41
+ order_placer_comments?: string | null;
42
+ order_short_id?: string | null;
43
+ origin_iata?: string | null;
44
+ pod_at_timestamp?: string | null;
45
+ pod_name?: string | null;
46
+ source_currency_code?: Chrt.BillingCurrencyCodeEnum1 | null;
47
+ source_unit_price?: number | null;
48
+ tax_percentage?: number | null;
49
+ weight_pounds?: number | null;
50
+ }
@@ -2,7 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Chrt from "../index.js";
5
- export interface InvoiceExportListRes {
6
- items: Chrt.InvoiceExportListItem[];
5
+ export interface InvoiceLineItemExportListRes {
6
+ items: Chrt.InvoiceLineItemExportListItem[];
7
7
  total_count: number;
8
8
  }
@@ -256,8 +256,6 @@ export * from "./InternalDelegationJwtRes.js";
256
256
  export * from "./Invoice1.js";
257
257
  export * from "./InvoiceExpandedListItem.js";
258
258
  export * from "./InvoiceExpandedRes.js";
259
- export * from "./InvoiceExportListItem.js";
260
- export * from "./InvoiceExportListRes.js";
261
259
  export * from "./InvoiceLineItem1.js";
262
260
  export * from "./InvoiceLineItemAmountTransformation1.js";
263
261
  export * from "./InvoiceLineItemAmountTransformationTypeEnum1.js";
@@ -265,6 +263,8 @@ export * from "./InvoiceLineItemClientCreate1.js";
265
263
  export * from "./InvoiceLineItemCurrencyConversion1.js";
266
264
  export * from "./InvoiceLineItemExpandedListItem.js";
267
265
  export * from "./InvoiceLineItemExpandedRes.js";
266
+ export * from "./InvoiceLineItemExportListItem.js";
267
+ export * from "./InvoiceLineItemExportListRes.js";
268
268
  export * from "./InvoiceLineItemListRes.js";
269
269
  export * from "./InvoiceLineItemServerCreate1.js";
270
270
  export * from "./InvoiceLineItemSortByEnum.js";
@@ -272,8 +272,6 @@ __exportStar(require("./InternalDelegationJwtRes.js"), exports);
272
272
  __exportStar(require("./Invoice1.js"), exports);
273
273
  __exportStar(require("./InvoiceExpandedListItem.js"), exports);
274
274
  __exportStar(require("./InvoiceExpandedRes.js"), exports);
275
- __exportStar(require("./InvoiceExportListItem.js"), exports);
276
- __exportStar(require("./InvoiceExportListRes.js"), exports);
277
275
  __exportStar(require("./InvoiceLineItem1.js"), exports);
278
276
  __exportStar(require("./InvoiceLineItemAmountTransformation1.js"), exports);
279
277
  __exportStar(require("./InvoiceLineItemAmountTransformationTypeEnum1.js"), exports);
@@ -281,6 +279,8 @@ __exportStar(require("./InvoiceLineItemClientCreate1.js"), exports);
281
279
  __exportStar(require("./InvoiceLineItemCurrencyConversion1.js"), exports);
282
280
  __exportStar(require("./InvoiceLineItemExpandedListItem.js"), exports);
283
281
  __exportStar(require("./InvoiceLineItemExpandedRes.js"), exports);
282
+ __exportStar(require("./InvoiceLineItemExportListItem.js"), exports);
283
+ __exportStar(require("./InvoiceLineItemExportListRes.js"), exports);
284
284
  __exportStar(require("./InvoiceLineItemListRes.js"), exports);
285
285
  __exportStar(require("./InvoiceLineItemServerCreate1.js"), exports);
286
286
  __exportStar(require("./InvoiceLineItemSortByEnum.js"), exports);
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.982.0";
1
+ export declare const SDK_VERSION = "1.984.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.982.0";
4
+ exports.SDK_VERSION = "1.984.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.982.0",
28
- "User-Agent": "@chrt-inc/typescript-sdk/1.982.0",
27
+ "X-Fern-SDK-Version": "1.984.0",
28
+ "User-Agent": "@chrt-inc/typescript-sdk/1.984.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 InvoiceLineItems {
8
9
  interface Options {
9
10
  environment?: core.Supplier<environments.ChrtEnvironment | string>;
@@ -29,7 +30,9 @@ export declare namespace InvoiceLineItems {
29
30
  }
30
31
  export declare class InvoiceLineItems {
31
32
  protected readonly _options: InvoiceLineItems.Options;
33
+ protected _export: Export | undefined;
32
34
  constructor(_options?: InvoiceLineItems.Options);
35
+ get export(): Export;
33
36
  /**
34
37
  * Creates account-split ad-hoc line items and attaches them to matching draft invoices. | authz: allowed_org_types=[provider], min_org_role=operator | (AdHocInvoiceLineItemsReq) -> (list[InvoiceLineItem1])
35
38
  *
@@ -317,7 +320,7 @@ export declare class InvoiceLineItems {
317
320
  updateCurrencyConversionManyV1(request: Chrt.billingNew.InvoiceLineItemsCurrencyConversionUpdateManyReq, requestOptions?: InvoiceLineItems.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItem1[]>;
318
321
  private __updateCurrencyConversionManyV1;
319
322
  /**
320
- * 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)
323
+ * Updates an owner-scoped line item's source fields, including its caller-owned shipper account when not rate-sheet-derived, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
321
324
  *
322
325
  * @param {string} invoiceLineItemId
323
326
  * @param {Chrt.billingNew.InvoiceLineItemClientUpdate1} request
@@ -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 InvoiceLineItems {
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
  * Creates account-split ad-hoc line items and attaches them to matching draft invoices. | authz: allowed_org_types=[provider], min_org_role=operator | (AdHocInvoiceLineItemsReq) -> (list[InvoiceLineItem1])
24
29
  *
@@ -1086,7 +1091,7 @@ export class InvoiceLineItems {
1086
1091
  });
1087
1092
  }
1088
1093
  /**
1089
- * 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)
1094
+ * Updates an owner-scoped line item's source fields, including its caller-owned shipper account when not rate-sheet-derived, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
1090
1095
  *
1091
1096
  * @param {string} invoiceLineItemId
1092
1097
  * @param {Chrt.billingNew.InvoiceLineItemClientUpdate1} request
@@ -12,6 +12,8 @@ export interface InvoiceLineItemClientUpdate1 {
12
12
  export_ref__sage__item_id__set_to_None?: boolean;
13
13
  invoice_type?: Chrt.InvoiceTypeEnum1 | null;
14
14
  quantity?: number | null;
15
+ shipper_account_id?: string | null;
16
+ shipper_account_id__set_to_None?: boolean;
15
17
  source_currency_code?: Chrt.BillingCurrencyCodeEnum1 | null;
16
18
  source_unit_price?: number | null;
17
19
  unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
@@ -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";
@@ -31,21 +31,21 @@ 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 accounts-receivable invoice owned by the caller's organization, regardless of invoice status. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (InvoiceExportListRes)
34
+ * Lists up to 1,000 accounts-receivable and accounts-payable line items for the selected Orders, with shipment context. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemExportListReq) -> (InvoiceLineItemExportListRes)
35
35
  *
36
- * @param {string} invoiceId
37
- * @param {Chrt.billingNew.invoices.ExportListV1Request} request
36
+ * @param {Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq} request
38
37
  * @param {Export.RequestOptions} requestOptions - Request-specific configuration.
39
38
  *
40
39
  * @throws {@link Chrt.UnprocessableEntityError}
41
40
  *
42
41
  * @example
43
- * await client.billingNew.invoices.export.listV1("invoice_id", {
42
+ * await client.billingNew.invoiceLineItems.export.listV1({
44
43
  * page: 1,
45
- * page_size: 1
44
+ * page_size: 1,
45
+ * order_ids: ["order_ids"]
46
46
  * })
47
47
  */
48
- listV1(invoiceId: string, request?: Chrt.billingNew.invoices.ExportListV1Request, requestOptions?: Export.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceExportListRes>;
48
+ listV1(request: Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq, requestOptions?: Export.RequestOptions): core.HttpResponsePromise<Chrt.InvoiceLineItemExportListRes>;
49
49
  private __listV1;
50
50
  protected _getAuthorizationHeader(): Promise<string | undefined>;
51
51
  }
@@ -10,6 +10,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  step((generator = generator.apply(thisArg, _arguments || [])).next());
11
11
  });
12
12
  };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
13
24
  import * as environments from "../../../../../../../../environments.mjs";
14
25
  import * as core from "../../../../../../../../core/index.mjs";
15
26
  import * as Chrt from "../../../../../../../index.mjs";
@@ -20,27 +31,27 @@ export class Export {
20
31
  this._options = _options;
21
32
  }
22
33
  /**
23
- * 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)
34
+ * Lists up to 1,000 accounts-receivable and accounts-payable line items for the selected Orders, with shipment context. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemExportListReq) -> (InvoiceLineItemExportListRes)
24
35
  *
25
- * @param {string} invoiceId
26
- * @param {Chrt.billingNew.invoices.ExportListV1Request} request
36
+ * @param {Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq} request
27
37
  * @param {Export.RequestOptions} requestOptions - Request-specific configuration.
28
38
  *
29
39
  * @throws {@link Chrt.UnprocessableEntityError}
30
40
  *
31
41
  * @example
32
- * await client.billingNew.invoices.export.listV1("invoice_id", {
42
+ * await client.billingNew.invoiceLineItems.export.listV1({
33
43
  * page: 1,
34
- * page_size: 1
44
+ * page_size: 1,
45
+ * order_ids: ["order_ids"]
35
46
  * })
36
47
  */
37
- listV1(invoiceId, request = {}, requestOptions) {
38
- return core.HttpResponsePromise.fromPromise(this.__listV1(invoiceId, request, requestOptions));
48
+ listV1(request, requestOptions) {
49
+ return core.HttpResponsePromise.fromPromise(this.__listV1(request, requestOptions));
39
50
  }
40
- __listV1(invoiceId_1) {
41
- return __awaiter(this, arguments, void 0, function* (invoiceId, request = {}, requestOptions) {
51
+ __listV1(request, requestOptions) {
52
+ return __awaiter(this, void 0, void 0, function* () {
42
53
  var _a, _b, _c, _d, _e, _f;
43
- const { page, page_size: pageSize } = request;
54
+ const { page, page_size: pageSize } = request, _body = __rest(request, ["page", "page_size"]);
44
55
  const _queryParams = {};
45
56
  if (page !== undefined) {
46
57
  _queryParams["page"] = (_a = page === null || page === void 0 ? void 0 : page.toString()) !== null && _a !== void 0 ? _a : null;
@@ -50,10 +61,13 @@ export class Export {
50
61
  }
51
62
  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
63
  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",
64
+ 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/invoice_line_items/export/list/v1"),
65
+ method: "POST",
55
66
  headers: _headers,
67
+ contentType: "application/json",
56
68
  queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
69
+ requestType: "json",
70
+ body: _body,
57
71
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
58
72
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
59
73
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -81,7 +95,7 @@ export class Export {
81
95
  rawResponse: _response.rawResponse,
82
96
  });
83
97
  case "timeout":
84
- throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /billing_new/invoices/export/list/v1/{invoice_id}.");
98
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /billing_new/invoice_line_items/export/list/v1.");
85
99
  case "unknown":
86
100
  throw new errors.ChrtError({
87
101
  message: _response.error.errorMessage,
@@ -5,10 +5,12 @@
5
5
  * @example
6
6
  * {
7
7
  * page: 1,
8
- * page_size: 1
8
+ * page_size: 1,
9
+ * order_ids: ["order_ids"]
9
10
  * }
10
11
  */
11
- export interface ExportListV1Request {
12
+ export interface InvoiceLineItemExportListReq {
12
13
  page?: number | null;
13
14
  page_size?: number | null;
15
+ order_ids: string[];
14
16
  }
@@ -0,0 +1 @@
1
+ export { type InvoiceLineItemExportListReq } from "./InvoiceLineItemExportListReq.mjs";
@@ -4,7 +4,6 @@
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";
8
7
  export declare namespace Invoices {
9
8
  interface Options {
10
9
  environment?: core.Supplier<environments.ChrtEnvironment | string>;
@@ -30,9 +29,7 @@ export declare namespace Invoices {
30
29
  }
31
30
  export declare class Invoices {
32
31
  protected readonly _options: Invoices.Options;
33
- protected _export: Export | undefined;
34
32
  constructor(_options?: Invoices.Options);
35
- get export(): Export;
36
33
  /**
37
34
  * Approves a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
38
35
  *
@@ -15,15 +15,10 @@ 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";
19
18
  export class Invoices {
20
19
  constructor(_options = {}) {
21
20
  this._options = _options;
22
21
  }
23
- get export() {
24
- var _a;
25
- return ((_a = this._export) !== null && _a !== void 0 ? _a : (this._export = new Export(this._options)));
26
- }
27
22
  /**
28
23
  * Approves a draft invoice owned by the caller's organization. | authz: allowed_org_types=[provider], min_org_role=operator | () -> (Invoice1)
29
24
  *
@@ -1,2 +1 @@
1
1
  export * from "./client/index.mjs";
2
- export * from "./resources/index.mjs";
@@ -1,2 +1 @@
1
1
  export * from "./client/index.mjs";
2
- export * from "./resources/index.mjs";
@@ -0,0 +1,50 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../index.mjs";
5
+ export interface InvoiceLineItemExportListItem {
6
+ account_name?: string | null;
7
+ airlines?: string[];
8
+ awb_numbers?: string[];
9
+ billing_period_end_at_timestamp?: string | null;
10
+ billing_period_start_at_timestamp?: string | null;
11
+ cargo_descriptions?: string[];
12
+ cargo_quantity?: number | null;
13
+ cargo_types?: string[];
14
+ conversion_rate?: number | null;
15
+ counterparty_name?: string | null;
16
+ currency_code: Chrt.BillingCurrencyCodeEnum1;
17
+ currency_conversion_description?: string | null;
18
+ delivery_address?: string | null;
19
+ delivery_location_name?: string | null;
20
+ delivery_status?: string | null;
21
+ delivery_stop_number?: number | null;
22
+ delivery_stops_on_order?: number | null;
23
+ destination_iata?: string | null;
24
+ flight_numbers?: string[];
25
+ invoice_approval_timestamp?: string | null;
26
+ invoice_line_item_id: string;
27
+ invoice_line_item_status: Chrt.InvoiceLineItemStatusEnum1;
28
+ invoice_number?: string | null;
29
+ invoice_status?: Chrt.InvoiceStatusEnum1 | null;
30
+ invoice_type: Chrt.InvoiceTypeEnum1;
31
+ /** IATA Air Waybill number: 3-digit airline prefix + 8-digit serial, e.g. '020-12345678'. */
32
+ line_item_awb_number?: string | null;
33
+ line_item_description: string;
34
+ line_item_quantity: number;
35
+ line_item_total_amount: number;
36
+ line_item_type: Chrt.InvoiceLineItemTypeEnum1;
37
+ line_item_unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
38
+ line_item_unit_price: number;
39
+ mileage_estimated?: number | null;
40
+ off_chrt_reference_id?: string | null;
41
+ order_placer_comments?: string | null;
42
+ order_short_id?: string | null;
43
+ origin_iata?: string | null;
44
+ pod_at_timestamp?: string | null;
45
+ pod_name?: string | null;
46
+ source_currency_code?: Chrt.BillingCurrencyCodeEnum1 | null;
47
+ source_unit_price?: number | null;
48
+ tax_percentage?: number | null;
49
+ weight_pounds?: number | null;
50
+ }
@@ -2,7 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as Chrt from "../index.mjs";
5
- export interface InvoiceExportListRes {
6
- items: Chrt.InvoiceExportListItem[];
5
+ export interface InvoiceLineItemExportListRes {
6
+ items: Chrt.InvoiceLineItemExportListItem[];
7
7
  total_count: number;
8
8
  }
@@ -256,8 +256,6 @@ export * from "./InternalDelegationJwtRes.mjs";
256
256
  export * from "./Invoice1.mjs";
257
257
  export * from "./InvoiceExpandedListItem.mjs";
258
258
  export * from "./InvoiceExpandedRes.mjs";
259
- export * from "./InvoiceExportListItem.mjs";
260
- export * from "./InvoiceExportListRes.mjs";
261
259
  export * from "./InvoiceLineItem1.mjs";
262
260
  export * from "./InvoiceLineItemAmountTransformation1.mjs";
263
261
  export * from "./InvoiceLineItemAmountTransformationTypeEnum1.mjs";
@@ -265,6 +263,8 @@ export * from "./InvoiceLineItemClientCreate1.mjs";
265
263
  export * from "./InvoiceLineItemCurrencyConversion1.mjs";
266
264
  export * from "./InvoiceLineItemExpandedListItem.mjs";
267
265
  export * from "./InvoiceLineItemExpandedRes.mjs";
266
+ export * from "./InvoiceLineItemExportListItem.mjs";
267
+ export * from "./InvoiceLineItemExportListRes.mjs";
268
268
  export * from "./InvoiceLineItemListRes.mjs";
269
269
  export * from "./InvoiceLineItemServerCreate1.mjs";
270
270
  export * from "./InvoiceLineItemSortByEnum.mjs";
@@ -256,8 +256,6 @@ export * from "./InternalDelegationJwtRes.mjs";
256
256
  export * from "./Invoice1.mjs";
257
257
  export * from "./InvoiceExpandedListItem.mjs";
258
258
  export * from "./InvoiceExpandedRes.mjs";
259
- export * from "./InvoiceExportListItem.mjs";
260
- export * from "./InvoiceExportListRes.mjs";
261
259
  export * from "./InvoiceLineItem1.mjs";
262
260
  export * from "./InvoiceLineItemAmountTransformation1.mjs";
263
261
  export * from "./InvoiceLineItemAmountTransformationTypeEnum1.mjs";
@@ -265,6 +263,8 @@ export * from "./InvoiceLineItemClientCreate1.mjs";
265
263
  export * from "./InvoiceLineItemCurrencyConversion1.mjs";
266
264
  export * from "./InvoiceLineItemExpandedListItem.mjs";
267
265
  export * from "./InvoiceLineItemExpandedRes.mjs";
266
+ export * from "./InvoiceLineItemExportListItem.mjs";
267
+ export * from "./InvoiceLineItemExportListRes.mjs";
268
268
  export * from "./InvoiceLineItemListRes.mjs";
269
269
  export * from "./InvoiceLineItemServerCreate1.mjs";
270
270
  export * from "./InvoiceLineItemSortByEnum.mjs";
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.982.0";
1
+ export declare const SDK_VERSION = "1.984.0";
@@ -1 +1 @@
1
- export const SDK_VERSION = "1.982.0";
1
+ export const SDK_VERSION = "1.984.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@chrt-inc/typescript-sdk",
3
- "version": "1.982.0",
3
+ "version": "1.984.0",
4
4
  "private": false,
5
5
  "repository": "github:chrt-inc/typescript-sdk",
6
6
  "type": "commonjs",
package/reference.md CHANGED
@@ -2885,7 +2885,7 @@ await client.billingNew.invoiceLineItems.updateCurrencyConversionManyV1({
2885
2885
  <dl>
2886
2886
  <dd>
2887
2887
 
2888
- 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)
2888
+ Updates an owner-scoped line item's source fields, including its caller-owned shipper account when not rate-sheet-derived, and rebuilds its draft invoice when attached. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemClientUpdate1) -> (InvoiceLineItem1)
2889
2889
 
2890
2890
  </dd>
2891
2891
  </dl>
@@ -4006,9 +4006,9 @@ await client.billingNew.orders.listExpandedForCoordinatorOperatorsV1({
4006
4006
  </dl>
4007
4007
  </details>
4008
4008
 
4009
- ## BillingNew Invoices Export
4009
+ ## BillingNew InvoiceLineItems Export
4010
4010
 
4011
- <details><summary><code>client.billingNew.invoices.export.<a href="/src/api/resources/billingNew/resources/invoices/resources/export/client/Client.ts">listV1</a>(invoiceId, { ...params }) -> Chrt.InvoiceExportListRes</code></summary>
4011
+ <details><summary><code>client.billingNew.invoiceLineItems.export.<a href="/src/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/Client.ts">listV1</a>({ ...params }) -> Chrt.InvoiceLineItemExportListRes</code></summary>
4012
4012
  <dl>
4013
4013
  <dd>
4014
4014
 
@@ -4020,7 +4020,7 @@ await client.billingNew.orders.listExpandedForCoordinatorOperatorsV1({
4020
4020
  <dl>
4021
4021
  <dd>
4022
4022
 
4023
- 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)
4023
+ Lists up to 1,000 accounts-receivable and accounts-payable line items for the selected Orders, with shipment context. | authz: allowed_org_types=[provider], min_org_role=operator | (InvoiceLineItemExportListReq) -> (InvoiceLineItemExportListRes)
4024
4024
 
4025
4025
  </dd>
4026
4026
  </dl>
@@ -4036,9 +4036,10 @@ Lists up to 1,000 shipment-level export rows for one accounts-receivable invoice
4036
4036
  <dd>
4037
4037
 
4038
4038
  ```typescript
4039
- await client.billingNew.invoices.export.listV1("invoice_id", {
4039
+ await client.billingNew.invoiceLineItems.export.listV1({
4040
4040
  page: 1,
4041
4041
  page_size: 1,
4042
+ order_ids: ["order_ids"],
4042
4043
  });
4043
4044
  ```
4044
4045
 
@@ -4055,15 +4056,7 @@ await client.billingNew.invoices.export.listV1("invoice_id", {
4055
4056
  <dl>
4056
4057
  <dd>
4057
4058
 
4058
- **invoiceId:** `string`
4059
-
4060
- </dd>
4061
- </dl>
4062
-
4063
- <dl>
4064
- <dd>
4065
-
4066
- **request:** `Chrt.billingNew.invoices.ExportListV1Request`
4059
+ **request:** `Chrt.billingNew.invoiceLineItems.InvoiceLineItemExportListReq`
4067
4060
 
4068
4061
  </dd>
4069
4062
  </dl>
@@ -1 +0,0 @@
1
- export { type ExportListV1Request } from "./ExportListV1Request.js";
@@ -1,46 +0,0 @@
1
- /**
2
- * This file was auto-generated by Fern from our API Definition.
3
- */
4
- import * as Chrt from "../index.js";
5
- export interface InvoiceExportListItem {
6
- account_name?: string | null;
7
- airbill_charge: number;
8
- airlines?: string[];
9
- awb_numbers?: string[];
10
- base_rate: number;
11
- billing_period_end_at_timestamp: string;
12
- billing_period_start_at_timestamp: string;
13
- cargo_types?: string[];
14
- charge_per_quantity?: number | null;
15
- charges_subtotal: number;
16
- currency_code: Chrt.BillingCurrencyCodeEnum1;
17
- delivery_address?: string | null;
18
- delivery_location_name?: string | null;
19
- delivery_status?: string | null;
20
- delivery_stop_number?: number | null;
21
- delivery_stops_on_order?: number | null;
22
- destination_iata?: string | null;
23
- flight_numbers?: string[];
24
- invoice_approval_timestamp?: string | null;
25
- invoice_number: string;
26
- mileage_estimated?: number | null;
27
- net_billing: number;
28
- off_chrt_reference_id?: string | null;
29
- order_placer_comments?: string | null;
30
- order_short_id?: string | null;
31
- origin_iata?: string | null;
32
- other_charges: number;
33
- other_charges_detail?: string[];
34
- pod_date?: string | null;
35
- pod_name?: string | null;
36
- pod_time?: string | null;
37
- quantity?: number | null;
38
- tax_1_amount?: number | null;
39
- tax_1_description?: string | null;
40
- tax_2_amount?: number | null;
41
- tax_2_description?: string | null;
42
- tax_3_amount?: number | null;
43
- tax_3_description?: string | null;
44
- total_tax: number;
45
- weight_pounds?: number | null;
46
- }
@@ -1 +0,0 @@
1
- export { type ExportListV1Request } from "./ExportListV1Request.mjs";
@@ -1,46 +0,0 @@
1
- /**
2
- * This file was auto-generated by Fern from our API Definition.
3
- */
4
- import * as Chrt from "../index.mjs";
5
- export interface InvoiceExportListItem {
6
- account_name?: string | null;
7
- airbill_charge: number;
8
- airlines?: string[];
9
- awb_numbers?: string[];
10
- base_rate: number;
11
- billing_period_end_at_timestamp: string;
12
- billing_period_start_at_timestamp: string;
13
- cargo_types?: string[];
14
- charge_per_quantity?: number | null;
15
- charges_subtotal: number;
16
- currency_code: Chrt.BillingCurrencyCodeEnum1;
17
- delivery_address?: string | null;
18
- delivery_location_name?: string | null;
19
- delivery_status?: string | null;
20
- delivery_stop_number?: number | null;
21
- delivery_stops_on_order?: number | null;
22
- destination_iata?: string | null;
23
- flight_numbers?: string[];
24
- invoice_approval_timestamp?: string | null;
25
- invoice_number: string;
26
- mileage_estimated?: number | null;
27
- net_billing: number;
28
- off_chrt_reference_id?: string | null;
29
- order_placer_comments?: string | null;
30
- order_short_id?: string | null;
31
- origin_iata?: string | null;
32
- other_charges: number;
33
- other_charges_detail?: string[];
34
- pod_date?: string | null;
35
- pod_name?: string | null;
36
- pod_time?: string | null;
37
- quantity?: number | null;
38
- tax_1_amount?: number | null;
39
- tax_1_description?: string | null;
40
- tax_2_amount?: number | null;
41
- tax_2_description?: string | null;
42
- tax_3_amount?: number | null;
43
- tax_3_description?: string | null;
44
- total_tax: number;
45
- weight_pounds?: number | null;
46
- }