@chrt-inc/typescript-sdk 1.1035.0 → 1.1037.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 (132) hide show
  1. package/dist/cjs/Client.js +2 -2
  2. package/dist/cjs/api/resources/cargoOnFlightIntegrations/client/Client.d.ts +3 -0
  3. package/dist/cjs/api/resources/cargoOnFlightIntegrations/client/Client.js +7 -2
  4. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/Client.d.ts +88 -0
  5. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/Client.js +269 -0
  6. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/index.d.ts +2 -0
  7. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/index.js +17 -0
  8. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaBookReq.d.ts +18 -0
  9. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaCancelReq.d.ts +12 -0
  10. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaCancelReq.js +5 -0
  11. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/index.d.ts +2 -0
  12. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/index.js +2 -0
  13. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/index.d.ts +1 -0
  14. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/airCanada/index.js +17 -0
  15. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/cargoai/client/Client.d.ts +2 -2
  16. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/cargoai/client/Client.js +1 -1
  17. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/cargoai/client/requests/index.d.ts +0 -1
  18. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/index.d.ts +2 -0
  19. package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/index.js +3 -1
  20. package/dist/cjs/api/resources/orgs/client/Client.d.ts +3 -0
  21. package/dist/cjs/api/resources/orgs/client/Client.js +19 -14
  22. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/Client.d.ts +137 -0
  23. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/Client.js +528 -0
  24. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/index.d.ts +2 -0
  25. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/index.js +17 -0
  26. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersAddReq.d.ts +12 -0
  27. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersAddReq.js +5 -0
  28. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersListV1Request.d.ts +27 -0
  29. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersListV1Request.js +5 -0
  30. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkAvailableReq.d.ts +12 -0
  31. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkAvailableReq.js +5 -0
  32. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkUsedReq.d.ts +13 -0
  33. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkUsedReq.js +5 -0
  34. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersVoidReq.d.ts +13 -0
  35. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersVoidReq.js +5 -0
  36. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/index.d.ts +5 -0
  37. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/index.js +2 -0
  38. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/index.d.ts +1 -0
  39. package/dist/cjs/api/resources/orgs/resources/airWaybillStockNumbers/index.js +17 -0
  40. package/dist/cjs/api/resources/orgs/resources/index.d.ts +2 -0
  41. package/dist/cjs/api/resources/orgs/resources/index.js +3 -1
  42. package/dist/cjs/api/resources/shipping/resources/cargoOnFlightBookings/client/Client.d.ts +1 -1
  43. package/dist/cjs/api/resources/shipping/resources/cargoOnFlightBookings/client/Client.js +1 -1
  44. package/dist/cjs/api/resources/shipping/resources/cargoOnFlightBookings/client/requests/CargoOnFlightBookingClientCreate1.d.ts +1 -1
  45. package/dist/cjs/api/types/AirWaybillStockNumber1.d.ts +21 -0
  46. package/dist/cjs/api/types/AirWaybillStockNumber1.js +5 -0
  47. package/dist/cjs/api/types/AirWaybillStockNumberListRes.d.ts +8 -0
  48. package/dist/cjs/api/types/AirWaybillStockNumberListRes.js +5 -0
  49. package/dist/cjs/api/types/AirWaybillStockNumberSortByEnum.d.ts +9 -0
  50. package/dist/cjs/api/types/AirWaybillStockNumberSortByEnum.js +11 -0
  51. package/dist/cjs/api/types/AirWaybillStockNumberStatusEnum1.d.ts +10 -0
  52. package/dist/cjs/api/types/AirWaybillStockNumberStatusEnum1.js +12 -0
  53. package/dist/cjs/api/types/AirWaybillStockNumbersAddRes.d.ts +8 -0
  54. package/dist/cjs/api/types/AirWaybillStockNumbersAddRes.js +5 -0
  55. package/dist/cjs/api/types/AirWaybillStockNumbersSummaryRes.d.ts +10 -0
  56. package/dist/cjs/api/types/AirWaybillStockNumbersSummaryRes.js +5 -0
  57. package/dist/cjs/api/{resources/cargoOnFlightIntegrations/resources/cargoai/client/requests → types}/CargoOnFlightBookingSearchClientCreate1.d.ts +0 -10
  58. package/dist/cjs/api/types/CargoOnFlightBookingSearchClientCreate1.js +5 -0
  59. package/dist/cjs/api/types/CargoOnFlightIntegrationEnum1.d.ts +2 -1
  60. package/dist/cjs/api/types/CargoOnFlightIntegrationEnum1.js +1 -0
  61. package/dist/cjs/api/types/index.d.ts +7 -0
  62. package/dist/cjs/api/types/index.js +7 -0
  63. package/dist/cjs/version.d.ts +1 -1
  64. package/dist/cjs/version.js +1 -1
  65. package/dist/esm/Client.mjs +2 -2
  66. package/dist/esm/api/resources/cargoOnFlightIntegrations/client/Client.d.mts +3 -0
  67. package/dist/esm/api/resources/cargoOnFlightIntegrations/client/Client.mjs +5 -0
  68. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/Client.d.mts +88 -0
  69. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/Client.mjs +232 -0
  70. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/index.d.mts +2 -0
  71. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/index.mjs +1 -0
  72. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaBookReq.d.mts +18 -0
  73. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaCancelReq.d.mts +12 -0
  74. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaCancelReq.mjs +4 -0
  75. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/index.d.mts +2 -0
  76. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/client/requests/index.mjs +1 -0
  77. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/index.d.mts +1 -0
  78. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/airCanada/index.mjs +1 -0
  79. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/cargoai/client/Client.d.mts +2 -2
  80. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/cargoai/client/Client.mjs +1 -1
  81. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/cargoai/client/requests/index.d.mts +0 -1
  82. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/index.d.mts +2 -0
  83. package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/index.mjs +2 -0
  84. package/dist/esm/api/resources/orgs/client/Client.d.mts +3 -0
  85. package/dist/esm/api/resources/orgs/client/Client.mjs +5 -0
  86. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/Client.d.mts +137 -0
  87. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/Client.mjs +491 -0
  88. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/index.d.mts +2 -0
  89. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/index.mjs +1 -0
  90. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersAddReq.d.mts +12 -0
  91. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersAddReq.mjs +4 -0
  92. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersListV1Request.d.mts +27 -0
  93. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersListV1Request.mjs +4 -0
  94. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkAvailableReq.d.mts +12 -0
  95. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkAvailableReq.mjs +4 -0
  96. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkUsedReq.d.mts +13 -0
  97. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersMarkUsedReq.mjs +4 -0
  98. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersVoidReq.d.mts +13 -0
  99. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/AirWaybillStockNumbersVoidReq.mjs +4 -0
  100. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/index.d.mts +5 -0
  101. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/client/requests/index.mjs +1 -0
  102. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/index.d.mts +1 -0
  103. package/dist/esm/api/resources/orgs/resources/airWaybillStockNumbers/index.mjs +1 -0
  104. package/dist/esm/api/resources/orgs/resources/index.d.mts +2 -0
  105. package/dist/esm/api/resources/orgs/resources/index.mjs +2 -0
  106. package/dist/esm/api/resources/shipping/resources/cargoOnFlightBookings/client/Client.d.mts +1 -1
  107. package/dist/esm/api/resources/shipping/resources/cargoOnFlightBookings/client/Client.mjs +1 -1
  108. package/dist/esm/api/resources/shipping/resources/cargoOnFlightBookings/client/requests/CargoOnFlightBookingClientCreate1.d.mts +1 -1
  109. package/dist/esm/api/types/AirWaybillStockNumber1.d.mts +21 -0
  110. package/dist/esm/api/types/AirWaybillStockNumber1.mjs +4 -0
  111. package/dist/esm/api/types/AirWaybillStockNumberListRes.d.mts +8 -0
  112. package/dist/esm/api/types/AirWaybillStockNumberListRes.mjs +4 -0
  113. package/dist/esm/api/types/AirWaybillStockNumberSortByEnum.d.mts +9 -0
  114. package/dist/esm/api/types/AirWaybillStockNumberSortByEnum.mjs +8 -0
  115. package/dist/esm/api/types/AirWaybillStockNumberStatusEnum1.d.mts +10 -0
  116. package/dist/esm/api/types/AirWaybillStockNumberStatusEnum1.mjs +9 -0
  117. package/dist/esm/api/types/AirWaybillStockNumbersAddRes.d.mts +8 -0
  118. package/dist/esm/api/types/AirWaybillStockNumbersAddRes.mjs +4 -0
  119. package/dist/esm/api/types/AirWaybillStockNumbersSummaryRes.d.mts +10 -0
  120. package/dist/esm/api/types/AirWaybillStockNumbersSummaryRes.mjs +4 -0
  121. package/dist/esm/api/{resources/cargoOnFlightIntegrations/resources/cargoai/client/requests → types}/CargoOnFlightBookingSearchClientCreate1.d.mts +0 -10
  122. package/dist/esm/api/types/CargoOnFlightBookingSearchClientCreate1.mjs +4 -0
  123. package/dist/esm/api/types/CargoOnFlightIntegrationEnum1.d.mts +2 -1
  124. package/dist/esm/api/types/CargoOnFlightIntegrationEnum1.mjs +1 -0
  125. package/dist/esm/api/types/index.d.mts +7 -0
  126. package/dist/esm/api/types/index.mjs +7 -0
  127. package/dist/esm/version.d.mts +1 -1
  128. package/dist/esm/version.mjs +1 -1
  129. package/package.json +1 -1
  130. package/reference.md +679 -2
  131. /package/dist/cjs/api/resources/cargoOnFlightIntegrations/resources/{cargoai/client/requests/CargoOnFlightBookingSearchClientCreate1.js → airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaBookReq.js} +0 -0
  132. /package/dist/esm/api/resources/cargoOnFlightIntegrations/resources/{cargoai/client/requests/CargoOnFlightBookingSearchClientCreate1.mjs → airCanada/client/requests/CargoOnFlightIntegrationsAirCanadaBookReq.mjs} +0 -0
