@chrt-inc/typescript-sdk 1.982.0 → 1.983.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Client.js +2 -2
- package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.ts +4 -1
- package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/Client.js +6 -1
- package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemClientUpdate1.d.ts +2 -0
- package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/index.d.ts +1 -0
- package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/index.js +1 -0
- package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.d.ts +6 -6
- package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.js +27 -13
- 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
- package/dist/cjs/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.d.ts +0 -3
- package/dist/cjs/api/resources/billingNew/resources/invoices/client/Client.js +0 -5
- package/dist/cjs/api/resources/billingNew/resources/invoices/index.d.ts +0 -1
- package/dist/cjs/api/resources/billingNew/resources/invoices/index.js +0 -1
- package/dist/cjs/api/types/InvoiceLineItemExportListItem.d.ts +46 -0
- package/dist/cjs/api/types/{InvoiceExportListRes.d.ts → InvoiceLineItemExportListRes.d.ts} +2 -2
- package/dist/cjs/api/types/index.d.ts +2 -2
- package/dist/cjs/api/types/index.js +2 -2
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.d.mts +4 -1
- package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/Client.mjs +6 -1
- package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/client/requests/InvoiceLineItemClientUpdate1.d.mts +2 -0
- package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/index.d.mts +1 -0
- package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/index.mjs +1 -0
- package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.d.mts +6 -6
- package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/Client.mjs +27 -13
- 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
- package/dist/esm/api/resources/billingNew/resources/invoiceLineItems/resources/export/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.d.mts +0 -3
- package/dist/esm/api/resources/billingNew/resources/invoices/client/Client.mjs +0 -5
- package/dist/esm/api/resources/billingNew/resources/invoices/index.d.mts +0 -1
- package/dist/esm/api/resources/billingNew/resources/invoices/index.mjs +0 -1
- package/dist/esm/api/types/InvoiceLineItemExportListItem.d.mts +46 -0
- package/dist/esm/api/types/{InvoiceExportListRes.d.mts → InvoiceLineItemExportListRes.d.mts} +2 -2
- package/dist/esm/api/types/index.d.mts +2 -2
- package/dist/esm/api/types/index.mjs +2 -2
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +7 -14
- package/dist/cjs/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.d.ts +0 -1
- package/dist/cjs/api/types/InvoiceExportListItem.d.ts +0 -46
- package/dist/esm/api/resources/billingNew/resources/invoices/resources/export/client/requests/index.d.mts +0 -1
- package/dist/esm/api/types/InvoiceExportListItem.d.mts +0 -46
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.d.ts +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.js +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices/resources/export/client/requests/ExportListV1Request.js → invoiceLineItems/resources/export/client/requests/InvoiceLineItemExportListReq.js} +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/requests/index.js +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.d.ts +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.js +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.d.ts +0 -0
- /package/dist/cjs/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.js +0 -0
- /package/dist/cjs/api/types/{InvoiceExportListItem.js → InvoiceLineItemExportListItem.js} +0 -0
- /package/dist/cjs/api/types/{InvoiceExportListRes.js → InvoiceLineItemExportListRes.js} +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.d.mts +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/index.mjs +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices/resources/export/client/requests/ExportListV1Request.mjs → invoiceLineItems/resources/export/client/requests/InvoiceLineItemExportListReq.mjs} +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/client/requests/index.mjs +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.d.mts +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/export/index.mjs +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.d.mts +0 -0
- /package/dist/esm/api/resources/billingNew/resources/{invoices → invoiceLineItems}/resources/index.mjs +0 -0
- /package/dist/esm/api/types/{InvoiceExportListItem.mjs → InvoiceLineItemExportListItem.mjs} +0 -0
- /package/dist/esm/api/types/{InvoiceExportListRes.mjs → InvoiceLineItemExportListRes.mjs} +0 -0
package/dist/cjs/Client.js
CHANGED
|
@@ -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.
|
|
64
|
-
"User-Agent": "@chrt-inc/typescript-sdk/1.
|
|
63
|
+
"X-Fern-SDK-Version": "1.983.0",
|
|
64
|
+
"User-Agent": "@chrt-inc/typescript-sdk/1.983.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,
|
|
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,
|
|
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;
|
|
@@ -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
|
|
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 {
|
|
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.
|
|
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(
|
|
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
|
|
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 {
|
|
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.
|
|
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(
|
|
74
|
-
return core.HttpResponsePromise.fromPromise(this.__listV1(
|
|
84
|
+
listV1(request, requestOptions) {
|
|
85
|
+
return core.HttpResponsePromise.fromPromise(this.__listV1(request, requestOptions));
|
|
75
86
|
}
|
|
76
|
-
__listV1(
|
|
77
|
-
return __awaiter(this,
|
|
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,
|
|
90
|
-
method: "
|
|
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
|
|
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
|
|
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
|
*
|
|
@@ -0,0 +1,46 @@
|
|
|
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
|
+
counterparty_name?: string | null;
|
|
15
|
+
currency_code: Chrt.BillingCurrencyCodeEnum1;
|
|
16
|
+
delivery_address?: string | null;
|
|
17
|
+
delivery_location_name?: string | null;
|
|
18
|
+
delivery_status?: string | null;
|
|
19
|
+
delivery_stop_number?: number | null;
|
|
20
|
+
delivery_stops_on_order?: number | null;
|
|
21
|
+
destination_iata?: string | null;
|
|
22
|
+
flight_numbers?: string[];
|
|
23
|
+
invoice_approval_timestamp?: string | null;
|
|
24
|
+
invoice_line_item_id: string;
|
|
25
|
+
invoice_line_item_status: Chrt.InvoiceLineItemStatusEnum1;
|
|
26
|
+
invoice_number?: string | null;
|
|
27
|
+
invoice_status?: Chrt.InvoiceStatusEnum1 | null;
|
|
28
|
+
invoice_type: Chrt.InvoiceTypeEnum1;
|
|
29
|
+
/** IATA Air Waybill number: 3-digit airline prefix + 8-digit serial, e.g. '020-12345678'. */
|
|
30
|
+
line_item_awb_number?: string | null;
|
|
31
|
+
line_item_description: string;
|
|
32
|
+
line_item_quantity: number;
|
|
33
|
+
line_item_total_amount: number;
|
|
34
|
+
line_item_type: Chrt.InvoiceLineItemTypeEnum1;
|
|
35
|
+
line_item_unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
|
|
36
|
+
line_item_unit_price: number;
|
|
37
|
+
mileage_estimated?: number | null;
|
|
38
|
+
off_chrt_reference_id?: string | null;
|
|
39
|
+
order_placer_comments?: string | null;
|
|
40
|
+
order_short_id?: string | null;
|
|
41
|
+
origin_iata?: string | null;
|
|
42
|
+
pod_at_timestamp?: string | null;
|
|
43
|
+
pod_name?: string | null;
|
|
44
|
+
tax_percentage?: number | null;
|
|
45
|
+
weight_pounds?: number | null;
|
|
46
|
+
}
|
|
@@ -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
|
|
6
|
-
items: Chrt.
|
|
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);
|
package/dist/cjs/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.
|
|
1
|
+
export declare const SDK_VERSION = "1.983.0";
|
package/dist/cjs/version.js
CHANGED
package/dist/esm/Client.mjs
CHANGED
|
@@ -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.
|
|
28
|
-
"User-Agent": "@chrt-inc/typescript-sdk/1.
|
|
27
|
+
"X-Fern-SDK-Version": "1.983.0",
|
|
28
|
+
"User-Agent": "@chrt-inc/typescript-sdk/1.983.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,
|
|
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,
|
|
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;
|
|
@@ -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
|
|
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 {
|
|
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.
|
|
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(
|
|
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
|
|
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 {
|
|
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.
|
|
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(
|
|
38
|
-
return core.HttpResponsePromise.fromPromise(this.__listV1(
|
|
48
|
+
listV1(request, requestOptions) {
|
|
49
|
+
return core.HttpResponsePromise.fromPromise(this.__listV1(request, requestOptions));
|
|
39
50
|
}
|
|
40
|
-
__listV1(
|
|
41
|
-
return __awaiter(this,
|
|
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,
|
|
54
|
-
method: "
|
|
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
|
|
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
|
|
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
|
*
|
|
@@ -0,0 +1,46 @@
|
|
|
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
|
+
counterparty_name?: string | null;
|
|
15
|
+
currency_code: Chrt.BillingCurrencyCodeEnum1;
|
|
16
|
+
delivery_address?: string | null;
|
|
17
|
+
delivery_location_name?: string | null;
|
|
18
|
+
delivery_status?: string | null;
|
|
19
|
+
delivery_stop_number?: number | null;
|
|
20
|
+
delivery_stops_on_order?: number | null;
|
|
21
|
+
destination_iata?: string | null;
|
|
22
|
+
flight_numbers?: string[];
|
|
23
|
+
invoice_approval_timestamp?: string | null;
|
|
24
|
+
invoice_line_item_id: string;
|
|
25
|
+
invoice_line_item_status: Chrt.InvoiceLineItemStatusEnum1;
|
|
26
|
+
invoice_number?: string | null;
|
|
27
|
+
invoice_status?: Chrt.InvoiceStatusEnum1 | null;
|
|
28
|
+
invoice_type: Chrt.InvoiceTypeEnum1;
|
|
29
|
+
/** IATA Air Waybill number: 3-digit airline prefix + 8-digit serial, e.g. '020-12345678'. */
|
|
30
|
+
line_item_awb_number?: string | null;
|
|
31
|
+
line_item_description: string;
|
|
32
|
+
line_item_quantity: number;
|
|
33
|
+
line_item_total_amount: number;
|
|
34
|
+
line_item_type: Chrt.InvoiceLineItemTypeEnum1;
|
|
35
|
+
line_item_unit?: Chrt.InvoiceLineItemUnitEnum1 | null;
|
|
36
|
+
line_item_unit_price: number;
|
|
37
|
+
mileage_estimated?: number | null;
|
|
38
|
+
off_chrt_reference_id?: string | null;
|
|
39
|
+
order_placer_comments?: string | null;
|
|
40
|
+
order_short_id?: string | null;
|
|
41
|
+
origin_iata?: string | null;
|
|
42
|
+
pod_at_timestamp?: string | null;
|
|
43
|
+
pod_name?: string | null;
|
|
44
|
+
tax_percentage?: number | null;
|
|
45
|
+
weight_pounds?: number | null;
|
|
46
|
+
}
|
package/dist/esm/api/types/{InvoiceExportListRes.d.mts → InvoiceLineItemExportListRes.d.mts}
RENAMED
|
@@ -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
|
|
6
|
-
items: Chrt.
|
|
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";
|
package/dist/esm/version.d.mts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.
|
|
1
|
+
export declare const SDK_VERSION = "1.983.0";
|
package/dist/esm/version.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const SDK_VERSION = "1.
|
|
1
|
+
export const SDK_VERSION = "1.983.0";
|
package/package.json
CHANGED
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,
|
|
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
|
|
4009
|
+
## BillingNew InvoiceLineItems Export
|
|
4010
4010
|
|
|
4011
|
-
<details><summary><code>client.billingNew.
|
|
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
|
|
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.
|
|
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
|
-
**
|
|
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
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|