@augno/sdk 0.12.4 → 0.12.5

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 (181) hide show
  1. package/CHANGELOG.md +2 -2
  2. package/package.json +1 -1
  3. package/resources/auth/api-keys/api-keys.d.mts +4 -0
  4. package/resources/auth/api-keys/api-keys.d.mts.map +1 -1
  5. package/resources/auth/api-keys/api-keys.d.ts +4 -0
  6. package/resources/auth/api-keys/api-keys.d.ts.map +1 -1
  7. package/resources/auth/api-keys/api-keys.js.map +1 -1
  8. package/resources/auth/api-keys/api-keys.mjs.map +1 -1
  9. package/resources/core/audit-events.d.mts +3 -3
  10. package/resources/core/audit-events.d.mts.map +1 -1
  11. package/resources/core/audit-events.d.ts +3 -3
  12. package/resources/core/audit-events.d.ts.map +1 -1
  13. package/resources/core/core.d.mts +2 -2
  14. package/resources/core/core.d.mts.map +1 -1
  15. package/resources/core/core.d.ts +2 -2
  16. package/resources/core/core.d.ts.map +1 -1
  17. package/resources/core/core.js.map +1 -1
  18. package/resources/core/core.mjs.map +1 -1
  19. package/resources/core/request-logs.d.mts +11 -1
  20. package/resources/core/request-logs.d.mts.map +1 -1
  21. package/resources/core/request-logs.d.ts +11 -1
  22. package/resources/core/request-logs.d.ts.map +1 -1
  23. package/resources/identity/accounts.d.mts +34 -0
  24. package/resources/identity/accounts.d.mts.map +1 -0
  25. package/resources/identity/accounts.d.ts +34 -0
  26. package/resources/identity/accounts.d.ts.map +1 -0
  27. package/resources/identity/accounts.js +35 -0
  28. package/resources/identity/accounts.js.map +1 -0
  29. package/resources/identity/accounts.mjs +31 -0
  30. package/resources/identity/accounts.mjs.map +1 -0
  31. package/resources/identity/identity.d.mts +4 -0
  32. package/resources/identity/identity.d.mts.map +1 -1
  33. package/resources/identity/identity.d.ts +4 -0
  34. package/resources/identity/identity.d.ts.map +1 -1
  35. package/resources/identity/identity.js +4 -0
  36. package/resources/identity/identity.js.map +1 -1
  37. package/resources/identity/identity.mjs +4 -0
  38. package/resources/identity/identity.mjs.map +1 -1
  39. package/resources/identity/index.d.mts +1 -0
  40. package/resources/identity/index.d.mts.map +1 -1
  41. package/resources/identity/index.d.ts +1 -0
  42. package/resources/identity/index.d.ts.map +1 -1
  43. package/resources/identity/index.js +3 -1
  44. package/resources/identity/index.js.map +1 -1
  45. package/resources/identity/index.mjs +1 -0
  46. package/resources/identity/index.mjs.map +1 -1
  47. package/resources/messaging/announcements/announcements.d.mts +1 -1
  48. package/resources/messaging/announcements/announcements.d.mts.map +1 -1
  49. package/resources/messaging/announcements/announcements.d.ts +1 -1
  50. package/resources/messaging/announcements/announcements.d.ts.map +1 -1
  51. package/resources/messaging/announcements/announcements.js.map +1 -1
  52. package/resources/messaging/announcements/announcements.mjs.map +1 -1
  53. package/resources/messaging/conversations/conversations.d.mts +32 -19
  54. package/resources/messaging/conversations/conversations.d.mts.map +1 -1
  55. package/resources/messaging/conversations/conversations.d.ts +32 -19
  56. package/resources/messaging/conversations/conversations.d.ts.map +1 -1
  57. package/resources/messaging/conversations/conversations.js +2 -2
  58. package/resources/messaging/conversations/conversations.js.map +1 -1
  59. package/resources/messaging/conversations/conversations.mjs +2 -2
  60. package/resources/messaging/conversations/conversations.mjs.map +1 -1
  61. package/resources/messaging/conversations/links.d.mts +2 -2
  62. package/resources/messaging/conversations/links.d.mts.map +1 -1
  63. package/resources/messaging/conversations/links.d.ts +2 -2
  64. package/resources/messaging/conversations/links.d.ts.map +1 -1
  65. package/resources/messaging/conversations/messages.d.mts +2 -2
  66. package/resources/messaging/conversations/messages.d.mts.map +1 -1
  67. package/resources/messaging/conversations/messages.d.ts +2 -2
  68. package/resources/messaging/conversations/messages.d.ts.map +1 -1
  69. package/resources/messaging/notifications/notifications.d.mts +6 -6
  70. package/resources/messaging/notifications/notifications.d.mts.map +1 -1
  71. package/resources/messaging/notifications/notifications.d.ts +6 -6
  72. package/resources/messaging/notifications/notifications.d.ts.map +1 -1
  73. package/resources/messaging/notifications/notifications.js.map +1 -1
  74. package/resources/messaging/notifications/notifications.mjs.map +1 -1
  75. package/resources/sales/index.d.mts +1 -1
  76. package/resources/sales/index.d.mts.map +1 -1
  77. package/resources/sales/index.d.ts +1 -1
  78. package/resources/sales/index.d.ts.map +1 -1
  79. package/resources/sales/index.js +2 -2
  80. package/resources/sales/index.js.map +1 -1
  81. package/resources/sales/index.mjs +1 -1
  82. package/resources/sales/index.mjs.map +1 -1
  83. package/resources/sales/sales-orders/actions.d.mts +255 -0
  84. package/resources/sales/sales-orders/actions.d.mts.map +1 -0
  85. package/resources/sales/sales-orders/actions.d.ts +255 -0
  86. package/resources/sales/sales-orders/actions.d.ts.map +1 -0
  87. package/resources/sales/sales-orders/actions.js +156 -0
  88. package/resources/sales/sales-orders/actions.js.map +1 -0
  89. package/resources/sales/sales-orders/actions.mjs +152 -0
  90. package/resources/sales/sales-orders/actions.mjs.map +1 -0
  91. package/resources/sales/sales-orders/index.d.mts +4 -0
  92. package/resources/sales/sales-orders/index.d.mts.map +1 -0
  93. package/resources/sales/sales-orders/index.d.ts +4 -0
  94. package/resources/sales/sales-orders/index.d.ts.map +1 -0
  95. package/resources/sales/sales-orders/index.js +11 -0
  96. package/resources/sales/sales-orders/index.js.map +1 -0
  97. package/resources/sales/sales-orders/index.mjs +5 -0
  98. package/resources/sales/sales-orders/index.mjs.map +1 -0
  99. package/resources/sales/sales-orders/lines/actions.d.mts +56 -0
  100. package/resources/sales/sales-orders/lines/actions.d.mts.map +1 -0
  101. package/resources/sales/sales-orders/lines/actions.d.ts +56 -0
  102. package/resources/sales/sales-orders/lines/actions.d.ts.map +1 -0
  103. package/resources/sales/sales-orders/lines/actions.js +38 -0
  104. package/resources/sales/sales-orders/lines/actions.js.map +1 -0
  105. package/resources/sales/sales-orders/lines/actions.mjs +34 -0
  106. package/resources/sales/sales-orders/lines/actions.mjs.map +1 -0
  107. package/resources/sales/sales-orders/lines/index.d.mts +3 -0
  108. package/resources/sales/sales-orders/lines/index.d.mts.map +1 -0
  109. package/resources/sales/sales-orders/lines/index.d.ts +3 -0
  110. package/resources/sales/sales-orders/lines/index.d.ts.map +1 -0
  111. package/resources/sales/sales-orders/lines/index.js +9 -0
  112. package/resources/sales/sales-orders/lines/index.js.map +1 -0
  113. package/resources/sales/sales-orders/lines/index.mjs +4 -0
  114. package/resources/sales/sales-orders/lines/index.mjs.map +1 -0
  115. package/resources/sales/sales-orders/lines/lines.d.mts +208 -0
  116. package/resources/sales/sales-orders/lines/lines.d.mts.map +1 -0
  117. package/resources/sales/sales-orders/lines/lines.d.ts +208 -0
  118. package/resources/sales/sales-orders/lines/lines.d.ts.map +1 -0
  119. package/resources/sales/sales-orders/lines/lines.js +100 -0
  120. package/resources/sales/sales-orders/lines/lines.js.map +1 -0
  121. package/resources/sales/sales-orders/lines/lines.mjs +95 -0
  122. package/resources/sales/sales-orders/lines/lines.mjs.map +1 -0
  123. package/resources/sales/sales-orders/lines.d.mts +2 -0
  124. package/resources/sales/sales-orders/lines.d.mts.map +1 -0
  125. package/resources/sales/sales-orders/lines.d.ts +2 -0
  126. package/resources/sales/sales-orders/lines.d.ts.map +1 -0
  127. package/resources/sales/sales-orders/lines.js +6 -0
  128. package/resources/sales/sales-orders/lines.js.map +1 -0
  129. package/resources/sales/sales-orders/lines.mjs +3 -0
  130. package/resources/sales/sales-orders/lines.mjs.map +1 -0
  131. package/resources/sales/sales-orders/sales-orders.d.mts +1466 -0
  132. package/resources/sales/sales-orders/sales-orders.d.mts.map +1 -0
  133. package/resources/sales/sales-orders/sales-orders.d.ts +1466 -0
  134. package/resources/sales/sales-orders/sales-orders.d.ts.map +1 -0
  135. package/resources/sales/sales-orders/sales-orders.js +199 -0
  136. package/resources/sales/sales-orders/sales-orders.js.map +1 -0
  137. package/resources/sales/sales-orders/sales-orders.mjs +194 -0
  138. package/resources/sales/sales-orders/sales-orders.mjs.map +1 -0
  139. package/resources/sales/sales-orders.d.mts +1 -980
  140. package/resources/sales/sales-orders.d.mts.map +1 -1
  141. package/resources/sales/sales-orders.d.ts +1 -980
  142. package/resources/sales/sales-orders.d.ts.map +1 -1
  143. package/resources/sales/sales-orders.js +2 -76
  144. package/resources/sales/sales-orders.js.map +1 -1
  145. package/resources/sales/sales-orders.mjs +1 -74
  146. package/resources/sales/sales-orders.mjs.map +1 -1
  147. package/resources/sales/sales.d.mts +3 -3
  148. package/resources/sales/sales.d.mts.map +1 -1
  149. package/resources/sales/sales.d.ts +3 -3
  150. package/resources/sales/sales.d.ts.map +1 -1
  151. package/resources/sales/sales.js +2 -2
  152. package/resources/sales/sales.js.map +1 -1
  153. package/resources/sales/sales.mjs +2 -2
  154. package/resources/sales/sales.mjs.map +1 -1
  155. package/src/resources/auth/api-keys/api-keys.ts +5 -0
  156. package/src/resources/core/audit-events.ts +40 -7
  157. package/src/resources/core/core.ts +27 -5
  158. package/src/resources/core/request-logs.ts +46 -0
  159. package/src/resources/identity/accounts.ts +40 -0
  160. package/src/resources/identity/identity.ts +6 -0
  161. package/src/resources/identity/index.ts +1 -0
  162. package/src/resources/messaging/announcements/announcements.ts +2 -1
  163. package/src/resources/messaging/conversations/conversations.ts +75 -27
  164. package/src/resources/messaging/conversations/links.ts +28 -6
  165. package/src/resources/messaging/conversations/messages.ts +28 -6
  166. package/src/resources/messaging/notifications/notifications.ts +36 -10
  167. package/src/resources/sales/index.ts +16 -1
  168. package/src/resources/sales/sales-orders/actions.ts +316 -0
  169. package/src/resources/sales/sales-orders/index.ts +60 -0
  170. package/src/resources/sales/sales-orders/lines/actions.ts +72 -0
  171. package/src/resources/sales/sales-orders/lines/index.ts +17 -0
  172. package/src/resources/sales/sales-orders/lines/lines.ts +284 -0
  173. package/src/resources/sales/sales-orders/lines.ts +3 -0
  174. package/src/resources/sales/sales-orders/sales-orders.ts +1934 -0
  175. package/src/resources/sales/sales-orders.ts +1 -1239
  176. package/src/resources/sales/sales.ts +54 -24
  177. package/src/version.ts +1 -1
  178. package/version.d.mts +1 -1
  179. package/version.d.ts +1 -1
  180. package/version.js +1 -1
  181. package/version.mjs +1 -1
