@mergeapi/merge-node-client 4.0.0-alpha.0 → 4.0.0-alpha.1

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 (236) hide show
  1. package/BaseClient.js +2 -2
  2. package/api/resources/accounting/resources/expenses/client/Client.d.ts +8 -26
  3. package/api/resources/accounting/resources/expenses/client/Client.js +18 -67
  4. package/api/resources/accounting/resources/expenses/client/requests/ExpenseBulkRequest.d.ts +0 -6
  5. package/api/resources/accounting/resources/expenses/client/requests/index.d.ts +0 -1
  6. package/api/resources/accounting/resources/expenses/types/index.d.ts +0 -1
  7. package/api/resources/accounting/resources/expenses/types/index.js +0 -1
  8. package/api/resources/accounting/resources/invoices/client/Client.d.ts +8 -34
  9. package/api/resources/accounting/resources/invoices/client/Client.js +18 -89
  10. package/api/resources/accounting/resources/invoices/client/requests/InvoiceBulkRequest.d.ts +0 -6
  11. package/api/resources/accounting/resources/invoices/client/requests/index.d.ts +0 -1
  12. package/api/resources/accounting/resources/invoices/types/index.d.ts +0 -3
  13. package/api/resources/accounting/resources/invoices/types/index.js +0 -3
  14. package/api/resources/accounting/resources/itemFulfillments/client/Client.d.ts +8 -20
  15. package/api/resources/accounting/resources/itemFulfillments/client/Client.js +18 -55
  16. package/api/resources/accounting/resources/itemFulfillments/client/requests/ItemFulfillmentBulkRequest.d.ts +0 -6
  17. package/api/resources/accounting/resources/itemFulfillments/client/requests/index.d.ts +0 -1
  18. package/api/resources/accounting/resources/itemFulfillments/types/index.d.ts +0 -1
  19. package/api/resources/accounting/resources/itemFulfillments/types/index.js +0 -1
  20. package/api/resources/accounting/resources/salesOrders/client/Client.d.ts +8 -28
  21. package/api/resources/accounting/resources/salesOrders/client/Client.js +20 -71
  22. package/api/resources/accounting/resources/salesOrders/client/requests/SalesOrderBulkRequest.d.ts +0 -6
  23. package/api/resources/accounting/resources/salesOrders/client/requests/index.d.ts +0 -1
  24. package/api/resources/accounting/resources/salesOrders/types/index.d.ts +0 -1
  25. package/api/resources/accounting/resources/salesOrders/types/index.js +0 -1
  26. package/api/resources/accounting/types/AsyncBulkCreateResponse.d.ts +4 -0
  27. package/api/resources/accounting/types/BankFeedTransactionRequestRequestBankFeedAccount.d.ts +1 -1
  28. package/api/resources/accounting/types/BatchObject.d.ts +15 -1
  29. package/api/resources/accounting/types/BatchObjectItemResponse.d.ts +3 -0
  30. package/api/resources/accounting/types/BatchObjectStatus.d.ts +13 -0
  31. package/api/resources/accounting/types/BatchObjectStatusEnum.d.ts +15 -0
  32. package/api/resources/accounting/types/BatchObjectStatusEnum.js +18 -0
  33. package/api/resources/accounting/types/BatchObjectsResponse.d.ts +23 -1
  34. package/api/resources/accounting/types/BatchObjectsResponseStatus.d.ts +19 -0
  35. package/api/resources/accounting/types/BatchObjectsResponseStatusEnum.d.ts +24 -0
  36. package/api/resources/accounting/types/BatchObjectsResponseStatusEnum.js +27 -0
  37. package/api/resources/accounting/types/ContactRequestAddressesItem.d.ts +1 -1
  38. package/api/resources/accounting/types/ContactRequestPhoneNumbersItem.d.ts +1 -1
  39. package/api/resources/accounting/types/CreditNoteApplyLineForCreditNoteRequestInvoice.d.ts +1 -1
  40. package/api/resources/accounting/types/CreditNoteLineItemRequestContact.d.ts +1 -1
  41. package/api/resources/accounting/types/CreditNoteRequestAppliedPaymentsItem.d.ts +1 -1
  42. package/api/resources/accounting/types/CreditNoteRequestContact.d.ts +1 -1
  43. package/api/resources/accounting/types/CreditNoteRequestLineItemsItem.d.ts +1 -1
  44. package/api/resources/accounting/types/CreditNoteRequestPaymentsItem.d.ts +1 -1
  45. package/api/resources/accounting/types/DataPassthroughRequest.d.ts +2 -2
  46. package/api/resources/accounting/types/ErrorValidationProblem.d.ts +2 -0
  47. package/api/resources/accounting/types/ExpenseLineRequestAccount.d.ts +1 -1
  48. package/api/resources/accounting/types/ExpenseLineRequestContact.d.ts +1 -1
  49. package/api/resources/accounting/types/ExpenseReportLineRequestAccount.d.ts +1 -1
  50. package/api/resources/accounting/types/ExpenseReportLineRequestContact.d.ts +1 -1
  51. package/api/resources/accounting/types/ExpenseRequestAccount.d.ts +1 -1
  52. package/api/resources/accounting/types/ExpenseRequestContact.d.ts +1 -1
  53. package/api/resources/accounting/types/InvoiceLineItemRequestAccount.d.ts +1 -1
  54. package/api/resources/accounting/types/InvoiceLineItemRequestContact.d.ts +1 -1
  55. package/api/resources/accounting/types/InvoiceRequestContact.d.ts +1 -1
  56. package/api/resources/accounting/types/InvoiceRequestPaymentsItem.d.ts +1 -1
  57. package/api/resources/accounting/types/InvoiceRequestPurchaseOrdersItem.d.ts +1 -1
  58. package/api/resources/accounting/types/ItemFulfillmentLineRequestSalesOrderLine.d.ts +1 -1
  59. package/api/resources/accounting/types/ItemFulfillmentRequestRequestCustomer.d.ts +1 -1
  60. package/api/resources/accounting/types/ItemRequestRequestPurchaseAccount.d.ts +1 -1
  61. package/api/resources/accounting/types/ItemRequestRequestSalesAccount.d.ts +1 -1
  62. package/api/resources/accounting/types/JournalEntryRequestLinesItem.d.ts +1 -1
  63. package/api/resources/accounting/types/JournalEntryRequestPaymentsItem.d.ts +1 -1
  64. package/api/resources/accounting/types/JournalLineRequestAccount.d.ts +1 -1
  65. package/api/resources/accounting/types/PaymentRequestAccount.d.ts +1 -1
  66. package/api/resources/accounting/types/PaymentRequestAppliedToLinesItem.d.ts +1 -1
  67. package/api/resources/accounting/types/PaymentRequestContact.d.ts +1 -1
  68. package/api/resources/accounting/types/PurchaseOrderRequestDeliveryAddress.d.ts +1 -1
  69. package/api/resources/accounting/types/PurchaseOrderRequestLineItemsItem.d.ts +1 -1
  70. package/api/resources/accounting/types/PurchaseOrderRequestVendor.d.ts +1 -1
  71. package/api/resources/accounting/types/RemoteFieldApi.d.ts +1 -1
  72. package/api/resources/accounting/types/SalesOrderRequestRequestCustomer.d.ts +1 -1
  73. package/api/resources/accounting/types/SalesOrderRequestRequestShippingAddress.d.ts +1 -1
  74. package/api/resources/accounting/types/VendorCreditApplyLineForVendorCreditRequestInvoice.d.ts +1 -1
  75. package/api/resources/accounting/types/VendorCreditLineRequestAccount.d.ts +1 -1
  76. package/api/resources/accounting/types/VendorCreditLineRequestContact.d.ts +1 -1
  77. package/api/resources/accounting/types/VendorCreditRequestVendor.d.ts +1 -1
  78. package/api/resources/accounting/types/WarningValidationProblem.d.ts +2 -0
  79. package/api/resources/accounting/types/index.d.ts +4 -3
  80. package/api/resources/accounting/types/index.js +4 -3
  81. package/package.json +1 -1
  82. package/reference.md +24 -128
  83. package/serialization/resources/accounting/resources/expenses/client/requests/ExpenseBulkRequest.d.ts +1 -1
  84. package/serialization/resources/accounting/resources/expenses/types/index.d.ts +0 -1
  85. package/serialization/resources/accounting/resources/expenses/types/index.js +0 -1
  86. package/serialization/resources/accounting/resources/invoices/client/requests/InvoiceBulkRequest.d.ts +1 -1
  87. package/serialization/resources/accounting/resources/invoices/types/index.d.ts +0 -3
  88. package/serialization/resources/accounting/resources/invoices/types/index.js +0 -3
  89. package/serialization/resources/accounting/resources/itemFulfillments/client/requests/ItemFulfillmentBulkRequest.d.ts +1 -1
  90. package/serialization/resources/accounting/resources/itemFulfillments/types/index.d.ts +0 -1
  91. package/serialization/resources/accounting/resources/itemFulfillments/types/index.js +0 -1
  92. package/serialization/resources/accounting/resources/salesOrders/client/requests/SalesOrderBulkRequest.d.ts +1 -1
  93. package/serialization/resources/accounting/resources/salesOrders/types/index.d.ts +0 -1
  94. package/serialization/resources/accounting/resources/salesOrders/types/index.js +0 -1
  95. package/serialization/resources/accounting/types/BankFeedTransactionRequestRequestBankFeedAccount.d.ts +2 -2
  96. package/serialization/resources/accounting/types/BankFeedTransactionRequestRequestBankFeedAccount.js +2 -2
  97. package/serialization/resources/accounting/types/BatchObject.d.ts +2 -1
  98. package/serialization/resources/accounting/types/BatchObject.js +2 -1
  99. package/serialization/resources/accounting/types/BatchObjectStatus.d.ts +8 -0
  100. package/serialization/resources/accounting/types/{RemoteFieldApiAdvancedMetadata.js → BatchObjectStatus.js} +3 -3
  101. package/serialization/resources/accounting/types/BatchObjectStatusEnum.d.ts +7 -0
  102. package/serialization/resources/accounting/types/{DataPassthroughRequestMethod.js → BatchObjectStatusEnum.js} +2 -3
  103. package/serialization/resources/accounting/types/BatchObjectsResponse.d.ts +2 -1
  104. package/serialization/resources/accounting/types/BatchObjectsResponse.js +2 -1
  105. package/serialization/resources/accounting/types/BatchObjectsResponseStatus.d.ts +8 -0
  106. package/serialization/resources/accounting/types/{DataPassthroughRequestRequestFormat.js → BatchObjectsResponseStatus.js} +3 -3
  107. package/serialization/resources/accounting/types/BatchObjectsResponseStatusEnum.d.ts +7 -0
  108. package/serialization/resources/accounting/{resources/invoices/types/InvoicesBatchObjectsListRequestType.js → types/BatchObjectsResponseStatusEnum.js} +3 -3
  109. package/serialization/resources/accounting/types/ContactRequestAddressesItem.d.ts +2 -2
  110. package/serialization/resources/accounting/types/ContactRequestAddressesItem.js +2 -2
  111. package/serialization/resources/accounting/types/ContactRequestPhoneNumbersItem.d.ts +2 -2
  112. package/serialization/resources/accounting/types/ContactRequestPhoneNumbersItem.js +2 -2
  113. package/serialization/resources/accounting/types/CreditNoteApplyLineForCreditNoteRequestInvoice.d.ts +2 -3
  114. package/serialization/resources/accounting/types/CreditNoteApplyLineForCreditNoteRequestInvoice.js +5 -2
  115. package/serialization/resources/accounting/types/CreditNoteLineItemRequestContact.d.ts +2 -2
  116. package/serialization/resources/accounting/types/CreditNoteLineItemRequestContact.js +2 -2
  117. package/serialization/resources/accounting/types/CreditNoteRequestAppliedPaymentsItem.d.ts +2 -2
  118. package/serialization/resources/accounting/types/CreditNoteRequestAppliedPaymentsItem.js +2 -2
  119. package/serialization/resources/accounting/types/CreditNoteRequestContact.d.ts +2 -2
  120. package/serialization/resources/accounting/types/CreditNoteRequestContact.js +2 -2
  121. package/serialization/resources/accounting/types/CreditNoteRequestLineItemsItem.d.ts +2 -2
  122. package/serialization/resources/accounting/types/CreditNoteRequestLineItemsItem.js +2 -2
  123. package/serialization/resources/accounting/types/CreditNoteRequestPaymentsItem.d.ts +2 -2
  124. package/serialization/resources/accounting/types/CreditNoteRequestPaymentsItem.js +2 -2
  125. package/serialization/resources/accounting/types/DataPassthroughRequest.d.ts +4 -4
  126. package/serialization/resources/accounting/types/DataPassthroughRequest.js +4 -4
  127. package/serialization/resources/accounting/types/ErrorValidationProblem.d.ts +2 -0
  128. package/serialization/resources/accounting/types/ErrorValidationProblem.js +2 -0
  129. package/serialization/resources/accounting/types/ExpenseLineRequestAccount.d.ts +2 -2
  130. package/serialization/resources/accounting/types/ExpenseLineRequestAccount.js +2 -2
  131. package/serialization/resources/accounting/types/ExpenseLineRequestContact.d.ts +2 -2
  132. package/serialization/resources/accounting/types/ExpenseLineRequestContact.js +2 -2
  133. package/serialization/resources/accounting/types/ExpenseReportLineRequestAccount.d.ts +2 -2
  134. package/serialization/resources/accounting/types/ExpenseReportLineRequestAccount.js +2 -2
  135. package/serialization/resources/accounting/types/ExpenseReportLineRequestContact.d.ts +2 -2
  136. package/serialization/resources/accounting/types/ExpenseReportLineRequestContact.js +2 -2
  137. package/serialization/resources/accounting/types/ExpenseRequestAccount.d.ts +2 -2
  138. package/serialization/resources/accounting/types/ExpenseRequestAccount.js +2 -2
  139. package/serialization/resources/accounting/types/ExpenseRequestContact.d.ts +2 -2
  140. package/serialization/resources/accounting/types/ExpenseRequestContact.js +2 -2
  141. package/serialization/resources/accounting/types/InvoiceLineItemRequestAccount.d.ts +2 -2
  142. package/serialization/resources/accounting/types/InvoiceLineItemRequestAccount.js +2 -2
  143. package/serialization/resources/accounting/types/InvoiceLineItemRequestContact.d.ts +2 -2
  144. package/serialization/resources/accounting/types/InvoiceLineItemRequestContact.js +2 -2
  145. package/serialization/resources/accounting/types/InvoiceRequestContact.d.ts +2 -2
  146. package/serialization/resources/accounting/types/InvoiceRequestContact.js +2 -2
  147. package/serialization/resources/accounting/types/InvoiceRequestPaymentsItem.d.ts +2 -2
  148. package/serialization/resources/accounting/types/InvoiceRequestPaymentsItem.js +2 -2
  149. package/serialization/resources/accounting/types/InvoiceRequestPurchaseOrdersItem.d.ts +2 -2
  150. package/serialization/resources/accounting/types/InvoiceRequestPurchaseOrdersItem.js +2 -2
  151. package/serialization/resources/accounting/types/ItemFulfillmentLineRequestSalesOrderLine.d.ts +2 -2
  152. package/serialization/resources/accounting/types/ItemFulfillmentLineRequestSalesOrderLine.js +2 -2
  153. package/serialization/resources/accounting/types/ItemFulfillmentRequestRequestCustomer.d.ts +2 -2
  154. package/serialization/resources/accounting/types/ItemFulfillmentRequestRequestCustomer.js +2 -2
  155. package/serialization/resources/accounting/types/ItemRequestRequestPurchaseAccount.d.ts +2 -2
  156. package/serialization/resources/accounting/types/ItemRequestRequestPurchaseAccount.js +2 -2
  157. package/serialization/resources/accounting/types/ItemRequestRequestSalesAccount.d.ts +2 -2
  158. package/serialization/resources/accounting/types/ItemRequestRequestSalesAccount.js +2 -2
  159. package/serialization/resources/accounting/types/JournalEntryRequestLinesItem.d.ts +2 -2
  160. package/serialization/resources/accounting/types/JournalEntryRequestLinesItem.js +2 -2
  161. package/serialization/resources/accounting/types/JournalEntryRequestPaymentsItem.d.ts +2 -2
  162. package/serialization/resources/accounting/types/JournalEntryRequestPaymentsItem.js +2 -2
  163. package/serialization/resources/accounting/types/JournalLineRequestAccount.d.ts +2 -2
  164. package/serialization/resources/accounting/types/JournalLineRequestAccount.js +2 -2
  165. package/serialization/resources/accounting/types/PaymentRequestAccount.d.ts +2 -2
  166. package/serialization/resources/accounting/types/PaymentRequestAccount.js +2 -2
  167. package/serialization/resources/accounting/types/PaymentRequestAppliedToLinesItem.d.ts +2 -2
  168. package/serialization/resources/accounting/types/PaymentRequestAppliedToLinesItem.js +2 -2
  169. package/serialization/resources/accounting/types/PaymentRequestContact.d.ts +2 -2
  170. package/serialization/resources/accounting/types/PaymentRequestContact.js +2 -2
  171. package/serialization/resources/accounting/types/PurchaseOrderRequestDeliveryAddress.d.ts +2 -2
  172. package/serialization/resources/accounting/types/PurchaseOrderRequestDeliveryAddress.js +2 -2
  173. package/serialization/resources/accounting/types/PurchaseOrderRequestLineItemsItem.d.ts +2 -2
  174. package/serialization/resources/accounting/types/PurchaseOrderRequestLineItemsItem.js +2 -2
  175. package/serialization/resources/accounting/types/PurchaseOrderRequestVendor.d.ts +2 -2
  176. package/serialization/resources/accounting/types/PurchaseOrderRequestVendor.js +2 -2
  177. package/serialization/resources/accounting/types/RemoteFieldApi.d.ts +2 -2
  178. package/serialization/resources/accounting/types/RemoteFieldApi.js +2 -2
  179. package/serialization/resources/accounting/types/SalesOrderRequestRequestCustomer.d.ts +2 -2
  180. package/serialization/resources/accounting/types/SalesOrderRequestRequestCustomer.js +2 -2
  181. package/serialization/resources/accounting/types/SalesOrderRequestRequestShippingAddress.d.ts +2 -2
  182. package/serialization/resources/accounting/types/SalesOrderRequestRequestShippingAddress.js +2 -2
  183. package/serialization/resources/accounting/types/VendorCreditApplyLineForVendorCreditRequestInvoice.d.ts +2 -3
  184. package/serialization/resources/accounting/types/VendorCreditApplyLineForVendorCreditRequestInvoice.js +5 -2
  185. package/serialization/resources/accounting/types/VendorCreditLineRequestAccount.d.ts +2 -2
  186. package/serialization/resources/accounting/types/VendorCreditLineRequestAccount.js +2 -2
  187. package/serialization/resources/accounting/types/VendorCreditLineRequestContact.d.ts +2 -2
  188. package/serialization/resources/accounting/types/VendorCreditLineRequestContact.js +2 -2
  189. package/serialization/resources/accounting/types/VendorCreditRequestVendor.d.ts +2 -2
  190. package/serialization/resources/accounting/types/VendorCreditRequestVendor.js +2 -2
  191. package/serialization/resources/accounting/types/WarningValidationProblem.d.ts +2 -0
  192. package/serialization/resources/accounting/types/WarningValidationProblem.js +2 -0
  193. package/serialization/resources/accounting/types/index.d.ts +4 -3
  194. package/serialization/resources/accounting/types/index.js +4 -3
  195. package/version.d.ts +1 -1
  196. package/version.js +1 -1
  197. package/api/resources/accounting/resources/expenses/client/requests/ExpensesBatchObjectsListRequest.d.ts +0 -52
  198. package/api/resources/accounting/resources/expenses/types/ExpensesBatchObjectsListRequestExpandItem.d.ts +0 -9
  199. package/api/resources/accounting/resources/expenses/types/ExpensesBatchObjectsListRequestExpandItem.js +0 -12
  200. package/api/resources/accounting/resources/invoices/client/requests/InvoicesBatchObjectsListRequest.d.ts +0 -84
  201. package/api/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestExpandItem.d.ts +0 -16
  202. package/api/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestExpandItem.js +0 -19
  203. package/api/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestStatus.d.ts +0 -9
  204. package/api/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestStatus.js +0 -12
  205. package/api/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestType.d.ts +0 -5
  206. package/api/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestType.js +0 -8
  207. package/api/resources/accounting/resources/itemFulfillments/client/requests/ItemFulfillmentsBatchObjectsListRequest.d.ts +0 -34
  208. package/api/resources/accounting/resources/itemFulfillments/client/requests/ItemFulfillmentsBatchObjectsListRequest.js +0 -3
  209. package/api/resources/accounting/resources/itemFulfillments/types/ItemFulfillmentsBatchObjectsListRequestExpandItem.d.ts +0 -7
  210. package/api/resources/accounting/resources/itemFulfillments/types/ItemFulfillmentsBatchObjectsListRequestExpandItem.js +0 -10
  211. package/api/resources/accounting/resources/salesOrders/client/requests/SalesOrdersBatchObjectsListRequest.d.ts +0 -58
  212. package/api/resources/accounting/resources/salesOrders/client/requests/SalesOrdersBatchObjectsListRequest.js +0 -3
  213. package/api/resources/accounting/resources/salesOrders/types/SalesOrdersBatchObjectsListRequestExpandItem.d.ts +0 -9
  214. package/api/resources/accounting/resources/salesOrders/types/SalesOrdersBatchObjectsListRequestExpandItem.js +0 -12
  215. package/api/resources/accounting/types/DataPassthroughRequestMethod.d.ts +0 -2
  216. package/api/resources/accounting/types/DataPassthroughRequestMethod.js +0 -3
  217. package/api/resources/accounting/types/DataPassthroughRequestRequestFormat.d.ts +0 -2
  218. package/api/resources/accounting/types/DataPassthroughRequestRequestFormat.js +0 -3
  219. package/api/resources/accounting/types/RemoteFieldApiAdvancedMetadata.d.ts +0 -2
  220. package/api/resources/accounting/types/RemoteFieldApiAdvancedMetadata.js +0 -3
  221. package/serialization/resources/accounting/resources/expenses/types/ExpensesBatchObjectsListRequestExpandItem.d.ts +0 -7
  222. package/serialization/resources/accounting/resources/expenses/types/ExpensesBatchObjectsListRequestExpandItem.js +0 -39
  223. package/serialization/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestExpandItem.d.ts +0 -7
  224. package/serialization/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestExpandItem.js +0 -53
  225. package/serialization/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestStatus.d.ts +0 -7
  226. package/serialization/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestStatus.js +0 -39
  227. package/serialization/resources/accounting/resources/invoices/types/InvoicesBatchObjectsListRequestType.d.ts +0 -7
  228. package/serialization/resources/accounting/resources/itemFulfillments/types/ItemFulfillmentsBatchObjectsListRequestExpandItem.d.ts +0 -7
  229. package/serialization/resources/accounting/resources/itemFulfillments/types/ItemFulfillmentsBatchObjectsListRequestExpandItem.js +0 -39
  230. package/serialization/resources/accounting/resources/salesOrders/types/SalesOrdersBatchObjectsListRequestExpandItem.d.ts +0 -7
  231. package/serialization/resources/accounting/resources/salesOrders/types/SalesOrdersBatchObjectsListRequestExpandItem.js +0 -46
  232. package/serialization/resources/accounting/types/DataPassthroughRequestMethod.d.ts +0 -8
  233. package/serialization/resources/accounting/types/DataPassthroughRequestRequestFormat.d.ts +0 -8
  234. package/serialization/resources/accounting/types/RemoteFieldApiAdvancedMetadata.d.ts +0 -8
  235. /package/api/resources/accounting/{resources/expenses/client/requests/ExpensesBatchObjectsListRequest.js → types/BatchObjectStatus.js} +0 -0
  236. /package/api/resources/accounting/{resources/invoices/client/requests/InvoicesBatchObjectsListRequest.js → types/BatchObjectsResponseStatus.js} +0 -0