@@ -0,0 +1,528 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || (function () {
22
+ var ownKeys = function(o) {
23
+ ownKeys = Object.getOwnPropertyNames || function (o) {
24
+ var ar = [];
25
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
26
+ return ar;
27
+ };
28
+ return ownKeys(o);
29
+ };
30
+ return function (mod) {
31
+ if (mod && mod.__esModule) return mod;
32
+ var result = {};
33
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
34
+ __setModuleDefault(result, mod);
35
+ return result;
36
+ };
37
+ })();
38
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
39
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
40
+ return new (P || (P = Promise))(function (resolve, reject) {
41
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
42
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
43
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
44
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
45
+ });
46
+ };
47
+ Object.defineProperty(exports, "__esModule", { value: true });
48
+ exports.AirWaybillStockNumbers = void 0;
49
+ const environments = __importStar(require("../../../../../../environments.js"));
50
+ const core = __importStar(require("../../../../../../core/index.js"));
51
+ const Chrt = __importStar(require("../../../../../index.js"));
52
+ const headers_js_1 = require("../../../../../../core/headers.js");
53
+ const errors = __importStar(require("../../../../../../errors/index.js"));
54
+ class AirWaybillStockNumbers {
55
+ constructor(_options = {}) {
56
+ this._options = _options;
57
+ }
58
+ /**
59
+ * Adds AWB numbers an airline gave the caller's organization to its AWB stock, skipping numbers already in it. | authz: min_org_role=operator | (AirWaybillStockNumbersAddReq) -> (AirWaybillStockNumbersAddRes)
60
+ *
61
+ * @param {Chrt.orgs.AirWaybillStockNumbersAddReq} request
62
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
63
+ *
64
+ * @throws {@link Chrt.UnprocessableEntityError}
65
+ *
66
+ * @example
67
+ * await client.orgs.airWaybillStockNumbers.addV1({
68
+ * awb_numbers: ["awb_numbers"]
69
+ * })
70
+ */
71
+ addV1(request, requestOptions) {
72
+ return core.HttpResponsePromise.fromPromise(this.__addV1(request, requestOptions));
73
+ }
74
+ __addV1(request, requestOptions) {
75
+ return __awaiter(this, void 0, void 0, function* () {
76
+ var _a, _b, _c, _d;
77
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
78
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
79
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "orgs/air_waybill_stock_numbers/add/v1"),
80
+ method: "POST",
81
+ headers: _headers,
82
+ contentType: "application/json",
83
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
84
+ requestType: "json",
85
+ body: request,
86
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
87
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
88
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
89
+ });
90
+ if (_response.ok) {
91
+ return { data: _response.body, rawResponse: _response.rawResponse };
92
+ }
93
+ if (_response.error.reason === "status-code") {
94
+ switch (_response.error.statusCode) {
95
+ case 422:
96
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
97
+ default:
98
+ throw new errors.ChrtError({
99
+ statusCode: _response.error.statusCode,
100
+ body: _response.error.body,
101
+ rawResponse: _response.rawResponse,
102
+ });
103
+ }
104
+ }
105
+ switch (_response.error.reason) {
106
+ case "non-json":
107
+ throw new errors.ChrtError({
108
+ statusCode: _response.error.statusCode,
109
+ body: _response.error.rawBody,
110
+ rawResponse: _response.rawResponse,
111
+ });
112
+ case "timeout":
113
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /orgs/air_waybill_stock_numbers/add/v1.");
114
+ case "unknown":
115
+ throw new errors.ChrtError({
116
+ message: _response.error.errorMessage,
117
+ rawResponse: _response.rawResponse,
118
+ });
119
+ }
120
+ });
121
+ }
122
+ /**
123
+ * Deletes an available AWB number from the caller's organization's AWB stock, e.g. one added by mistake. | authz: min_org_role=operator | () -> (bool)
124
+ *
125
+ * @param {string} airWaybillStockNumberId
126
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
127
+ *
128
+ * @throws {@link Chrt.UnprocessableEntityError}
129
+ *
130
+ * @example
131
+ * await client.orgs.airWaybillStockNumbers.deleteV1("air_waybill_stock_number_id")
132
+ */
133
+ deleteV1(airWaybillStockNumberId, requestOptions) {
134
+ return core.HttpResponsePromise.fromPromise(this.__deleteV1(airWaybillStockNumberId, requestOptions));
135
+ }
136
+ __deleteV1(airWaybillStockNumberId, requestOptions) {
137
+ return __awaiter(this, void 0, void 0, function* () {
138
+ var _a, _b, _c, _d;
139
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
140
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
141
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, `orgs/air_waybill_stock_numbers/delete/v1/${encodeURIComponent(airWaybillStockNumberId)}`),
142
+ method: "DELETE",
143
+ headers: _headers,
144
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
145
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
146
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
147
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
148
+ });
149
+ if (_response.ok) {
150
+ return { data: _response.body, rawResponse: _response.rawResponse };
151
+ }
152
+ if (_response.error.reason === "status-code") {
153
+ switch (_response.error.statusCode) {
154
+ case 422:
155
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
156
+ default:
157
+ throw new errors.ChrtError({
158
+ statusCode: _response.error.statusCode,
159
+ body: _response.error.body,
160
+ rawResponse: _response.rawResponse,
161
+ });
162
+ }
163
+ }
164
+ switch (_response.error.reason) {
165
+ case "non-json":
166
+ throw new errors.ChrtError({
167
+ statusCode: _response.error.statusCode,
168
+ body: _response.error.rawBody,
169
+ rawResponse: _response.rawResponse,
170
+ });
171
+ case "timeout":
172
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling DELETE /orgs/air_waybill_stock_numbers/delete/v1/{air_waybill_stock_number_id}.");
173
+ case "unknown":
174
+ throw new errors.ChrtError({
175
+ message: _response.error.errorMessage,
176
+ rawResponse: _response.rawResponse,
177
+ });
178
+ }
179
+ });
180
+ }
181
+ /**
182
+ * Lists the AWB numbers in the caller's organization's AWB stock, by airline prefix and status. | () -> (AirWaybillStockNumberListRes)
183
+ *
184
+ * @param {Chrt.orgs.AirWaybillStockNumbersListV1Request} request
185
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
186
+ *
187
+ * @throws {@link Chrt.UnprocessableEntityError}
188
+ *
189
+ * @example
190
+ * await client.orgs.airWaybillStockNumbers.listV1({
191
+ * filter_awb_prefix: "filter_awb_prefix",
192
+ * filter_status: ["available"],
193
+ * sort_by: "awb_number",
194
+ * sort_order: "asc",
195
+ * page: 1,
196
+ * page_size: 1
197
+ * })
198
+ */
199
+ listV1(request = {}, requestOptions) {
200
+ return core.HttpResponsePromise.fromPromise(this.__listV1(request, requestOptions));
201
+ }
202
+ __listV1() {
203
+ return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
204
+ var _a, _b, _c, _d, _e, _f;
205
+ const { filter_awb_prefix: filterAwbPrefix, filter_status: filterStatus, sort_by: sortBy, sort_order: sortOrder, page, page_size: pageSize, } = request;
206
+ const _queryParams = {};
207
+ if (filterAwbPrefix !== undefined) {
208
+ _queryParams["filter_awb_prefix"] = filterAwbPrefix;
209
+ }
210
+ if (filterStatus !== undefined) {
211
+ if (Array.isArray(filterStatus)) {
212
+ _queryParams["filter_status"] = filterStatus.map((item) => item);
213
+ }
214
+ else {
215
+ _queryParams["filter_status"] = filterStatus;
216
+ }
217
+ }
218
+ if (sortBy !== undefined) {
219
+ _queryParams["sort_by"] = sortBy;
220
+ }
221
+ if (sortOrder !== undefined) {
222
+ _queryParams["sort_order"] = sortOrder;
223
+ }
224
+ if (page !== undefined) {
225
+ _queryParams["page"] = (_a = page === null || page === void 0 ? void 0 : page.toString()) !== null && _a !== void 0 ? _a : null;
226
+ }
227
+ if (pageSize !== undefined) {
228
+ _queryParams["page_size"] = (_b = pageSize === null || pageSize === void 0 ? void 0 : pageSize.toString()) !== null && _b !== void 0 ? _b : null;
229
+ }
230
+ 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);
231
+ const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
232
+ 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, "orgs/air_waybill_stock_numbers/list/v1"),
233
+ method: "GET",
234
+ headers: _headers,
235
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
236
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
237
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
238
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
239
+ });
240
+ if (_response.ok) {
241
+ return { data: _response.body, rawResponse: _response.rawResponse };
242
+ }
243
+ if (_response.error.reason === "status-code") {
244
+ switch (_response.error.statusCode) {
245
+ case 422:
246
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
247
+ default:
248
+ throw new errors.ChrtError({
249
+ statusCode: _response.error.statusCode,
250
+ body: _response.error.body,
251
+ rawResponse: _response.rawResponse,
252
+ });
253
+ }
254
+ }
255
+ switch (_response.error.reason) {
256
+ case "non-json":
257
+ throw new errors.ChrtError({
258
+ statusCode: _response.error.statusCode,
259
+ body: _response.error.rawBody,
260
+ rawResponse: _response.rawResponse,
261
+ });
262
+ case "timeout":
263
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /orgs/air_waybill_stock_numbers/list/v1.");
264
+ case "unknown":
265
+ throw new errors.ChrtError({
266
+ message: _response.error.errorMessage,
267
+ rawResponse: _response.rawResponse,
268
+ });
269
+ }
270
+ });
271
+ }
272
+ /**
273
+ * Marks AWB numbers of the caller's organization's AWB stock as available, whatever their status, taking them off their booking. | authz: min_org_role=operator | (AirWaybillStockNumbersMarkAvailableReq) -> (list[AirWaybillStockNumber1])
274
+ *
275
+ * @param {Chrt.orgs.AirWaybillStockNumbersMarkAvailableReq} request
276
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
277
+ *
278
+ * @throws {@link Chrt.UnprocessableEntityError}
279
+ *
280
+ * @example
281
+ * await client.orgs.airWaybillStockNumbers.markAvailableV1({
282
+ * awb_numbers: ["awb_numbers"]
283
+ * })
284
+ */
285
+ markAvailableV1(request, requestOptions) {
286
+ return core.HttpResponsePromise.fromPromise(this.__markAvailableV1(request, requestOptions));
287
+ }
288
+ __markAvailableV1(request, requestOptions) {
289
+ return __awaiter(this, void 0, void 0, function* () {
290
+ var _a, _b, _c, _d;
291
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
292
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
293
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "orgs/air_waybill_stock_numbers/mark_available/v1"),
294
+ method: "POST",
295
+ headers: _headers,
296
+ contentType: "application/json",
297
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
298
+ requestType: "json",
299
+ body: request,
300
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
301
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
302
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
303
+ });
304
+ if (_response.ok) {
305
+ return { data: _response.body, rawResponse: _response.rawResponse };
306
+ }
307
+ if (_response.error.reason === "status-code") {
308
+ switch (_response.error.statusCode) {
309
+ case 422:
310
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
311
+ default:
312
+ throw new errors.ChrtError({
313
+ statusCode: _response.error.statusCode,
314
+ body: _response.error.body,
315
+ rawResponse: _response.rawResponse,
316
+ });
317
+ }
318
+ }
319
+ switch (_response.error.reason) {
320
+ case "non-json":
321
+ throw new errors.ChrtError({
322
+ statusCode: _response.error.statusCode,
323
+ body: _response.error.rawBody,
324
+ rawResponse: _response.rawResponse,
325
+ });
326
+ case "timeout":
327
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /orgs/air_waybill_stock_numbers/mark_available/v1.");
328
+ case "unknown":
329
+ throw new errors.ChrtError({
330
+ message: _response.error.errorMessage,
331
+ rawResponse: _response.rawResponse,
332
+ });
333
+ }
334
+ });
335
+ }
336
+ /**
337
+ * Marks AWB numbers of the caller's organization's AWB stock as used, whatever their status, e.g. booked outside CHRT. | authz: min_org_role=operator | (AirWaybillStockNumbersMarkUsedReq) -> (list[AirWaybillStockNumber1])
338
+ *
339
+ * @param {Chrt.orgs.AirWaybillStockNumbersMarkUsedReq} request
340
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
341
+ *
342
+ * @throws {@link Chrt.UnprocessableEntityError}
343
+ *
344
+ * @example
345
+ * await client.orgs.airWaybillStockNumbers.markUsedV1({
346
+ * awb_numbers: ["awb_numbers"]
347
+ * })
348
+ */
349
+ markUsedV1(request, requestOptions) {
350
+ return core.HttpResponsePromise.fromPromise(this.__markUsedV1(request, requestOptions));
351
+ }
352
+ __markUsedV1(request, requestOptions) {
353
+ return __awaiter(this, void 0, void 0, function* () {
354
+ var _a, _b, _c, _d;
355
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
356
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
357
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "orgs/air_waybill_stock_numbers/mark_used/v1"),
358
+ method: "POST",
359
+ headers: _headers,
360
+ contentType: "application/json",
361
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
362
+ requestType: "json",
363
+ body: request,
364
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
365
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
366
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
367
+ });
368
+ if (_response.ok) {
369
+ return { data: _response.body, rawResponse: _response.rawResponse };
370
+ }
371
+ if (_response.error.reason === "status-code") {
372
+ switch (_response.error.statusCode) {
373
+ case 422:
374
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
375
+ default:
376
+ throw new errors.ChrtError({
377
+ statusCode: _response.error.statusCode,
378
+ body: _response.error.body,
379
+ rawResponse: _response.rawResponse,
380
+ });
381
+ }
382
+ }
383
+ switch (_response.error.reason) {
384
+ case "non-json":
385
+ throw new errors.ChrtError({
386
+ statusCode: _response.error.statusCode,
387
+ body: _response.error.rawBody,
388
+ rawResponse: _response.rawResponse,
389
+ });
390
+ case "timeout":
391
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /orgs/air_waybill_stock_numbers/mark_used/v1.");
392
+ case "unknown":
393
+ throw new errors.ChrtError({
394
+ message: _response.error.errorMessage,
395
+ rawResponse: _response.rawResponse,
396
+ });
397
+ }
398
+ });
399
+ }
400
+ /**
401
+ * Counts the caller's organization's AWB stock per airline prefix and status. | () -> (list[AirWaybillStockNumbersSummaryRes])
402
+ *
403
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
404
+ *
405
+ * @example
406
+ * await client.orgs.airWaybillStockNumbers.summaryV1()
407
+ */
408
+ summaryV1(requestOptions) {
409
+ return core.HttpResponsePromise.fromPromise(this.__summaryV1(requestOptions));
410
+ }
411
+ __summaryV1(requestOptions) {
412
+ return __awaiter(this, void 0, void 0, function* () {
413
+ var _a, _b, _c, _d;
414
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
415
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
416
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "orgs/air_waybill_stock_numbers/summary/v1"),
417
+ method: "GET",
418
+ headers: _headers,
419
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
420
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
421
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
422
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
423
+ });
424
+ if (_response.ok) {
425
+ return {
426
+ data: _response.body,
427
+ rawResponse: _response.rawResponse,
428
+ };
429
+ }
430
+ if (_response.error.reason === "status-code") {
431
+ throw new errors.ChrtError({
432
+ statusCode: _response.error.statusCode,
433
+ body: _response.error.body,
434
+ rawResponse: _response.rawResponse,
435
+ });
436
+ }
437
+ switch (_response.error.reason) {
438
+ case "non-json":
439
+ throw new errors.ChrtError({
440
+ statusCode: _response.error.statusCode,
441
+ body: _response.error.rawBody,
442
+ rawResponse: _response.rawResponse,
443
+ });
444
+ case "timeout":
445
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling GET /orgs/air_waybill_stock_numbers/summary/v1.");
446
+ case "unknown":
447
+ throw new errors.ChrtError({
448
+ message: _response.error.errorMessage,
449
+ rawResponse: _response.rawResponse,
450
+ });
451
+ }
452
+ });
453
+ }
454
+ /**
455
+ * Voids available AWB numbers of the caller's organization's AWB stock, e.g. spoiled or returned to the airline. | authz: min_org_role=operator | (AirWaybillStockNumbersVoidReq) -> (list[AirWaybillStockNumber1])
456
+ *
457
+ * @param {Chrt.orgs.AirWaybillStockNumbersVoidReq} request
458
+ * @param {AirWaybillStockNumbers.RequestOptions} requestOptions - Request-specific configuration.
459
+ *
460
+ * @throws {@link Chrt.UnprocessableEntityError}
461
+ *
462
+ * @example
463
+ * await client.orgs.airWaybillStockNumbers.voidV1({
464
+ * awb_numbers: ["awb_numbers"]
465
+ * })
466
+ */
467
+ voidV1(request, requestOptions) {
468
+ return core.HttpResponsePromise.fromPromise(this.__voidV1(request, requestOptions));
469
+ }
470
+ __voidV1(request, requestOptions) {
471
+ return __awaiter(this, void 0, void 0, function* () {
472
+ var _a, _b, _c, _d;
473
+ let _headers = (0, headers_js_1.mergeHeaders)((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_js_1.mergeOnlyDefinedHeaders)({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
474
+ const _response = yield ((_b = this._options.fetcher) !== null && _b !== void 0 ? _b : core.fetcher)({
475
+ url: core.url.join((_d = (_c = (yield core.Supplier.get(this._options.baseUrl))) !== null && _c !== void 0 ? _c : (yield core.Supplier.get(this._options.environment))) !== null && _d !== void 0 ? _d : environments.ChrtEnvironment.Local, "orgs/air_waybill_stock_numbers/void/v1"),
476
+ method: "POST",
477
+ headers: _headers,
478
+ contentType: "application/json",
479
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
480
+ requestType: "json",
481
+ body: request,
482
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
483
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
484
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
485
+ });
486
+ if (_response.ok) {
487
+ return { data: _response.body, rawResponse: _response.rawResponse };
488
+ }
489
+ if (_response.error.reason === "status-code") {
490
+ switch (_response.error.statusCode) {
491
+ case 422:
492
+ throw new Chrt.UnprocessableEntityError(_response.error.body, _response.rawResponse);
493
+ default:
494
+ throw new errors.ChrtError({
495
+ statusCode: _response.error.statusCode,
496
+ body: _response.error.body,
497
+ rawResponse: _response.rawResponse,
498
+ });
499
+ }
500
+ }
501
+ switch (_response.error.reason) {
502
+ case "non-json":
503
+ throw new errors.ChrtError({
504
+ statusCode: _response.error.statusCode,
505
+ body: _response.error.rawBody,
506
+ rawResponse: _response.rawResponse,
507
+ });
508
+ case "timeout":
509
+ throw new errors.ChrtTimeoutError("Timeout exceeded when calling POST /orgs/air_waybill_stock_numbers/void/v1.");
510
+ case "unknown":
511
+ throw new errors.ChrtError({
512
+ message: _response.error.errorMessage,
513
+ rawResponse: _response.rawResponse,
514
+ });
515
+ }
516
+ });
517
+ }
518
+ _getAuthorizationHeader() {
519
+ return __awaiter(this, void 0, void 0, function* () {
520
+ const bearer = yield core.Supplier.get(this._options.token);
521
+ if (bearer != null) {
522
+ return `Bearer ${bearer}`;
523
+ }
524
+ return undefined;
525
+ });
526
+ }
527
+ }
528
+ exports.AirWaybillStockNumbers = AirWaybillStockNumbers;
@@ -0,0 +1,2 @@
1
+ export {};
2
+ export * from "./requests/index.js";
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./requests/index.js"), exports);
@@ -0,0 +1,12 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * @example
6
+ * {
7
+ * awb_numbers: ["awb_numbers"]
8
+ * }
9
+ */
10
+ export interface AirWaybillStockNumbersAddReq {
11
+ awb_numbers: string[];
12
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,27 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as Chrt from "../../../../../../index.js";
5
+ /**
6
+ * @example
7
+ * {
8
+ * filter_awb_prefix: "filter_awb_prefix",
9
+ * filter_status: ["available"],
10
+ * sort_by: "awb_number",
11
+ * sort_order: "asc",
12
+ * page: 1,
13
+ * page_size: 1
14
+ * }
15
+ */
16
+ export interface AirWaybillStockNumbersListV1Request {
17
+ /** Filter by the airline's 3-digit AWB prefix, e.g. 014. */
18
+ filter_awb_prefix?: string | null;
19
+ /** Filter by status(es). */
20
+ filter_status?: (Chrt.AirWaybillStockNumberStatusEnum1 | null) | (Chrt.AirWaybillStockNumberStatusEnum1 | null)[];
21
+ /** Field to sort by. */
22
+ sort_by?: Chrt.AirWaybillStockNumberSortByEnum | null;
23
+ /** Sort order. */
24
+ sort_order?: Chrt.SortOrderEnum | null;
25
+ page?: number | null;
26
+ page_size?: number | null;
27
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,12 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * @example
6
+ * {
7
+ * awb_numbers: ["awb_numbers"]
8
+ * }
9
+ */
10
+ export interface AirWaybillStockNumbersMarkAvailableReq {
11
+ awb_numbers: string[];
12
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,13 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * @example
6
+ * {
7
+ * awb_numbers: ["awb_numbers"]
8
+ * }
9
+ */
10
+ export interface AirWaybillStockNumbersMarkUsedReq {
11
+ awb_numbers: string[];
12
+ status_note?: string | null;
13
+ }
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,13 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ /**
5
+ * @example
6
+ * {
7
+ * awb_numbers: ["awb_numbers"]
8
+ * }
9
+ */
10
+ export interface AirWaybillStockNumbersVoidReq {
11
+ awb_numbers: string[];
12
+ status_note?: string | null;
13
+ }