@@ -0,0 +1,1934 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../../core/resource';
4
+ import * as MaterialsAPI from '../../catalog/materials';
5
+ import * as ProductsAPI from '../../catalog/products';
6
+ import * as UnitsAPI from '../../catalog/units';
7
+ import * as RequestLogsAPI from '../../core/request-logs';
8
+ import * as APIKeysAPI from '../../auth/api-keys/api-keys';
9
+ import * as ItemsAPI from '../../catalog/items/items';
10
+ import * as CustomersAPI from '../customers/customers';
11
+ import * as ActionsAPI from './actions';
12
+ import {
13
+ ActionBulkDeleteParams,
14
+ ActionBulkDeleteResponse,
15
+ ActionCreateProductionRunParams,
16
+ ActionIssueParams,
17
+ Actions,
18
+ BulkDeleteSalesOrdersRequest,
19
+ IssueSalesOrderRequest,
20
+ ProductionRun,
21
+ QuoteSalesOrderFreightResponse,
22
+ } from './actions';
23
+ import * as LinesAPI from './lines/lines';
24
+ import {
25
+ CreateSalesOrderLineRequest,
26
+ LineCreateParams,
27
+ LineDeleteParams,
28
+ LineDeleteResponse,
29
+ LineUpdateParams,
30
+ Lines,
31
+ UpdateSalesOrderLineRequest,
32
+ } from './lines/lines';
33
+ import { APIPromise } from '../../../core/api-promise';
34
+ import { RequestOptions } from '../../../internal/request-options';
35
+ import { path } from '../../../internal/utils/path';
36
+
37
+ export class SalesOrders extends APIResource {
38
+ actions: ActionsAPI.Actions = new ActionsAPI.Actions(this._client);
39
+ lines: LinesAPI.Lines = new LinesAPI.Lines(this._client);
40
+
41
+ /**
42
+ * Returns a paginated list of sales order statuses.
43
+ *
44
+ * @example
45
+ * ```ts
46
+ * const listSalesOrderStatus =
47
+ * await client.sales.salesOrders.retrieveStatuses();
48
+ * ```
49
+ */
50
+ retrieveStatuses(
51
+ query: SalesOrderRetrieveStatusesParams | null | undefined = {},
52
+ options?: RequestOptions,
53
+ ): APIPromise<ListSalesOrderStatus> {
54
+ return this._client.get('/v1/sales/sales-orders/statuses', { query, ...options });
55
+ }
56
+
57
+ /**
58
+ * Returns a paginated list of sales orders for the current account.
59
+ *
60
+ * This endpoint requires the permissions: `sales_orders:read`, `customers:read`,
61
+ * `suppliers:read`.
62
+ *
63
+ * @example
64
+ * ```ts
65
+ * const listSalesOrder =
66
+ * await client.sales.salesOrders.list();
67
+ * ```
68
+ */
69
+ list(
70
+ query: SalesOrderListParams | null | undefined = {},
71
+ options?: RequestOptions,
72
+ ): APIPromise<ListSalesOrder> {
73
+ return this._client.get('/v1/sales/sales-orders', { query, ...options });
74
+ }
75
+
76
+ /**
77
+ * Returns a sales order by ID.
78
+ *
79
+ * This endpoint requires the permissions: `customers:read`, `suppliers:read`,
80
+ * `sales_orders:read`.
81
+ *
82
+ * @example
83
+ * ```ts
84
+ * const salesOrder = await client.sales.salesOrders.retrieve(
85
+ * 'or_01d5034136c3ccc048abecc312',
86
+ * );
87
+ * ```
88
+ */
89
+ retrieve(
90
+ id: string,
91
+ query: SalesOrderRetrieveParams | null | undefined = {},
92
+ options?: RequestOptions,
93
+ ): APIPromise<SalesOrder> {
94
+ return this._client.get(path`/v1/sales/sales-orders/${id}`, { query, ...options });
95
+ }
96
+
97
+ /**
98
+ * Creates a sales order in `estimate` status.
99
+ *
100
+ * The order number is assigned automatically, and a sales rep is auto-assigned
101
+ * when none is provided. A shipping line is always added to the order, plus a
102
+ * discount line when an order discount is supplied.
103
+ *
104
+ * This endpoint requires the permission: `sales_orders:create`.
105
+ *
106
+ * @example
107
+ * ```ts
108
+ * const salesOrder = await client.sales.salesOrders.create({
109
+ * bill_to_address_id: 'ad_012c2e4aeeb20f56c1a3d06cc7',
110
+ * buyer_account_id: 'ac_0170df1ac58e4d24c66fc89f5f',
111
+ * lines: [
112
+ * {
113
+ * product_id: 'pd_013c29ab3f1518d0004094c316',
114
+ * quantity: { ... },
115
+ * },
116
+ * ],
117
+ * priority_code: 'normal',
118
+ * ship_to_address_id: 'ad_012c2e4aeeb20f56c1a3d06cc7',
119
+ * acknowledgement_email_contacts: [
120
+ * { account_user_id: 'acus_01ea9983ddb41dacc44ecf997c' },
121
+ * ],
122
+ * carrier_billing_account_number: '123456789',
123
+ * carrier_billing_type: 'sender',
124
+ * carrier_id: 'cr_01784fd54c9ba197bb4e42f0e6',
125
+ * customer_purchase_order_number: 'PO-88231',
126
+ * invoice_email_contacts: [{ account_user_id: 'acus_01ea9983ddb41dacc44ecf997c' }],
127
+ * note: 'Rush order for trade show',
128
+ * order_discount_id: 'ords_01121c5e2f6937a6b896daad3a',
129
+ * payment_term_id: 'pytm_018694d6601ea771cd1b52e890',
130
+ * promised_at: '2026-05-20T00:00:00Z',
131
+ * sales_rep_id: 'acus_01ea9983ddb41dacc44ecf997c',
132
+ * service_level_id: 'crop_01cfaf03f104e90ef9680e2a30',
133
+ * shipping_term_id: 'shtm_014341ab4bb5bf94d5b6936f86',
134
+ * });
135
+ * ```
136
+ */
137
+ create(params: SalesOrderCreateParams, options?: RequestOptions): APIPromise<SalesOrder> {
138
+ const { include, ...body } = params;
139
+ return this._client.post('/v1/sales/sales-orders', { query: { include }, body, ...options });
140
+ }
141
+
142
+ /**
143
+ * Partially updates a sales order.
144
+ *
145
+ * This endpoint requires the permission: `sales_orders:update`.
146
+ *
147
+ * @example
148
+ * ```ts
149
+ * const salesOrder = await client.sales.salesOrders.update(
150
+ * 'or_01d5034136c3ccc048abecc312',
151
+ * {
152
+ * carrier_id: 'cr_01784fd54c9ba197bb4e42f0e6',
153
+ * note: 'Updated shipping instructions',
154
+ * priority_code: 'normal',
155
+ * shipping_address_id: 'ad_012c2e4aeeb20f56c1a3d06cc7',
156
+ * },
157
+ * );
158
+ * ```
159
+ */
160
+ update(
161
+ id: string,
162
+ params: SalesOrderUpdateParams | null | undefined = {},
163
+ options?: RequestOptions,
164
+ ): APIPromise<SalesOrder> {
165
+ const { include, ...body } = params ?? {};
166
+ return this._client.patch(path`/v1/sales/sales-orders/${id}`, { query: { include }, body, ...options });
167
+ }
168
+
169
+ /**
170
+ * Deletes a sales order and all its related records.
171
+ *
172
+ * Fulfilled orders cannot be deleted.
173
+ *
174
+ * This endpoint requires the permission: `sales_orders:delete`.
175
+ *
176
+ * @example
177
+ * ```ts
178
+ * const salesOrder = await client.sales.salesOrders.delete(
179
+ * 'or_01d5034136c3ccc048abecc312',
180
+ * );
181
+ * ```
182
+ */
183
+ delete(id: string, options?: RequestOptions): APIPromise<SalesOrderDeleteResponse> {
184
+ return this._client.delete(path`/v1/sales/sales-orders/${id}`, options);
185
+ }
186
+
187
+ /**
188
+ * Creates a hosted payment checkout session for a sales order.
189
+ *
190
+ * Requires an active Stripe integration on the account. The checkout is built from
191
+ * the order's lines, and the checkout link is emailed to the provided address.
192
+ * Fails with a conflict if the order already has a payment.
193
+ *
194
+ * This endpoint requires the permission: `sales_orders:update`.
195
+ *
196
+ * @example
197
+ * ```ts
198
+ * const checkoutSalesOrderResponse =
199
+ * await client.sales.salesOrders.checkout(
200
+ * 'or_01d5034136c3ccc048abecc312',
201
+ * { email: 'operations@acme.example.com' },
202
+ * );
203
+ * ```
204
+ */
205
+ checkout(
206
+ id: string,
207
+ body: SalesOrderCheckoutParams,
208
+ options?: RequestOptions,
209
+ ): APIPromise<CheckoutSalesOrderResponse> {
210
+ return this._client.post(path`/v1/sales/sales-orders/${id}/checkout`, { body, ...options });
211
+ }
212
+
213
+ /**
214
+ * Calculates the unit price for each line without creating an order.
215
+ *
216
+ * Use this to display prices to users as they build an order. Prices are computed
217
+ * server-side from the product's list price, contracted account prices, and
218
+ * applicable discounts — the same logic used when an order is created. Internal
219
+ * price overrides are not accepted here; the calculated price is always returned.
220
+ *
221
+ * This endpoint requires the permission: `sales_orders:read`.
222
+ *
223
+ * @example
224
+ * ```ts
225
+ * const quoteSalesOrderPricesResponse =
226
+ * await client.sales.salesOrders.priceQuote({
227
+ * buyer_account_id: 'ac_0170df1ac58e4d24c66fc89f5f',
228
+ * lines: [
229
+ * {
230
+ * product_id: 'pd_013c29ab3f1518d0004094c316',
231
+ * quantity: {
232
+ * value: '10',
233
+ * unit_id: 'un_01966263f74a5a0cae356000a1',
234
+ * },
235
+ * },
236
+ * ],
237
+ * });
238
+ * ```
239
+ */
240
+ priceQuote(
241
+ body: SalesOrderPriceQuoteParams,
242
+ options?: RequestOptions,
243
+ ): APIPromise<QuoteSalesOrderPricesResponse> {
244
+ return this._client.post('/v1/sales/sales-orders/price-quote', { body, ...options });
245
+ }
246
+ }
247
+
248
+ /**
249
+ * Request to create a checkout session for a sales order.
250
+ */
251
+ export interface CheckoutSalesOrderRequest {
252
+ /**
253
+ * Email address to send the checkout link to.
254
+ *
255
+ * Also set as the customer email on the payment provider's checkout session.
256
+ */
257
+ email: string;
258
+ }
259
+
260
+ /**
261
+ * Checkout session result.
262
+ */
263
+ export interface CheckoutSalesOrderResponse {
264
+ /**
265
+ * URL of the hosted payment page where the customer completes the checkout.
266
+ */
267
+ checkout_url: string;
268
+
269
+ /**
270
+ * Resource type identifier.
271
+ */
272
+ object: 'checkout_sales_order';
273
+ }
274
+
275
+ /**
276
+ * Line item input for a create sales order request.
277
+ *
278
+ * The item, unit cost, and (unless an internal user supplies a `unit_price`
279
+ * override) the unit price are resolved server-side from the product. The quantity
280
+ * unit must belong to the product's unit group.
281
+ */
282
+ export interface CreateSalesOrderLineInput {
283
+ /**
284
+ * ID of the product being ordered.
285
+ */
286
+ product_id: string;
287
+
288
+ /**
289
+ * A value with an associated unit, used in create and update requests.
290
+ */
291
+ quantity: CustomersAPI.QuantityInput;
292
+
293
+ /**
294
+ * Description recorded on the line.
295
+ *
296
+ * Defaults to the product's description when omitted.
297
+ */
298
+ product_description?: string;
299
+
300
+ /**
301
+ * SKU recorded on the line.
302
+ *
303
+ * Defaults to the product's SKU when omitted.
304
+ */
305
+ product_sku?: string;
306
+
307
+ /**
308
+ * A rate value with its numerator and denominator units, used in create and update
309
+ * requests.
310
+ */
311
+ unit_price?: MaterialsAPI.RateInput;
312
+ }
313
+
314
+ /**
315
+ * Request to create a sales order.
316
+ */
317
+ export interface CreateSalesOrderRequest {
318
+ /**
319
+ * Bill-to address ID.
320
+ *
321
+ * Must reference an existing address on the order's owner or buyer account.
322
+ */
323
+ bill_to_address_id: string;
324
+
325
+ /**
326
+ * ID of the customer account the order is for.
327
+ */
328
+ buyer_account_id: string;
329
+
330
+ /**
331
+ * Order lines to create.
332
+ */
333
+ lines: Array<CreateSalesOrderLineInput>;
334
+
335
+ /**
336
+ * Fulfillment priority used to rank the order on the shop floor.
337
+ */
338
+ priority_code: string;
339
+
340
+ /**
341
+ * Ship-to address ID.
342
+ *
343
+ * Must reference an existing address on the order's owner or buyer account.
344
+ */
345
+ ship_to_address_id: string;
346
+
347
+ /**
348
+ * Account users who should receive order acknowledgement emails.
349
+ */
350
+ acknowledgement_email_contacts?: Array<SalesOrderEmailContactInput>;
351
+
352
+ /**
353
+ * Carrier billing account number.
354
+ */
355
+ carrier_billing_account_number?: string;
356
+
357
+ /**
358
+ * Who is billed for freight.
359
+ *
360
+ * - `sender`: the sender pays for shipping.
361
+ * - `third_party`: a third party pays for shipping, using the carrier billing
362
+ * account number.
363
+ */
364
+ carrier_billing_type?: 'sender' | 'third_party';
365
+
366
+ /**
367
+ * Carrier ID.
368
+ */
369
+ carrier_id?: string;
370
+
371
+ /**
372
+ * The customer's own purchase order number, for cross-referencing.
373
+ *
374
+ * Must be unique among your orders for this customer.
375
+ */
376
+ customer_purchase_order_number?: string;
377
+
378
+ /**
379
+ * Account users who should receive invoice emails.
380
+ */
381
+ invoice_email_contacts?: Array<SalesOrderEmailContactInput>;
382
+
383
+ /**
384
+ * Order note.
385
+ */
386
+ note?: string;
387
+
388
+ /**
389
+ * Order discount ID.
390
+ *
391
+ * When supplied, a discount line is added to the order automatically.
392
+ */
393
+ order_discount_id?: string;
394
+
395
+ /**
396
+ * Payment term ID.
397
+ */
398
+ payment_term_id?: string;
399
+
400
+ /**
401
+ * Promised delivery date.
402
+ */
403
+ promised_at?: string;
404
+
405
+ /**
406
+ * Sales rep ID.
407
+ *
408
+ * When omitted, a rep is assigned automatically: the customer's default sales rep
409
+ * first, then the sales territory matching the ship-to postal code, then the
410
+ * ship-to state.
411
+ */
412
+ sales_rep_id?: string;
413
+
414
+ /**
415
+ * Service level ID.
416
+ */
417
+ service_level_id?: string;
418
+
419
+ /**
420
+ * Shipping term ID.
421
+ */
422
+ shipping_term_id?: string;
423
+ }
424
+
425
+ /**
426
+ * CreatedBy describes who created a resource and their relationship to the account
427
+ * that owns it.
428
+ *
429
+ * It is resolved from the resource's create audit event.
430
+ */
431
+ export interface CreatedBy {
432
+ /**
433
+ * Reference to an actor — the user, API key, agent, or group identity associated
434
+ * with an action.
435
+ */
436
+ actor: RequestLogsAPI.Actor | null;
437
+
438
+ /**
439
+ * Resource type identifier.
440
+ */
441
+ object: 'created_by';
442
+
443
+ /**
444
+ * The creator's relationship to the account that owns the resource.
445
+ *
446
+ * - `internal`: created by a user of the owning account.
447
+ * - `customer`: created by a customer of the owning account.
448
+ * - `system`: created automatically with no human actor (e.g. an EDI import).
449
+ */
450
+ relation: 'internal' | 'customer' | 'system';
451
+ }
452
+
453
+ /**
454
+ * Freight describes the carrier selection and freight billing for a record.
455
+ *
456
+ * It is a generic, reusable sub-resource shared by anything that carries shipping
457
+ * configuration — for example a sales order's chosen freight, or a customer's
458
+ * default freight preferences.
459
+ */
460
+ export interface Freight {
461
+ /**
462
+ * Carrier account number to bill, used when `billing_type` is `third_party`.
463
+ */
464
+ billing_account_number: string | null;
465
+
466
+ /**
467
+ * Which party the carrier bills for the shipment.
468
+ *
469
+ * - `sender`: the shipper (your account) is billed.
470
+ * - `third_party`: a third party is billed via `billing_account_number`.
471
+ */
472
+ billing_type: 'sender' | 'third_party' | null;
473
+
474
+ /**
475
+ * A shipping carrier configured for fulfilling orders.
476
+ *
477
+ * Carriers with a Shippo-supported `code` (`fedex`, `ups`, `usps`) are connected
478
+ * through Shippo for live rating and label purchase; other carriers represent
479
+ * self-managed shipping methods such as will call or local delivery.
480
+ */
481
+ carrier: CustomersAPI.Carrier | null;
482
+
483
+ /**
484
+ * Resource type identifier.
485
+ */
486
+ object: 'freight';
487
+
488
+ /**
489
+ * How freight is arranged and billed for the record.
490
+ *
491
+ * Populated where a freight policy applies, such as a customer's default
492
+ * preferences.
493
+ *
494
+ * - `free_freight`: no shipping cost to the buyer.
495
+ * - `billed_freight`: freight is billed to the buyer.
496
+ */
497
+ policy: 'free_freight' | 'billed_freight' | null;
498
+
499
+ /**
500
+ * Shipping service level for a carrier.
501
+ */
502
+ service_level: CustomersAPI.ServiceLevel | null;
503
+ }
504
+
505
+ /**
506
+ * List represents a paginated list of resources.
507
+ */
508
+ export interface ListQuotedSalesOrderLine {
509
+ /**
510
+ * Resources in this page.
511
+ */
512
+ data: Array<QuotedSalesOrderLine>;
513
+
514
+ /**
515
+ * Resource type identifier.
516
+ */
517
+ object: 'list';
518
+
519
+ /**
520
+ * PageInfo contains URL-based pagination metadata.
521
+ */
522
+ page_info: APIKeysAPI.PageInfo;
523
+ }
524
+
525
+ /**
526
+ * List represents a paginated list of resources.
527
+ */
528
+ export interface ListRecord {
529
+ /**
530
+ * Resources in this page.
531
+ */
532
+ data: Array<Record>;
533
+
534
+ /**
535
+ * Resource type identifier.
536
+ */
537
+ object: 'list';
538
+
539
+ /**
540
+ * PageInfo contains URL-based pagination metadata.
541
+ */
542
+ page_info: APIKeysAPI.PageInfo;
543
+ }
544
+
545
+ /**
546
+ * List represents a paginated list of resources.
547
+ */
548
+ export interface ListSalesOrder {
549
+ /**
550
+ * Resources in this page.
551
+ */
552
+ data: Array<SalesOrder>;
553
+
554
+ /**
555
+ * Resource type identifier.
556
+ */
557
+ object: 'list';
558
+
559
+ /**
560
+ * PageInfo contains URL-based pagination metadata.
561
+ */
562
+ page_info: APIKeysAPI.PageInfo;
563
+ }
564
+
565
+ /**
566
+ * List represents a paginated list of resources.
567
+ */
568
+ export interface ListSalesOrderLine {
569
+ /**
570
+ * Resources in this page.
571
+ */
572
+ data: Array<SalesOrderLine>;
573
+
574
+ /**
575
+ * Resource type identifier.
576
+ */
577
+ object: 'list';
578
+
579
+ /**
580
+ * PageInfo contains URL-based pagination metadata.
581
+ */
582
+ page_info: APIKeysAPI.PageInfo;
583
+ }
584
+
585
+ /**
586
+ * List represents a paginated list of resources.
587
+ */
588
+ export interface ListSalesOrderStatus {
589
+ /**
590
+ * Resources in this page.
591
+ */
592
+ data: Array<SalesOrderStatus>;
593
+
594
+ /**
595
+ * Resource type identifier.
596
+ */
597
+ object: 'list';
598
+
599
+ /**
600
+ * PageInfo contains URL-based pagination metadata.
601
+ */
602
+ page_info: APIKeysAPI.PageInfo;
603
+ }
604
+
605
+ /**
606
+ * OrderContact groups a sales order's email recipients by notification purpose.
607
+ */
608
+ export interface OrderContact {
609
+ /**
610
+ * Email addresses that receive order acknowledgements for this order.
611
+ */
612
+ acknowledgement: Array<string>;
613
+
614
+ /**
615
+ * Email addresses that receive invoices for this order.
616
+ */
617
+ invoice: Array<string>;
618
+
619
+ /**
620
+ * Resource type identifier.
621
+ */
622
+ object: 'order_contact';
623
+ }
624
+
625
+ /**
626
+ * A discount code that can be applied to a sales order.
627
+ *
628
+ * An order discount reduces the order total by either a percentage or a fixed
629
+ * amount, depending on `discount_type`.
630
+ */
631
+ export interface OrderDiscount {
632
+ /**
633
+ * Order discount ID.
634
+ */
635
+ id: string;
636
+
637
+ /**
638
+ * Fixed amount off as a decimal string.
639
+ *
640
+ * Applies when `discount_type` is `amount`; otherwise `0`.
641
+ */
642
+ amount: string;
643
+
644
+ /**
645
+ * The code entered to apply this discount to an order.
646
+ *
647
+ * Must be unique within the account.
648
+ */
649
+ code: string;
650
+
651
+ /**
652
+ * Creation timestamp.
653
+ */
654
+ created_at: string;
655
+
656
+ /**
657
+ * How the discount is calculated, determining whether `percentage` or `amount` is
658
+ * used.
659
+ *
660
+ * - `percentage`: the discount is a percent off, taken from `percentage`.
661
+ * - `amount`: the discount is a fixed amount off, taken from `amount`.
662
+ */
663
+ discount_type: 'percentage' | 'amount';
664
+
665
+ /**
666
+ * Display name of the discount.
667
+ */
668
+ name: string;
669
+
670
+ /**
671
+ * Resource type identifier.
672
+ */
673
+ object: 'order_discount';
674
+
675
+ /**
676
+ * Number of orders currently using this discount.
677
+ */
678
+ order_count: number;
679
+
680
+ /**
681
+ * Percent off as a decimal string (e.g. `10` for 10%).
682
+ *
683
+ * Applies when `discount_type` is `percentage`; otherwise `0`.
684
+ */
685
+ percentage: string;
686
+
687
+ /**
688
+ * Last updated timestamp.
689
+ */
690
+ updated_at: string;
691
+ }
692
+
693
+ /**
694
+ * A line to price in a quote request.
695
+ */
696
+ export interface QuoteSalesOrderLineInput {
697
+ /**
698
+ * ID of the product to price.
699
+ */
700
+ product_id: string;
701
+
702
+ /**
703
+ * A value with an associated unit, used in create and update requests.
704
+ */
705
+ quantity: CustomersAPI.QuantityInput;
706
+ }
707
+
708
+ /**
709
+ * Request to quote sales-order line prices without creating an order.
710
+ */
711
+ export interface QuoteSalesOrderPricesRequest {
712
+ /**
713
+ * ID of the customer account the prices are for.
714
+ */
715
+ buyer_account_id: string;
716
+
717
+ /**
718
+ * Lines to price.
719
+ */
720
+ lines: Array<QuoteSalesOrderLineInput>;
721
+ }
722
+
723
+ /**
724
+ * Quoted unit prices for the requested lines, in request order.
725
+ */
726
+ export interface QuoteSalesOrderPricesResponse {
727
+ /**
728
+ * List represents a paginated list of resources.
729
+ */
730
+ lines: ListQuotedSalesOrderLine | null;
731
+
732
+ /**
733
+ * Resource type identifier.
734
+ */
735
+ object: 'sales_order_price_quote';
736
+ }
737
+
738
+ /**
739
+ * One priced line in a quote response.
740
+ */
741
+ export interface QuotedSalesOrderLine {
742
+ /**
743
+ * Resource type identifier.
744
+ */
745
+ object: 'sales_order_price_quote_line';
746
+
747
+ /**
748
+ * Product pairs an inventory item with how it is sold: its product type, optional
749
+ * product line, and customer portal visibility.
750
+ */
751
+ product: ProductsAPI.Product | null;
752
+
753
+ /**
754
+ * A per-unit rate on a sales-order quote.
755
+ *
756
+ * A lightweight, unpersisted variant of a rate: it carries no ID or timestamps
757
+ * because a quote is computed on demand and never stored.
758
+ */
759
+ unit_price: SalesOrderQuoteRate | null;
760
+ }
761
+
762
+ /**
763
+ * Record is a lightweight reference to a business record — a sales order, purchase
764
+ * order, pick, shipment, production run, invoice, etc.
765
+ *
766
+ * Like Actor and Entity, it carries just enough to identify and label the
767
+ * referenced record without embedding its full resource. The optional status and
768
+ * metadata fields hold type-specific detail that varies by the kind of record
769
+ * referenced.
770
+ */
771
+ export interface Record {
772
+ /**
773
+ * Unique identifier for the record.
774
+ */
775
+ id: string;
776
+
777
+ /**
778
+ * Type-specific metadata.
779
+ *
780
+ * The set of keys varies by record type.
781
+ */
782
+ metadata: { [key: string]: string };
783
+
784
+ /**
785
+ * Human-readable record number, when the record has one.
786
+ */
787
+ number: string | null;
788
+
789
+ /**
790
+ * Resource type identifier.
791
+ */
792
+ object: 'record';
793
+
794
+ /**
795
+ * Type-specific status code, when applicable.
796
+ */
797
+ status: string | null;
798
+
799
+ /**
800
+ * The kind of business record referenced.
801
+ *
802
+ * Determines how to resolve the record and which `status` and `metadata` keys may
803
+ * appear.
804
+ *
805
+ * - `sales_order`: a customer order.
806
+ * - `purchase_order`: an order placed with a supplier.
807
+ * - `receiving_order`: an inbound order being received into inventory.
808
+ * - `pick`: a warehouse pick task.
809
+ * - `shipment`: an outbound shipment.
810
+ * - `delivery`: a delivery of one or more shipments to a destination.
811
+ * - `production_run`: a manufacturing production run.
812
+ * - `invoice`: a customer invoice.
813
+ * - `transaction`: a payment or financial transaction.
814
+ * - `settlement`: a settlement reconciling transactions against invoices.
815
+ */
816
+ type:
817
+ | 'sales_order'
818
+ | 'purchase_order'
819
+ | 'receiving_order'
820
+ | 'pick'
821
+ | 'shipment'
822
+ | 'delivery'
823
+ | 'production_run'
824
+ | 'invoice'
825
+ | 'transaction'
826
+ | 'settlement';
827
+ }
828
+
829
+ /**
830
+ * Full sales order resource.
831
+ */
832
+ export interface SalesOrder {
833
+ /**
834
+ * Sales order ID.
835
+ */
836
+ id: string;
837
+
838
+ /**
839
+ * Whether an order acknowledgment has been sent to the customer.
840
+ */
841
+ acknowledgment_status: 'not_sent' | 'sent';
842
+
843
+ /**
844
+ * A saved address that can be used for billing and shipping on sales orders,
845
+ * invoices, and shipments.
846
+ */
847
+ bill_to_address: APIKeysAPI.Address | null;
848
+
849
+ /**
850
+ * When the order was fulfilled and closed.
851
+ */
852
+ completed_at: string | null;
853
+
854
+ /**
855
+ * OrderContact groups a sales order's email recipients by notification purpose.
856
+ */
857
+ contacts: OrderContact | null;
858
+
859
+ /**
860
+ * Creation timestamp.
861
+ */
862
+ created_at: string;
863
+
864
+ /**
865
+ * CreatedBy describes who created a resource and their relationship to the account
866
+ * that owns it.
867
+ *
868
+ * It is resolved from the resource's create audit event.
869
+ */
870
+ created_by: CreatedBy | null;
871
+
872
+ /**
873
+ * A business you sell to, with its contact details, default fulfillment settings,
874
+ * and order policies.
875
+ */
876
+ customer: CustomersAPI.Customer | null;
877
+
878
+ /**
879
+ * The customer's own purchase order number, for cross-referencing.
880
+ *
881
+ * Unique among this customer's orders.
882
+ */
883
+ customer_purchase_order_number: string | null;
884
+
885
+ /**
886
+ * When this estimate expires, if an expiration was set.
887
+ */
888
+ expired_at: string | null;
889
+
890
+ /**
891
+ * When the first shipment against this order went out.
892
+ */
893
+ first_ship_at: string | null;
894
+
895
+ /**
896
+ * Freight describes the carrier selection and freight billing for a record.
897
+ *
898
+ * It is a generic, reusable sub-resource shared by anything that carries shipping
899
+ * configuration — for example a sales order's chosen freight, or a customer's
900
+ * default freight preferences.
901
+ */
902
+ freight: Freight | null;
903
+
904
+ /**
905
+ * When the order was issued (moved out of `estimate`).
906
+ */
907
+ issued_at: string | null;
908
+
909
+ /**
910
+ * Number of order lines on this order, returned even when the `lines` list itself
911
+ * is not expanded.
912
+ */
913
+ line_count: number;
914
+
915
+ /**
916
+ * List represents a paginated list of resources.
917
+ */
918
+ lines: ListSalesOrderLine | null;
919
+
920
+ /**
921
+ * Order note.
922
+ */
923
+ note: string | null;
924
+
925
+ /**
926
+ * Human-readable order number, e.g. `SO-001`.
927
+ *
928
+ * Assigned automatically when the order is created; unique within your account.
929
+ */
930
+ number: string;
931
+
932
+ /**
933
+ * Resource type identifier.
934
+ */
935
+ object: 'sales_order';
936
+
937
+ /**
938
+ * A discount code that can be applied to a sales order.
939
+ *
940
+ * An order discount reduces the order total by either a percentage or a fixed
941
+ * amount, depending on `discount_type`.
942
+ */
943
+ order_discount: OrderDiscount | null;
944
+
945
+ /**
946
+ * Stripe payment intent IDs recorded against this order.
947
+ */
948
+ payment_intent_ids: Array<string>;
949
+
950
+ /**
951
+ * Payment state of the order, derived from settlement allocations, invoices, and
952
+ * Stripe payments.
953
+ */
954
+ payment_status: 'unpaid' | 'partially_paid' | 'paid';
955
+
956
+ /**
957
+ * A payment term describing when payment is due (e.g. `Net 30`), assignable to
958
+ * customers, sales orders, purchase orders, and invoices.
959
+ */
960
+ payment_term: CustomersAPI.PaymentTerm | null;
961
+
962
+ /**
963
+ * Fulfillment priority, used to rank orders on the shop floor.
964
+ */
965
+ priority: 'low' | 'normal' | 'high';
966
+
967
+ /**
968
+ * Date promised to the customer for delivery, if one was committed.
969
+ */
970
+ promised_at: string | null;
971
+
972
+ /**
973
+ * SalesOrderRelated groups the records related to a sales order.
974
+ *
975
+ * The members are individually expandable (e.g. include[]=related.pick). The group
976
+ * is null unless at least one of its members is expanded.
977
+ */
978
+ related: SalesOrderRelated | null;
979
+
980
+ /**
981
+ * Reference to an actor — the user, API key, agent, or group identity associated
982
+ * with an action.
983
+ */
984
+ sales_rep: RequestLogsAPI.Actor | null;
985
+
986
+ /**
987
+ * A saved address that can be used for billing and shipping on sales orders,
988
+ * invoices, and shipments.
989
+ */
990
+ ship_to_address: APIKeysAPI.Address | null;
991
+
992
+ /**
993
+ * A shipping term defining how freight charges are calculated for an order.
994
+ */
995
+ shipping_term: CustomersAPI.ShippingTerm | null;
996
+
997
+ /**
998
+ * Order lifecycle status.
999
+ *
1000
+ * - `estimate`: a draft quote that has not yet been committed; not counted as a
1001
+ * real order.
1002
+ * - `issued`: the order has been issued and is being fulfilled.
1003
+ * - `fulfilled`: the order has been completed and closed.
1004
+ *
1005
+ * Status changes are made through the issue, unissue, close, and reopen action
1006
+ * endpoints rather than by updating this field.
1007
+ */
1008
+ status: 'estimate' | 'issued' | 'fulfilled';
1009
+
1010
+ /**
1011
+ * SalesOrderTotals holds the derived monetary totals for a sales order or one of
1012
+ * its lines, following the lifecycle ordered -> picked -> packed -> invoiced. Each
1013
+ * downstream stage carries both its monetary amount and its completion progress
1014
+ * against the ordered baseline.
1015
+ */
1016
+ totals: SalesOrderTotals | null;
1017
+
1018
+ /**
1019
+ * Last updated timestamp.
1020
+ */
1021
+ updated_at: string;
1022
+ }
1023
+
1024
+ /**
1025
+ * SalesOrderEmailContactInput represents an account user subscribed to a
1026
+ * sales-order email notification type.
1027
+ */
1028
+ export interface SalesOrderEmailContactInput {
1029
+ /**
1030
+ * Account user ID to receive the notification.
1031
+ */
1032
+ account_user_id: string;
1033
+ }
1034
+
1035
+ /**
1036
+ * Full sales order line resource.
1037
+ */
1038
+ export interface SalesOrderLine {
1039
+ /**
1040
+ * Sales order line ID.
1041
+ */
1042
+ id: string;
1043
+
1044
+ /**
1045
+ * Creation timestamp.
1046
+ */
1047
+ created_at: string;
1048
+
1049
+ /**
1050
+ * Position of the line on the order.
1051
+ *
1052
+ * Assigned automatically in sequence, starting at `1`.
1053
+ */
1054
+ line_item_number: number;
1055
+
1056
+ /**
1057
+ * Resource type identifier.
1058
+ */
1059
+ object: 'sales_order_line';
1060
+
1061
+ /**
1062
+ * Product pairs an inventory item with how it is sold: its product type, optional
1063
+ * product line, and customer portal visibility.
1064
+ */
1065
+ product: ProductsAPI.Product | null;
1066
+
1067
+ /**
1068
+ * Product description.
1069
+ */
1070
+ product_description: string | null;
1071
+
1072
+ /**
1073
+ * Product SKU.
1074
+ */
1075
+ product_sku: string;
1076
+
1077
+ /**
1078
+ * Value with an associated unit.
1079
+ */
1080
+ quantity_ordered: ItemsAPI.Quantity | null;
1081
+
1082
+ /**
1083
+ * SalesOrderTotals holds the derived monetary totals for a sales order or one of
1084
+ * its lines, following the lifecycle ordered -> picked -> packed -> invoiced. Each
1085
+ * downstream stage carries both its monetary amount and its completion progress
1086
+ * against the ordered baseline.
1087
+ */
1088
+ totals: SalesOrderTotals | null;
1089
+
1090
+ /**
1091
+ * Value expressed as a ratio of two units, such as a price per kilogram or a
1092
+ * throughput per hour.
1093
+ */
1094
+ unit_cost: ItemsAPI.Rate | null;
1095
+
1096
+ /**
1097
+ * Value expressed as a ratio of two units, such as a price per kilogram or a
1098
+ * throughput per hour.
1099
+ */
1100
+ unit_price: ItemsAPI.Rate | null;
1101
+
1102
+ /**
1103
+ * Last updated timestamp.
1104
+ */
1105
+ updated_at: string;
1106
+ }
1107
+
1108
+ /**
1109
+ * A per-unit rate on a sales-order quote.
1110
+ *
1111
+ * A lightweight, unpersisted variant of a rate: it carries no ID or timestamps
1112
+ * because a quote is computed on demand and never stored.
1113
+ */
1114
+ export interface SalesOrderQuoteRate {
1115
+ /**
1116
+ * Unit of measurement used for conversions and product quantities.
1117
+ */
1118
+ denominator_unit: UnitsAPI.Unit | null;
1119
+
1120
+ /**
1121
+ * Unit of measurement used for conversions and product quantities.
1122
+ */
1123
+ numerator_unit: UnitsAPI.Unit | null;
1124
+
1125
+ /**
1126
+ * Resource type identifier.
1127
+ */
1128
+ object: 'sales_order_quote_rate';
1129
+
1130
+ /**
1131
+ * Decimal value of the rate, expressed as the amount of the numerator unit per one
1132
+ * denominator unit.
1133
+ */
1134
+ value: string;
1135
+ }
1136
+
1137
+ /**
1138
+ * SalesOrderRelated groups the records related to a sales order.
1139
+ *
1140
+ * The members are individually expandable (e.g. include[]=related.pick). The group
1141
+ * is null unless at least one of its members is expanded.
1142
+ */
1143
+ export interface SalesOrderRelated {
1144
+ /**
1145
+ * List represents a paginated list of resources.
1146
+ */
1147
+ invoices: ListRecord | null;
1148
+
1149
+ /**
1150
+ * Resource type identifier.
1151
+ */
1152
+ object: 'sales_order_related';
1153
+
1154
+ /**
1155
+ * Record is a lightweight reference to a business record — a sales order, purchase
1156
+ * order, pick, shipment, production run, invoice, etc.
1157
+ *
1158
+ * Like Actor and Entity, it carries just enough to identify and label the
1159
+ * referenced record without embedding its full resource. The optional status and
1160
+ * metadata fields hold type-specific detail that varies by the kind of record
1161
+ * referenced.
1162
+ */
1163
+ pick: Record | null;
1164
+
1165
+ /**
1166
+ * Record is a lightweight reference to a business record — a sales order, purchase
1167
+ * order, pick, shipment, production run, invoice, etc.
1168
+ *
1169
+ * Like Actor and Entity, it carries just enough to identify and label the
1170
+ * referenced record without embedding its full resource. The optional status and
1171
+ * metadata fields hold type-specific detail that varies by the kind of record
1172
+ * referenced.
1173
+ */
1174
+ production_run: Record | null;
1175
+
1176
+ /**
1177
+ * List represents a paginated list of resources.
1178
+ */
1179
+ shipments: ListRecord | null;
1180
+ }
1181
+
1182
+ /**
1183
+ * SalesOrderStageTotal pairs a fulfillment stage's monetary amount with its
1184
+ * completion progress.
1185
+ */
1186
+ export interface SalesOrderStageTotal {
1187
+ /**
1188
+ * Amount for this stage as a decimal string (unit price x quantity at this stage).
1189
+ */
1190
+ amount: string;
1191
+
1192
+ /**
1193
+ * Progress to completion for this stage, as a fraction between 0 and 1: quantity
1194
+ * at this stage divided by quantity ordered. `0` when nothing has reached this
1195
+ * stage yet.
1196
+ */
1197
+ completion: number;
1198
+
1199
+ /**
1200
+ * Resource type identifier.
1201
+ */
1202
+ object: 'sales_order_stage_total';
1203
+ }
1204
+
1205
+ /**
1206
+ * A lookup value describing where a sales order is in its lifecycle, from estimate
1207
+ * through fulfillment.
1208
+ */
1209
+ export interface SalesOrderStatus {
1210
+ /**
1211
+ * Sales order status ID.
1212
+ */
1213
+ id: string;
1214
+
1215
+ /**
1216
+ * Machine-readable status code.
1217
+ *
1218
+ * - `estimate`: a draft quote that has not yet been committed.
1219
+ * - `issued`: the order has been issued and is being fulfilled.
1220
+ * - `fulfilled`: the order has been completed and closed.
1221
+ */
1222
+ code: 'estimate' | 'issued' | 'fulfilled';
1223
+
1224
+ /**
1225
+ * Creation timestamp.
1226
+ */
1227
+ created_at: string;
1228
+
1229
+ /**
1230
+ * Human-readable name of the status.
1231
+ */
1232
+ name: string;
1233
+
1234
+ /**
1235
+ * Resource type identifier.
1236
+ */
1237
+ object: 'sales_order_status';
1238
+
1239
+ /**
1240
+ * Owner describes the provenance of a resource.
1241
+ */
1242
+ owner: APIKeysAPI.Owner | null;
1243
+
1244
+ /**
1245
+ * Last updated timestamp.
1246
+ */
1247
+ updated_at: string;
1248
+ }
1249
+
1250
+ /**
1251
+ * SalesOrderTotals holds the derived monetary totals for a sales order or one of
1252
+ * its lines, following the lifecycle ordered -> picked -> packed -> invoiced. Each
1253
+ * downstream stage carries both its monetary amount and its completion progress
1254
+ * against the ordered baseline.
1255
+ */
1256
+ export interface SalesOrderTotals {
1257
+ /**
1258
+ * SalesOrderStageTotal pairs a fulfillment stage's monetary amount with its
1259
+ * completion progress.
1260
+ */
1261
+ invoiced: SalesOrderStageTotal;
1262
+
1263
+ /**
1264
+ * Resource type identifier.
1265
+ */
1266
+ object: 'sales_order_totals';
1267
+
1268
+ /**
1269
+ * Total ordered amount as a decimal string (unit price x quantity ordered). This
1270
+ * is the baseline the stage completions are measured against.
1271
+ */
1272
+ ordered: string;
1273
+
1274
+ /**
1275
+ * SalesOrderStageTotal pairs a fulfillment stage's monetary amount with its
1276
+ * completion progress.
1277
+ */
1278
+ packed: SalesOrderStageTotal;
1279
+
1280
+ /**
1281
+ * SalesOrderStageTotal pairs a fulfillment stage's monetary amount with its
1282
+ * completion progress.
1283
+ */
1284
+ picked: SalesOrderStageTotal;
1285
+ }
1286
+
1287
+ /**
1288
+ * Request to update a sales order.
1289
+ */
1290
+ export interface UpdateSalesOrderRequest {
1291
+ /**
1292
+ * Replaces the acknowledgement email contacts on the order.
1293
+ *
1294
+ * An empty list clears all contacts; omitting the field leaves existing contacts
1295
+ * untouched.
1296
+ */
1297
+ acknowledgement_email_contacts?: Array<SalesOrderEmailContactInput>;
1298
+
1299
+ /**
1300
+ * Acknowledgment status of the order.
1301
+ *
1302
+ * Set to `sent` to mark the acknowledgement as sent without emailing the customer,
1303
+ * or `not_sent` to reset it.
1304
+ */
1305
+ acknowledgment_status?: 'not_sent' | 'sent';
1306
+
1307
+ /**
1308
+ * Billing address ID.
1309
+ *
1310
+ * Re-points the order to an existing address. To change an address's contents, use
1311
+ * the update-address endpoint.
1312
+ */
1313
+ billing_address_id?: string;
1314
+
1315
+ /**
1316
+ * Carrier billing account number. Send `null` to clear.
1317
+ */
1318
+ carrier_billing_account_number?: string | null;
1319
+
1320
+ /**
1321
+ * Who is billed for freight. Send `null` to clear.
1322
+ *
1323
+ * - `sender`: the sender pays for shipping.
1324
+ * - `third_party`: a third party pays for shipping, using the carrier billing
1325
+ * account number.
1326
+ */
1327
+ carrier_billing_type?: 'sender' | 'third_party' | null;
1328
+
1329
+ /**
1330
+ * Carrier ID.
1331
+ */
1332
+ carrier_id?: string;
1333
+
1334
+ /**
1335
+ * Customer ID.
1336
+ */
1337
+ customer_id?: string;
1338
+
1339
+ /**
1340
+ * Customer's purchase order number. Send `null` to clear.
1341
+ */
1342
+ customer_purchase_order_number?: string | null;
1343
+
1344
+ /**
1345
+ * Replaces the invoice email contacts on the order.
1346
+ *
1347
+ * An empty list clears all contacts; omitting the field leaves existing contacts
1348
+ * untouched.
1349
+ */
1350
+ invoice_email_contacts?: Array<SalesOrderEmailContactInput>;
1351
+
1352
+ /**
1353
+ * Order note. Send `null` to clear.
1354
+ */
1355
+ note?: string | null;
1356
+
1357
+ /**
1358
+ * Order discount ID. Send `null` to clear.
1359
+ */
1360
+ order_discount_id?: string | null;
1361
+
1362
+ /**
1363
+ * Payment term ID.
1364
+ */
1365
+ payment_term_id?: string;
1366
+
1367
+ /**
1368
+ * New fulfillment priority for the order.
1369
+ */
1370
+ priority_code?: string;
1371
+
1372
+ /**
1373
+ * Promised delivery date. Send `null` to clear.
1374
+ */
1375
+ promised_at?: string | null;
1376
+
1377
+ /**
1378
+ * Sales rep ID. Send `null` to clear.
1379
+ */
1380
+ sales_rep_id?: string | null;
1381
+
1382
+ /**
1383
+ * Service level ID. Send `null` to clear.
1384
+ */
1385
+ service_level_id?: string | null;
1386
+
1387
+ /**
1388
+ * Shipping address ID.
1389
+ *
1390
+ * Re-points the order to an existing address. To change an address's contents, use
1391
+ * the update-address endpoint.
1392
+ */
1393
+ shipping_address_id?: string;
1394
+
1395
+ /**
1396
+ * Shipping term ID.
1397
+ */
1398
+ shipping_term_id?: string;
1399
+ }
1400
+
1401
+ export interface SalesOrderDeleteResponse {}
1402
+
1403
+ export interface SalesOrderRetrieveStatusesParams {
1404
+ /**
1405
+ * Opaque cursor token identifying where the page of results starts.
1406
+ *
1407
+ * Use the `cursor` value embedded in a previous response's `next_page_url` or
1408
+ * `previous_page_url` to fetch the adjacent page. Omit to start from the first
1409
+ * page.
1410
+ */
1411
+ cursor?: string;
1412
+
1413
+ /**
1414
+ * Sub-objects to expand in the response. When omitted, sub-objects are returned as
1415
+ * `null`.
1416
+ */
1417
+ include?: Array<'owner'>;
1418
+
1419
+ /**
1420
+ * Maximum number of results to return in a single page.
1421
+ */
1422
+ limit?: number;
1423
+
1424
+ /**
1425
+ * Free-text search term used to filter results.
1426
+ *
1427
+ * Which fields are matched against the term varies by endpoint.
1428
+ */
1429
+ q?: string;
1430
+ }
1431
+
1432
+ export interface SalesOrderListParams {
1433
+ /**
1434
+ * Opaque cursor token identifying where the page of results starts.
1435
+ *
1436
+ * Use the `cursor` value embedded in a previous response's `next_page_url` or
1437
+ * `previous_page_url` to fetch the adjacent page. Omit to start from the first
1438
+ * page.
1439
+ */
1440
+ cursor?: string;
1441
+
1442
+ /**
1443
+ * Filter by customer group IDs.
1444
+ */
1445
+ customer_group_ids?: Array<string>;
1446
+
1447
+ /**
1448
+ * Filter by customer IDs.
1449
+ */
1450
+ customer_ids?: Array<string>;
1451
+
1452
+ /**
1453
+ * Latest order creation date to include, in `YYYY-MM-DD` format (inclusive).
1454
+ */
1455
+ end_date?: string;
1456
+
1457
+ /**
1458
+ * Sub-objects to expand in the response. When omitted, sub-objects are returned as
1459
+ * `null`.
1460
+ */
1461
+ include?: Array<
1462
+ | 'customer'
1463
+ | 'sales_rep'
1464
+ | 'created_by'
1465
+ | 'bill_to_address'
1466
+ | 'ship_to_address'
1467
+ | 'freight'
1468
+ | 'payment_term'
1469
+ | 'shipping_term'
1470
+ | 'order_discount'
1471
+ | 'totals'
1472
+ | 'contacts'
1473
+ | 'related.pick'
1474
+ | 'related.production_run'
1475
+ | 'related.shipments'
1476
+ | 'related.invoices'
1477
+ | 'lines'
1478
+ | 'lines.product'
1479
+ | 'lines.product.item'
1480
+ | 'lines.product.product_line'
1481
+ | 'lines.quantity_ordered'
1482
+ | 'lines.quantity_ordered.unit'
1483
+ | 'lines.unit_price'
1484
+ | 'lines.unit_price.numerator_unit'
1485
+ | 'lines.unit_price.denominator_unit'
1486
+ | 'lines.unit_cost'
1487
+ | 'lines.unit_cost.numerator_unit'
1488
+ | 'lines.unit_cost.denominator_unit'
1489
+ | 'lines.totals'
1490
+ >;
1491
+
1492
+ /**
1493
+ * Filter by item IDs.
1494
+ */
1495
+ item_ids?: Array<string>;
1496
+
1497
+ /**
1498
+ * Maximum number of results to return in a single page.
1499
+ */
1500
+ limit?: number;
1501
+
1502
+ /**
1503
+ * Filter by product line IDs.
1504
+ */
1505
+ product_line_ids?: Array<string>;
1506
+
1507
+ /**
1508
+ * Free-text search term used to filter results.
1509
+ *
1510
+ * Which fields are matched against the term varies by endpoint.
1511
+ */
1512
+ q?: string;
1513
+
1514
+ /**
1515
+ * Filter by sales rep IDs.
1516
+ */
1517
+ sales_rep_ids?: Array<string>;
1518
+
1519
+ /**
1520
+ * Earliest order creation date to include, in `YYYY-MM-DD` format (inclusive).
1521
+ */
1522
+ start_date?: string;
1523
+
1524
+ /**
1525
+ * Filter by status codes.
1526
+ */
1527
+ status_codes?: Array<string>;
1528
+ }
1529
+
1530
+ export interface SalesOrderRetrieveParams {
1531
+ /**
1532
+ * Sub-objects to expand in the response. When omitted, sub-objects are returned as
1533
+ * `null`.
1534
+ */
1535
+ include?: Array<
1536
+ | 'customer'
1537
+ | 'sales_rep'
1538
+ | 'created_by'
1539
+ | 'bill_to_address'
1540
+ | 'ship_to_address'
1541
+ | 'freight'
1542
+ | 'payment_term'
1543
+ | 'shipping_term'
1544
+ | 'order_discount'
1545
+ | 'totals'
1546
+ | 'contacts'
1547
+ | 'related.pick'
1548
+ | 'related.production_run'
1549
+ | 'related.shipments'
1550
+ | 'related.invoices'
1551
+ | 'lines'
1552
+ | 'lines.product'
1553
+ | 'lines.product.item'
1554
+ | 'lines.product.product_line'
1555
+ | 'lines.quantity_ordered'
1556
+ | 'lines.quantity_ordered.unit'
1557
+ | 'lines.unit_price'
1558
+ | 'lines.unit_price.numerator_unit'
1559
+ | 'lines.unit_price.denominator_unit'
1560
+ | 'lines.unit_cost'
1561
+ | 'lines.unit_cost.numerator_unit'
1562
+ | 'lines.unit_cost.denominator_unit'
1563
+ | 'lines.totals'
1564
+ >;
1565
+ }
1566
+
1567
+ export interface SalesOrderCreateParams {
1568
+ /**
1569
+ * Body param: Bill-to address ID.
1570
+ *
1571
+ * Must reference an existing address on the order's owner or buyer account.
1572
+ */
1573
+ bill_to_address_id: string;
1574
+
1575
+ /**
1576
+ * Body param: ID of the customer account the order is for.
1577
+ */
1578
+ buyer_account_id: string;
1579
+
1580
+ /**
1581
+ * Body param: Order lines to create.
1582
+ */
1583
+ lines: Array<CreateSalesOrderLineInput>;
1584
+
1585
+ /**
1586
+ * Body param: Fulfillment priority used to rank the order on the shop floor.
1587
+ */
1588
+ priority_code: string;
1589
+
1590
+ /**
1591
+ * Body param: Ship-to address ID.
1592
+ *
1593
+ * Must reference an existing address on the order's owner or buyer account.
1594
+ */
1595
+ ship_to_address_id: string;
1596
+
1597
+ /**
1598
+ * Query param: Sub-objects to expand in the response. When omitted, sub-objects
1599
+ * are returned as `null`.
1600
+ */
1601
+ include?: Array<
1602
+ | 'customer'
1603
+ | 'sales_rep'
1604
+ | 'bill_to_address'
1605
+ | 'ship_to_address'
1606
+ | 'freight'
1607
+ | 'payment_term'
1608
+ | 'shipping_term'
1609
+ | 'order_discount'
1610
+ | 'totals'
1611
+ | 'contacts'
1612
+ | 'related.pick'
1613
+ | 'related.production_run'
1614
+ | 'related.shipments'
1615
+ | 'related.invoices'
1616
+ | 'lines'
1617
+ | 'lines.product'
1618
+ | 'lines.quantity_ordered'
1619
+ | 'lines.quantity_ordered.unit'
1620
+ | 'lines.unit_price'
1621
+ | 'lines.unit_price.numerator_unit'
1622
+ | 'lines.unit_price.denominator_unit'
1623
+ | 'lines.unit_cost'
1624
+ | 'lines.unit_cost.numerator_unit'
1625
+ | 'lines.unit_cost.denominator_unit'
1626
+ | 'lines.totals'
1627
+ >;
1628
+
1629
+ /**
1630
+ * Body param: Account users who should receive order acknowledgement emails.
1631
+ */
1632
+ acknowledgement_email_contacts?: Array<SalesOrderEmailContactInput>;
1633
+
1634
+ /**
1635
+ * Body param: Carrier billing account number.
1636
+ */
1637
+ carrier_billing_account_number?: string;
1638
+
1639
+ /**
1640
+ * Body param: Who is billed for freight.
1641
+ *
1642
+ * - `sender`: the sender pays for shipping.
1643
+ * - `third_party`: a third party pays for shipping, using the carrier billing
1644
+ * account number.
1645
+ */
1646
+ carrier_billing_type?: 'sender' | 'third_party';
1647
+
1648
+ /**
1649
+ * Body param: Carrier ID.
1650
+ */
1651
+ carrier_id?: string;
1652
+
1653
+ /**
1654
+ * Body param: The customer's own purchase order number, for cross-referencing.
1655
+ *
1656
+ * Must be unique among your orders for this customer.
1657
+ */
1658
+ customer_purchase_order_number?: string;
1659
+
1660
+ /**
1661
+ * Body param: Account users who should receive invoice emails.
1662
+ */
1663
+ invoice_email_contacts?: Array<SalesOrderEmailContactInput>;
1664
+
1665
+ /**
1666
+ * Body param: Order note.
1667
+ */
1668
+ note?: string;
1669
+
1670
+ /**
1671
+ * Body param: Order discount ID.
1672
+ *
1673
+ * When supplied, a discount line is added to the order automatically.
1674
+ */
1675
+ order_discount_id?: string;
1676
+
1677
+ /**
1678
+ * Body param: Payment term ID.
1679
+ */
1680
+ payment_term_id?: string;
1681
+
1682
+ /**
1683
+ * Body param: Promised delivery date.
1684
+ */
1685
+ promised_at?: string;
1686
+
1687
+ /**
1688
+ * Body param: Sales rep ID.
1689
+ *
1690
+ * When omitted, a rep is assigned automatically: the customer's default sales rep
1691
+ * first, then the sales territory matching the ship-to postal code, then the
1692
+ * ship-to state.
1693
+ */
1694
+ sales_rep_id?: string;
1695
+
1696
+ /**
1697
+ * Body param: Service level ID.
1698
+ */
1699
+ service_level_id?: string;
1700
+
1701
+ /**
1702
+ * Body param: Shipping term ID.
1703
+ */
1704
+ shipping_term_id?: string;
1705
+ }
1706
+
1707
+ export interface SalesOrderUpdateParams {
1708
+ /**
1709
+ * Query param: Sub-objects to expand in the response. When omitted, sub-objects
1710
+ * are returned as `null`.
1711
+ */
1712
+ include?: Array<
1713
+ | 'customer'
1714
+ | 'sales_rep'
1715
+ | 'bill_to_address'
1716
+ | 'ship_to_address'
1717
+ | 'freight'
1718
+ | 'payment_term'
1719
+ | 'shipping_term'
1720
+ | 'order_discount'
1721
+ | 'totals'
1722
+ | 'contacts'
1723
+ | 'related.pick'
1724
+ | 'related.production_run'
1725
+ | 'related.shipments'
1726
+ | 'related.invoices'
1727
+ | 'lines'
1728
+ | 'lines.product'
1729
+ | 'lines.quantity_ordered'
1730
+ | 'lines.quantity_ordered.unit'
1731
+ | 'lines.unit_price'
1732
+ | 'lines.unit_price.numerator_unit'
1733
+ | 'lines.unit_price.denominator_unit'
1734
+ | 'lines.unit_cost'
1735
+ | 'lines.unit_cost.numerator_unit'
1736
+ | 'lines.unit_cost.denominator_unit'
1737
+ | 'lines.totals'
1738
+ >;
1739
+
1740
+ /**
1741
+ * Body param: Replaces the acknowledgement email contacts on the order.
1742
+ *
1743
+ * An empty list clears all contacts; omitting the field leaves existing contacts
1744
+ * untouched.
1745
+ */
1746
+ acknowledgement_email_contacts?: Array<SalesOrderEmailContactInput>;
1747
+
1748
+ /**
1749
+ * Body param: Acknowledgment status of the order.
1750
+ *
1751
+ * Set to `sent` to mark the acknowledgement as sent without emailing the customer,
1752
+ * or `not_sent` to reset it.
1753
+ */
1754
+ acknowledgment_status?: 'not_sent' | 'sent';
1755
+
1756
+ /**
1757
+ * Body param: Billing address ID.
1758
+ *
1759
+ * Re-points the order to an existing address. To change an address's contents, use
1760
+ * the update-address endpoint.
1761
+ */
1762
+ billing_address_id?: string;
1763
+
1764
+ /**
1765
+ * Body param: Carrier billing account number. Send `null` to clear.
1766
+ */
1767
+ carrier_billing_account_number?: string | null;
1768
+
1769
+ /**
1770
+ * Body param: Who is billed for freight. Send `null` to clear.
1771
+ *
1772
+ * - `sender`: the sender pays for shipping.
1773
+ * - `third_party`: a third party pays for shipping, using the carrier billing
1774
+ * account number.
1775
+ */
1776
+ carrier_billing_type?: 'sender' | 'third_party' | null;
1777
+
1778
+ /**
1779
+ * Body param: Carrier ID.
1780
+ */
1781
+ carrier_id?: string;
1782
+
1783
+ /**
1784
+ * Body param: Customer ID.
1785
+ */
1786
+ customer_id?: string;
1787
+
1788
+ /**
1789
+ * Body param: Customer's purchase order number. Send `null` to clear.
1790
+ */
1791
+ customer_purchase_order_number?: string | null;
1792
+
1793
+ /**
1794
+ * Body param: Replaces the invoice email contacts on the order.
1795
+ *
1796
+ * An empty list clears all contacts; omitting the field leaves existing contacts
1797
+ * untouched.
1798
+ */
1799
+ invoice_email_contacts?: Array<SalesOrderEmailContactInput>;
1800
+
1801
+ /**
1802
+ * Body param: Order note. Send `null` to clear.
1803
+ */
1804
+ note?: string | null;
1805
+
1806
+ /**
1807
+ * Body param: Order discount ID. Send `null` to clear.
1808
+ */
1809
+ order_discount_id?: string | null;
1810
+
1811
+ /**
1812
+ * Body param: Payment term ID.
1813
+ */
1814
+ payment_term_id?: string;
1815
+
1816
+ /**
1817
+ * Body param: New fulfillment priority for the order.
1818
+ */
1819
+ priority_code?: string;
1820
+
1821
+ /**
1822
+ * Body param: Promised delivery date. Send `null` to clear.
1823
+ */
1824
+ promised_at?: string | null;
1825
+
1826
+ /**
1827
+ * Body param: Sales rep ID. Send `null` to clear.
1828
+ */
1829
+ sales_rep_id?: string | null;
1830
+
1831
+ /**
1832
+ * Body param: Service level ID. Send `null` to clear.
1833
+ */
1834
+ service_level_id?: string | null;
1835
+
1836
+ /**
1837
+ * Body param: Shipping address ID.
1838
+ *
1839
+ * Re-points the order to an existing address. To change an address's contents, use
1840
+ * the update-address endpoint.
1841
+ */
1842
+ shipping_address_id?: string;
1843
+
1844
+ /**
1845
+ * Body param: Shipping term ID.
1846
+ */
1847
+ shipping_term_id?: string;
1848
+ }
1849
+
1850
+ export interface SalesOrderCheckoutParams {
1851
+ /**
1852
+ * Email address to send the checkout link to.
1853
+ *
1854
+ * Also set as the customer email on the payment provider's checkout session.
1855
+ */
1856
+ email: string;
1857
+ }
1858
+
1859
+ export interface SalesOrderPriceQuoteParams {
1860
+ /**
1861
+ * ID of the customer account the prices are for.
1862
+ */
1863
+ buyer_account_id: string;
1864
+
1865
+ /**
1866
+ * Lines to price.
1867
+ */
1868
+ lines: Array<QuoteSalesOrderLineInput>;
1869
+ }
1870
+
1871
+ SalesOrders.Actions = Actions;
1872
+ SalesOrders.Lines = Lines;
1873
+
1874
+ export declare namespace SalesOrders {
1875
+ export {
1876
+ type CheckoutSalesOrderRequest as CheckoutSalesOrderRequest,
1877
+ type CheckoutSalesOrderResponse as CheckoutSalesOrderResponse,
1878
+ type CreateSalesOrderLineInput as CreateSalesOrderLineInput,
1879
+ type CreateSalesOrderRequest as CreateSalesOrderRequest,
1880
+ type CreatedBy as CreatedBy,
1881
+ type Freight as Freight,
1882
+ type ListQuotedSalesOrderLine as ListQuotedSalesOrderLine,
1883
+ type ListRecord as ListRecord,
1884
+ type ListSalesOrder as ListSalesOrder,
1885
+ type ListSalesOrderLine as ListSalesOrderLine,
1886
+ type ListSalesOrderStatus as ListSalesOrderStatus,
1887
+ type OrderContact as OrderContact,
1888
+ type OrderDiscount as OrderDiscount,
1889
+ type QuoteSalesOrderLineInput as QuoteSalesOrderLineInput,
1890
+ type QuoteSalesOrderPricesRequest as QuoteSalesOrderPricesRequest,
1891
+ type QuoteSalesOrderPricesResponse as QuoteSalesOrderPricesResponse,
1892
+ type QuotedSalesOrderLine as QuotedSalesOrderLine,
1893
+ type Record as Record,
1894
+ type SalesOrder as SalesOrder,
1895
+ type SalesOrderEmailContactInput as SalesOrderEmailContactInput,
1896
+ type SalesOrderLine as SalesOrderLine,
1897
+ type SalesOrderQuoteRate as SalesOrderQuoteRate,
1898
+ type SalesOrderRelated as SalesOrderRelated,
1899
+ type SalesOrderStageTotal as SalesOrderStageTotal,
1900
+ type SalesOrderStatus as SalesOrderStatus,
1901
+ type SalesOrderTotals as SalesOrderTotals,
1902
+ type UpdateSalesOrderRequest as UpdateSalesOrderRequest,
1903
+ type SalesOrderDeleteResponse as SalesOrderDeleteResponse,
1904
+ type SalesOrderRetrieveStatusesParams as SalesOrderRetrieveStatusesParams,
1905
+ type SalesOrderListParams as SalesOrderListParams,
1906
+ type SalesOrderRetrieveParams as SalesOrderRetrieveParams,
1907
+ type SalesOrderCreateParams as SalesOrderCreateParams,
1908
+ type SalesOrderUpdateParams as SalesOrderUpdateParams,
1909
+ type SalesOrderCheckoutParams as SalesOrderCheckoutParams,
1910
+ type SalesOrderPriceQuoteParams as SalesOrderPriceQuoteParams,
1911
+ };
1912
+
1913
+ export {
1914
+ Actions as Actions,
1915
+ type BulkDeleteSalesOrdersRequest as BulkDeleteSalesOrdersRequest,
1916
+ type IssueSalesOrderRequest as IssueSalesOrderRequest,
1917
+ type ProductionRun as ProductionRun,
1918
+ type QuoteSalesOrderFreightResponse as QuoteSalesOrderFreightResponse,
1919
+ type ActionBulkDeleteResponse as ActionBulkDeleteResponse,
1920
+ type ActionBulkDeleteParams as ActionBulkDeleteParams,
1921
+ type ActionIssueParams as ActionIssueParams,
1922
+ type ActionCreateProductionRunParams as ActionCreateProductionRunParams,
1923
+ };
1924
+
1925
+ export {
1926
+ Lines as Lines,
1927
+ type CreateSalesOrderLineRequest as CreateSalesOrderLineRequest,
1928
+ type UpdateSalesOrderLineRequest as UpdateSalesOrderLineRequest,
1929
+ type LineDeleteResponse as LineDeleteResponse,
1930
+ type LineCreateParams as LineCreateParams,
1931
+ type LineUpdateParams as LineUpdateParams,
1932
+ type LineDeleteParams as LineDeleteParams,
1933
+ };
1934
+ }