package/BaseClient.js CHANGED
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
43
43
  const headers = (0, headers_1.mergeHeaders)({
44
44
  "X-Fern-Language": "JavaScript",
45
45
  "X-Fern-SDK-Name": "@mergeapi/merge-node-client",
46
- "X-Fern-SDK-Version": "3.0.2",
47
- "User-Agent": "@mergeapi/merge-node-client/3.0.2",
46
+ "X-Fern-SDK-Version": "4.0.0-alpha.1",
47
+ "User-Agent": "@mergeapi/merge-node-client/4.0.0-alpha.1",
48
48
  "X-Fern-Runtime": core.RUNTIME.type,
49
49
  "X-Fern-Runtime-Version": core.RUNTIME.version,
50
50
  "X-Account-Token": options === null || options === void 0 ? void 0 : options.accountToken,
@@ -67,50 +67,32 @@ export declare class ExpensesClient {
67
67
  retrieve(id: string, request?: Merge.accounting.ExpensesRetrieveRequest, requestOptions?: ExpensesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.Expense>;
68
68
  private __retrieve;
69
69
  /**
70
- * Creates an `Expense` object with the given values.
70
+ * Creates multiple `Expense` objects with the given values.
71
71
  *
72
72
  * @param {Merge.accounting.ExpenseBulkRequest} request
73
73
  * @param {ExpensesClient.RequestOptions} requestOptions - Request-specific configuration.
74
74
  *
75
75
  * @example
76
- * await client.accounting.expenses.asyncBulkCreate({
77
- * isDebugMode: true,
78
- * runAsync: true,
76
+ * await client.accounting.expenses.bulkCreate({
79
77
  * batchItems: [{
80
78
  * itemId: "item_id",
81
79
  * payload: {}
82
80
  * }]
83
81
  * })
84
82
  */
85
- asyncBulkCreate(request: Merge.accounting.ExpenseBulkRequest, requestOptions?: ExpensesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.AsyncBulkCreateResponse>;
86
- private __asyncBulkCreate;
83
+ bulkCreate(request: Merge.accounting.ExpenseBulkRequest, requestOptions?: ExpensesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.AsyncBulkCreateResponse>;
84
+ private __bulkCreate;
87
85
  /**
88
- * Returns a list of `Expense` objects.
86
+ * Returns the status and results of an `Expense` bulk create batch.
89
87
  *
90
88
  * @param {string} batch_id
91
- * @param {Merge.accounting.ExpensesBatchObjectsListRequest} request
92
89
  * @param {ExpensesClient.RequestOptions} requestOptions - Request-specific configuration.
93
90
  *
94
91
  * @example
95
- * await client.accounting.expenses.batchObjectsList("batch_id", {
96
- * companyId: "company_id",
97
- * createdAfter: new Date("2024-01-15T09:30:00.000Z"),
98
- * createdBefore: new Date("2024-01-15T09:30:00.000Z"),
99
- * cursor: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw",
100
- * includeDeletedData: true,
101
- * includeRemoteData: true,
102
- * includeRemoteFields: true,
103
- * includeShellData: true,
104
- * modifiedAfter: new Date("2024-01-15T09:30:00.000Z"),
105
- * modifiedBefore: new Date("2024-01-15T09:30:00.000Z"),
106
- * pageSize: 1,
107
- * remoteId: "remote_id",
108
- * transactionDateAfter: new Date("2024-01-15T09:30:00.000Z"),
109
- * transactionDateBefore: new Date("2024-01-15T09:30:00.000Z")
110
- * })
92
+ * await client.accounting.expenses.bulkRetrieve("batch_id")
111
93
  */
112
- batchObjectsList(batch_id: string, request?: Merge.accounting.ExpensesBatchObjectsListRequest, requestOptions?: ExpensesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.BatchObjectsResponse>;
113
- private __batchObjectsList;
94
+ bulkRetrieve(batch_id: string, requestOptions?: ExpensesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.BatchObjectsResponse>;
95
+ private __bulkRetrieve;
114
96
  /**
115
97
  * Returns a list of `RemoteFieldClass` objects.
116
98
  *
@@ -301,42 +301,35 @@ class ExpensesClient {
301
301
  });
302
302
  }
303
303
  /**
304
- * Creates an `Expense` object with the given values.
304
+ * Creates multiple `Expense` objects with the given values.
305
305
  *
306
306
  * @param {Merge.accounting.ExpenseBulkRequest} request
307
307
  * @param {ExpensesClient.RequestOptions} requestOptions - Request-specific configuration.
308
308
  *
309
309
  * @example
310
- * await client.accounting.expenses.asyncBulkCreate({
311
- * isDebugMode: true,
312
- * runAsync: true,
310
+ * await client.accounting.expenses.bulkCreate({
313
311
  * batchItems: [{
314
312
  * itemId: "item_id",
315
313
  * payload: {}
316
314
  * }]
317
315
  * })
318
316
  */
319
- asyncBulkCreate(request, requestOptions) {
320
- return core.HttpResponsePromise.fromPromise(this.__asyncBulkCreate(request, requestOptions));
317
+ bulkCreate(request, requestOptions) {
318
+ return core.HttpResponsePromise.fromPromise(this.__bulkCreate(request, requestOptions));
321
319
  }
322
- __asyncBulkCreate(request, requestOptions) {
320
+ __bulkCreate(request, requestOptions) {
323
321
  return __awaiter(this, void 0, void 0, function* () {
324
322
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
325
- const { isDebugMode, runAsync } = request, _body = __rest(request, ["isDebugMode", "runAsync"]);
326
- const _queryParams = {
327
- is_debug_mode: isDebugMode,
328
- run_async: runAsync,
329
- };
330
323
  const _authRequest = yield this._options.authProvider.getAuthRequest();
331
324
  const _headers = (0, headers_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_1.mergeOnlyDefinedHeaders)({ "X-Account-Token": (_b = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.accountToken) !== null && _b !== void 0 ? _b : (_c = this._options) === null || _c === void 0 ? void 0 : _c.accountToken }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
332
325
  const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
333
- 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.MergeEnvironment.Production, "accounting/v1/expenses/async/bulk"),
326
+ 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.MergeEnvironment.Production, "accounting/v1/expenses/bulk"),
334
327
  method: "POST",
335
328
  headers: _headers,
336
329
  contentType: "application/json",
337
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
330
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
338
331
  requestType: "json",
339
- body: serializers.accounting.ExpenseBulkRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
332
+ body: serializers.accounting.ExpenseBulkRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
340
333
  timeoutMs: ((_j = (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.timeoutInSeconds) !== null && _j !== void 0 ? _j : 60) * 1000,
341
334
  maxRetries: (_k = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _k !== void 0 ? _k : (_l = this._options) === null || _l === void 0 ? void 0 : _l.maxRetries,
342
335
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -362,73 +355,31 @@ class ExpensesClient {
362
355
  rawResponse: _response.rawResponse,
363
356
  });
364
357
  }
365
- return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/accounting/v1/expenses/async/bulk");
358
+ return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/accounting/v1/expenses/bulk");
366
359
  });
367
360
  }
368
361
  /**
369
- * Returns a list of `Expense` objects.
362
+ * Returns the status and results of an `Expense` bulk create batch.
370
363
  *
371
364
  * @param {string} batch_id
372
- * @param {Merge.accounting.ExpensesBatchObjectsListRequest} request
373
365
  * @param {ExpensesClient.RequestOptions} requestOptions - Request-specific configuration.
374
366
  *
375
367
  * @example
376
- * await client.accounting.expenses.batchObjectsList("batch_id", {
377
- * companyId: "company_id",
378
- * createdAfter: new Date("2024-01-15T09:30:00.000Z"),
379
- * createdBefore: new Date("2024-01-15T09:30:00.000Z"),
380
- * cursor: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw",
381
- * includeDeletedData: true,
382
- * includeRemoteData: true,
383
- * includeRemoteFields: true,
384
- * includeShellData: true,
385
- * modifiedAfter: new Date("2024-01-15T09:30:00.000Z"),
386
- * modifiedBefore: new Date("2024-01-15T09:30:00.000Z"),
387
- * pageSize: 1,
388
- * remoteId: "remote_id",
389
- * transactionDateAfter: new Date("2024-01-15T09:30:00.000Z"),
390
- * transactionDateBefore: new Date("2024-01-15T09:30:00.000Z")
391
- * })
368
+ * await client.accounting.expenses.bulkRetrieve("batch_id")
392
369
  */
393
- batchObjectsList(batch_id, request = {}, requestOptions) {
394
- return core.HttpResponsePromise.fromPromise(this.__batchObjectsList(batch_id, request, requestOptions));
370
+ bulkRetrieve(batch_id, requestOptions) {
371
+ return core.HttpResponsePromise.fromPromise(this.__bulkRetrieve(batch_id, requestOptions));
395
372
  }
396
- __batchObjectsList(batch_id_1) {
397
- return __awaiter(this, arguments, void 0, function* (batch_id, request = {}, requestOptions) {
373
+ __bulkRetrieve(batch_id, requestOptions) {
374
+ return __awaiter(this, void 0, void 0, function* () {
398
375
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
399
- const { companyId, createdAfter, createdBefore, cursor, expand, includeDeletedData, includeRemoteData, includeRemoteFields, includeShellData, modifiedAfter, modifiedBefore, pageSize, remoteId, transactionDateAfter, transactionDateBefore, } = request;
400
- const _queryParams = {
401
- company_id: companyId,
402
- created_after: createdAfter === null || createdAfter === void 0 ? void 0 : createdAfter.toISOString(),
403
- created_before: createdBefore === null || createdBefore === void 0 ? void 0 : createdBefore.toISOString(),
404
- cursor,
405
- expand: Array.isArray(expand)
406
- ? expand.map((item) => serializers.accounting.ExpensesBatchObjectsListRequestExpandItem.jsonOrThrow(item, {
407
- unrecognizedObjectKeys: "strip",
408
- }))
409
- : expand != null
410
- ? serializers.accounting.ExpensesBatchObjectsListRequestExpandItem.jsonOrThrow(expand, {
411
- unrecognizedObjectKeys: "strip",
412
- })
413
- : undefined,
414
- include_deleted_data: includeDeletedData,
415
- include_remote_data: includeRemoteData,
416
- include_remote_fields: includeRemoteFields,
417
- include_shell_data: includeShellData,
418
- modified_after: modifiedAfter === null || modifiedAfter === void 0 ? void 0 : modifiedAfter.toISOString(),
419
- modified_before: modifiedBefore === null || modifiedBefore === void 0 ? void 0 : modifiedBefore.toISOString(),
420
- page_size: pageSize,
421
- remote_id: remoteId,
422
- transaction_date_after: transactionDateAfter === null || transactionDateAfter === void 0 ? void 0 : transactionDateAfter.toISOString(),
423
- transaction_date_before: transactionDateBefore === null || transactionDateBefore === void 0 ? void 0 : transactionDateBefore.toISOString(),
424
- };
425
376
  const _authRequest = yield this._options.authProvider.getAuthRequest();
426
377
  const _headers = (0, headers_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_1.mergeOnlyDefinedHeaders)({ "X-Account-Token": (_b = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.accountToken) !== null && _b !== void 0 ? _b : (_c = this._options) === null || _c === void 0 ? void 0 : _c.accountToken }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
427
378
  const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
428
- 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.MergeEnvironment.Production, `accounting/v1/expenses/batch/${core.url.encodePathParam(batch_id)}/objects`),
379
+ 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.MergeEnvironment.Production, `accounting/v1/expenses/bulk/${core.url.encodePathParam(batch_id)}`),
429
380
  method: "GET",
430
381
  headers: _headers,
431
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
382
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
432
383
  timeoutMs: ((_j = (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.timeoutInSeconds) !== null && _j !== void 0 ? _j : 60) * 1000,
433
384
  maxRetries: (_k = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _k !== void 0 ? _k : (_l = this._options) === null || _l === void 0 ? void 0 : _l.maxRetries,
434
385
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -454,7 +405,7 @@ class ExpensesClient {
454
405
  rawResponse: _response.rawResponse,
455
406
  });
456
407
  }
457
- return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/accounting/v1/expenses/batch/{batch_id}/objects");
408
+ return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/accounting/v1/expenses/bulk/{batch_id}");
458
409
  });
459
410
  }
460
411
  /**
@@ -2,8 +2,6 @@ import type * as Merge from "../../../../../../index";
2
2
  /**
3
3
  * @example
4
4
  * {
5
- * isDebugMode: true,
6
- * runAsync: true,
7
5
  * batchItems: [{
8
6
  * itemId: "item_id",
9
7
  * payload: {}
@@ -11,9 +9,5 @@ import type * as Merge from "../../../../../../index";
11
9
  * }
12
10
  */
13
11
  export interface ExpenseBulkRequest {
14
- /** Whether to include debug fields (such as log file links) in the response. */
15
- isDebugMode?: boolean;
16
- /** Whether or not third-party updates should be run asynchronously. */
17
- runAsync?: boolean;
18
12
  batchItems: Merge.accounting.ExpenseBatchItemRequest[];
19
13
  }
@@ -1,6 +1,5 @@
1
1
  export type { ExpenseBulkRequest } from "./ExpenseBulkRequest";
2
2
  export type { ExpenseEndpointRequest } from "./ExpenseEndpointRequest";
3
- export type { ExpensesBatchObjectsListRequest } from "./ExpensesBatchObjectsListRequest";
4
3
  export type { ExpensesLinesRemoteFieldClassesListRequest } from "./ExpensesLinesRemoteFieldClassesListRequest";
5
4
  export type { ExpensesListRequest } from "./ExpensesListRequest";
6
5
  export type { ExpensesRemoteFieldClassesListRequest } from "./ExpensesRemoteFieldClassesListRequest";
@@ -1,3 +1,2 @@
1
- export * from "./ExpensesBatchObjectsListRequestExpandItem";
2
1
  export * from "./ExpensesListRequestExpandItem";
3
2
  export * from "./ExpensesRetrieveRequestExpandItem";
@@ -14,6 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./ExpensesBatchObjectsListRequestExpandItem"), exports);
18
17
  __exportStar(require("./ExpensesListRequestExpandItem"), exports);
19
18
  __exportStar(require("./ExpensesRetrieveRequestExpandItem"), exports);
@@ -93,58 +93,32 @@ export declare class InvoicesClient {
93
93
  partialUpdate(id: string, request: Merge.accounting.PatchedInvoiceEndpointRequest, requestOptions?: InvoicesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.InvoiceResponse>;
94
94
  private __partialUpdate;
95
95
  /**
96
- * Creates an `Invoice` object with the given values.
97
- * Including a `PurchaseOrder` id in the `purchase_orders` property will generate an Accounts Payable Invoice from the specified Purchase Order(s).
98
- *
96
+ * Creates multiple `Invoice` objects with the given values.
99
97
  *
100
98
  * @param {Merge.accounting.InvoiceBulkRequest} request
101
99
  * @param {InvoicesClient.RequestOptions} requestOptions - Request-specific configuration.
102
100
  *
103
101
  * @example
104
- * await client.accounting.invoices.asyncBulkCreate({
105
- * isDebugMode: true,
106
- * runAsync: true,
102
+ * await client.accounting.invoices.bulkCreate({
107
103
  * batchItems: [{
108
104
  * itemId: "item_id",
109
105
  * payload: {}
110
106
  * }]
111
107
  * })
112
108
  */
113
- asyncBulkCreate(request: Merge.accounting.InvoiceBulkRequest, requestOptions?: InvoicesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.AsyncBulkCreateResponse>;
114
- private __asyncBulkCreate;
109
+ bulkCreate(request: Merge.accounting.InvoiceBulkRequest, requestOptions?: InvoicesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.AsyncBulkCreateResponse>;
110
+ private __bulkCreate;
115
111
  /**
116
- * Returns a list of `Invoice` objects.
112
+ * Returns the status and results of an `Invoice` bulk create batch.
117
113
  *
118
114
  * @param {string} batch_id
119
- * @param {Merge.accounting.InvoicesBatchObjectsListRequest} request
120
115
  * @param {InvoicesClient.RequestOptions} requestOptions - Request-specific configuration.
121
116
  *
122
117
  * @example
123
- * await client.accounting.invoices.batchObjectsList("batch_id", {
124
- * companyId: "company_id",
125
- * contactId: "contact_id",
126
- * createdAfter: new Date("2024-01-15T09:30:00.000Z"),
127
- * createdBefore: new Date("2024-01-15T09:30:00.000Z"),
128
- * cursor: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw",
129
- * includeDeletedData: true,
130
- * includeRemoteData: true,
131
- * includeRemoteFields: true,
132
- * includeShellData: true,
133
- * issueDateAfter: new Date("2024-01-15T09:30:00.000Z"),
134
- * issueDateBefore: new Date("2024-01-15T09:30:00.000Z"),
135
- * modifiedAfter: new Date("2024-01-15T09:30:00.000Z"),
136
- * modifiedBefore: new Date("2024-01-15T09:30:00.000Z"),
137
- * number: "number",
138
- * pageSize: 1,
139
- * remoteFields: "type",
140
- * remoteId: "remote_id",
141
- * showEnumOrigins: "type",
142
- * status: "DRAFT",
143
- * type: "ACCOUNTS_PAYABLE"
144
- * })
118
+ * await client.accounting.invoices.bulkRetrieve("batch_id")
145
119
  */
146
- batchObjectsList(batch_id: string, request?: Merge.accounting.InvoicesBatchObjectsListRequest, requestOptions?: InvoicesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.BatchObjectsResponse>;
147
- private __batchObjectsList;
120
+ bulkRetrieve(batch_id: string, requestOptions?: InvoicesClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.BatchObjectsResponse>;
121
+ private __bulkRetrieve;
148
122
  /**
149
123
  * Returns a list of `RemoteFieldClass` objects.
150
124
  *
@@ -392,44 +392,35 @@ class InvoicesClient {
392
392
  });
393
393
  }
394
394
  /**
395
- * Creates an `Invoice` object with the given values.
396
- * Including a `PurchaseOrder` id in the `purchase_orders` property will generate an Accounts Payable Invoice from the specified Purchase Order(s).
397
- *
395
+ * Creates multiple `Invoice` objects with the given values.
398
396
  *
399
397
  * @param {Merge.accounting.InvoiceBulkRequest} request
400
398
  * @param {InvoicesClient.RequestOptions} requestOptions - Request-specific configuration.
401
399
  *
402
400
  * @example
403
- * await client.accounting.invoices.asyncBulkCreate({
404
- * isDebugMode: true,
405
- * runAsync: true,
401
+ * await client.accounting.invoices.bulkCreate({
406
402
  * batchItems: [{
407
403
  * itemId: "item_id",
408
404
  * payload: {}
409
405
  * }]
410
406
  * })
411
407
  */
412
- asyncBulkCreate(request, requestOptions) {
413
- return core.HttpResponsePromise.fromPromise(this.__asyncBulkCreate(request, requestOptions));
408
+ bulkCreate(request, requestOptions) {
409
+ return core.HttpResponsePromise.fromPromise(this.__bulkCreate(request, requestOptions));
414
410
  }
415
- __asyncBulkCreate(request, requestOptions) {
411
+ __bulkCreate(request, requestOptions) {
416
412
  return __awaiter(this, void 0, void 0, function* () {
417
413
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
418
- const { isDebugMode, runAsync } = request, _body = __rest(request, ["isDebugMode", "runAsync"]);
419
- const _queryParams = {
420
- is_debug_mode: isDebugMode,
421
- run_async: runAsync,
422
- };
423
414
  const _authRequest = yield this._options.authProvider.getAuthRequest();
424
415
  const _headers = (0, headers_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_1.mergeOnlyDefinedHeaders)({ "X-Account-Token": (_b = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.accountToken) !== null && _b !== void 0 ? _b : (_c = this._options) === null || _c === void 0 ? void 0 : _c.accountToken }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
425
416
  const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
426
- 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.MergeEnvironment.Production, "accounting/v1/invoices/async/bulk"),
417
+ 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.MergeEnvironment.Production, "accounting/v1/invoices/bulk"),
427
418
  method: "POST",
428
419
  headers: _headers,
429
420
  contentType: "application/json",
430
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
421
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
431
422
  requestType: "json",
432
- body: serializers.accounting.InvoiceBulkRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
423
+ body: serializers.accounting.InvoiceBulkRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
433
424
  timeoutMs: ((_j = (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.timeoutInSeconds) !== null && _j !== void 0 ? _j : 60) * 1000,
434
425
  maxRetries: (_k = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _k !== void 0 ? _k : (_l = this._options) === null || _l === void 0 ? void 0 : _l.maxRetries,
435
426
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -455,93 +446,31 @@ class InvoicesClient {
455
446
  rawResponse: _response.rawResponse,
456
447
  });
457
448
  }
458
- return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/accounting/v1/invoices/async/bulk");
449
+ return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/accounting/v1/invoices/bulk");
459
450
  });
460
451
  }
461
452
  /**
462
- * Returns a list of `Invoice` objects.
453
+ * Returns the status and results of an `Invoice` bulk create batch.
463
454
  *
464
455
  * @param {string} batch_id
465
- * @param {Merge.accounting.InvoicesBatchObjectsListRequest} request
466
456
  * @param {InvoicesClient.RequestOptions} requestOptions - Request-specific configuration.
467
457
  *
468
458
  * @example
469
- * await client.accounting.invoices.batchObjectsList("batch_id", {
470
- * companyId: "company_id",
471
- * contactId: "contact_id",
472
- * createdAfter: new Date("2024-01-15T09:30:00.000Z"),
473
- * createdBefore: new Date("2024-01-15T09:30:00.000Z"),
474
- * cursor: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw",
475
- * includeDeletedData: true,
476
- * includeRemoteData: true,
477
- * includeRemoteFields: true,
478
- * includeShellData: true,
479
- * issueDateAfter: new Date("2024-01-15T09:30:00.000Z"),
480
- * issueDateBefore: new Date("2024-01-15T09:30:00.000Z"),
481
- * modifiedAfter: new Date("2024-01-15T09:30:00.000Z"),
482
- * modifiedBefore: new Date("2024-01-15T09:30:00.000Z"),
483
- * number: "number",
484
- * pageSize: 1,
485
- * remoteFields: "type",
486
- * remoteId: "remote_id",
487
- * showEnumOrigins: "type",
488
- * status: "DRAFT",
489
- * type: "ACCOUNTS_PAYABLE"
490
- * })
459
+ * await client.accounting.invoices.bulkRetrieve("batch_id")
491
460
  */
492
- batchObjectsList(batch_id, request = {}, requestOptions) {
493
- return core.HttpResponsePromise.fromPromise(this.__batchObjectsList(batch_id, request, requestOptions));
461
+ bulkRetrieve(batch_id, requestOptions) {
462
+ return core.HttpResponsePromise.fromPromise(this.__bulkRetrieve(batch_id, requestOptions));
494
463
  }
495
- __batchObjectsList(batch_id_1) {
496
- return __awaiter(this, arguments, void 0, function* (batch_id, request = {}, requestOptions) {
464
+ __bulkRetrieve(batch_id, requestOptions) {
465
+ return __awaiter(this, void 0, void 0, function* () {
497
466
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
498
- const { companyId, contactId, createdAfter, createdBefore, cursor, expand, includeDeletedData, includeRemoteData, includeRemoteFields, includeShellData, issueDateAfter, issueDateBefore, modifiedAfter, modifiedBefore, number: number_, pageSize, remoteFields, remoteId, showEnumOrigins, status, type: type_, } = request;
499
- const _queryParams = {
500
- company_id: companyId,
501
- contact_id: contactId,
502
- created_after: createdAfter === null || createdAfter === void 0 ? void 0 : createdAfter.toISOString(),
503
- created_before: createdBefore === null || createdBefore === void 0 ? void 0 : createdBefore.toISOString(),
504
- cursor,
505
- expand: Array.isArray(expand)
506
- ? expand.map((item) => serializers.accounting.InvoicesBatchObjectsListRequestExpandItem.jsonOrThrow(item, {
507
- unrecognizedObjectKeys: "strip",
508
- }))
509
- : expand != null
510
- ? serializers.accounting.InvoicesBatchObjectsListRequestExpandItem.jsonOrThrow(expand, {
511
- unrecognizedObjectKeys: "strip",
512
- })
513
- : undefined,
514
- include_deleted_data: includeDeletedData,
515
- include_remote_data: includeRemoteData,
516
- include_remote_fields: includeRemoteFields,
517
- include_shell_data: includeShellData,
518
- issue_date_after: issueDateAfter === null || issueDateAfter === void 0 ? void 0 : issueDateAfter.toISOString(),
519
- issue_date_before: issueDateBefore === null || issueDateBefore === void 0 ? void 0 : issueDateBefore.toISOString(),
520
- modified_after: modifiedAfter === null || modifiedAfter === void 0 ? void 0 : modifiedAfter.toISOString(),
521
- modified_before: modifiedBefore === null || modifiedBefore === void 0 ? void 0 : modifiedBefore.toISOString(),
522
- number: number_,
523
- page_size: pageSize,
524
- remote_fields: remoteFields != null ? remoteFields : undefined,
525
- remote_id: remoteId,
526
- show_enum_origins: showEnumOrigins != null ? showEnumOrigins : undefined,
527
- status: status != null
528
- ? serializers.accounting.InvoicesBatchObjectsListRequestStatus.jsonOrThrow(status, {
529
- unrecognizedObjectKeys: "strip",
530
- })
531
- : undefined,
532
- type: type_ != null
533
- ? serializers.accounting.InvoicesBatchObjectsListRequestType.jsonOrThrow(type_, {
534
- unrecognizedObjectKeys: "strip",
535
- })
536
- : undefined,
537
- };
538
467
  const _authRequest = yield this._options.authProvider.getAuthRequest();
539
468
  const _headers = (0, headers_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, (0, headers_1.mergeOnlyDefinedHeaders)({ "X-Account-Token": (_b = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.accountToken) !== null && _b !== void 0 ? _b : (_c = this._options) === null || _c === void 0 ? void 0 : _c.accountToken }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
540
469
  const _response = yield ((_d = this._options.fetcher) !== null && _d !== void 0 ? _d : core.fetcher)({
541
- 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.MergeEnvironment.Production, `accounting/v1/invoices/batch/${core.url.encodePathParam(batch_id)}/objects`),
470
+ 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.MergeEnvironment.Production, `accounting/v1/invoices/bulk/${core.url.encodePathParam(batch_id)}`),
542
471
  method: "GET",
543
472
  headers: _headers,
544
- queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
473
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
545
474
  timeoutMs: ((_j = (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.timeoutInSeconds) !== null && _j !== void 0 ? _j : 60) * 1000,
546
475
  maxRetries: (_k = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _k !== void 0 ? _k : (_l = this._options) === null || _l === void 0 ? void 0 : _l.maxRetries,
547
476
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
@@ -567,7 +496,7 @@ class InvoicesClient {
567
496
  rawResponse: _response.rawResponse,
568
497
  });
569
498
  }
570
- return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/accounting/v1/invoices/batch/{batch_id}/objects");
499
+ return (0, handleNonStatusCodeError_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/accounting/v1/invoices/bulk/{batch_id}");
571
500
  });
572
501
  }
573
502
  /**
@@ -2,8 +2,6 @@ import type * as Merge from "../../../../../../index";
2
2
  /**
3
3
  * @example
4
4
  * {
5
- * isDebugMode: true,
6
- * runAsync: true,
7
5
  * batchItems: [{
8
6
  * itemId: "item_id",
9
7
  * payload: {}
@@ -11,9 +9,5 @@ import type * as Merge from "../../../../../../index";
11
9
  * }
12
10
  */
13
11
  export interface InvoiceBulkRequest {
14
- /** Whether to include debug fields (such as log file links) in the response. */
15
- isDebugMode?: boolean;
16
- /** Whether or not third-party updates should be run asynchronously. */
17
- runAsync?: boolean;
18
12
  batchItems: Merge.accounting.InvoiceBatchItemRequest[];
19
13
  }
@@ -1,6 +1,5 @@
1
1
  export type { InvoiceBulkRequest } from "./InvoiceBulkRequest";
2
2
  export type { InvoiceEndpointRequest } from "./InvoiceEndpointRequest";
3
- export type { InvoicesBatchObjectsListRequest } from "./InvoicesBatchObjectsListRequest";
4
3
  export type { InvoicesLineItemsRemoteFieldClassesListRequest } from "./InvoicesLineItemsRemoteFieldClassesListRequest";
5
4
  export type { InvoicesListRequest } from "./InvoicesListRequest";
6
5
  export type { InvoicesRemoteFieldClassesListRequest } from "./InvoicesRemoteFieldClassesListRequest";
@@ -1,6 +1,3 @@
1
- export * from "./InvoicesBatchObjectsListRequestExpandItem";
2
- export * from "./InvoicesBatchObjectsListRequestStatus";
3
- export * from "./InvoicesBatchObjectsListRequestType";
4
1
  export * from "./InvoicesListRequestExpandItem";
5
2
  export * from "./InvoicesListRequestStatus";
6
3
  export * from "./InvoicesListRequestType";
@@ -14,9 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./InvoicesBatchObjectsListRequestExpandItem"), exports);
18
- __exportStar(require("./InvoicesBatchObjectsListRequestStatus"), exports);
19
- __exportStar(require("./InvoicesBatchObjectsListRequestType"), exports);
20
17
  __exportStar(require("./InvoicesListRequestExpandItem"), exports);
21
18
  __exportStar(require("./InvoicesListRequestStatus"), exports);
22
19
  __exportStar(require("./InvoicesListRequestType"), exports);
@@ -63,44 +63,32 @@ export declare class ItemFulfillmentsClient {
63
63
  retrieve(id: string, request?: Merge.accounting.ItemFulfillmentsRetrieveRequest, requestOptions?: ItemFulfillmentsClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.ItemFulfillment>;
64
64
  private __retrieve;
65
65
  /**
66
- * Creates an `ItemFulfillment` object with the given values.
66
+ * Creates multiple `ItemFulfillment` objects with the given values.
67
67
  *
68
68
  * @param {Merge.accounting.ItemFulfillmentBulkRequest} request
69
69
  * @param {ItemFulfillmentsClient.RequestOptions} requestOptions - Request-specific configuration.
70
70
  *
71
71
  * @example
72
- * await client.accounting.itemFulfillments.asyncBulkCreate({
73
- * isDebugMode: true,
74
- * runAsync: true,
72
+ * await client.accounting.itemFulfillments.bulkCreate({
75
73
  * batchItems: [{
76
74
  * itemId: "item_id",
77
75
  * payload: {}
78
76
  * }]
79
77
  * })
80
78
  */
81
- asyncBulkCreate(request: Merge.accounting.ItemFulfillmentBulkRequest, requestOptions?: ItemFulfillmentsClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.AsyncBulkCreateResponse>;
82
- private __asyncBulkCreate;
79
+ bulkCreate(request: Merge.accounting.ItemFulfillmentBulkRequest, requestOptions?: ItemFulfillmentsClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.AsyncBulkCreateResponse>;
80
+ private __bulkCreate;
83
81
  /**
84
- * Returns a list of `ItemFulfillment` objects.
82
+ * Returns the status and results of an `ItemFulfillment` bulk create batch.
85
83
  *
86
84
  * @param {string} batch_id
87
- * @param {Merge.accounting.ItemFulfillmentsBatchObjectsListRequest} request
88
85
  * @param {ItemFulfillmentsClient.RequestOptions} requestOptions - Request-specific configuration.
89
86
  *
90
87
  * @example
91
- * await client.accounting.itemFulfillments.batchObjectsList("batch_id", {
92
- * cursor: "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw",
93
- * includeDeletedData: true,
94
- * includeRemoteData: true,
95
- * includeRemoteFields: true,
96
- * includeShellData: true,
97
- * pageSize: 1,
98
- * remoteFields: "status",
99
- * showEnumOrigins: "status"
100
- * })
88
+ * await client.accounting.itemFulfillments.bulkRetrieve("batch_id")
101
89
  */
102
- batchObjectsList(batch_id: string, request?: Merge.accounting.ItemFulfillmentsBatchObjectsListRequest, requestOptions?: ItemFulfillmentsClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.BatchObjectsResponse>;
103
- private __batchObjectsList;
90
+ bulkRetrieve(batch_id: string, requestOptions?: ItemFulfillmentsClient.RequestOptions): core.HttpResponsePromise<Merge.accounting.BatchObjectsResponse>;
91
+ private __bulkRetrieve;
104
92
  /**
105
93
  * Returns a list of `RemoteFieldClass` objects.
106
94
  *