@commercelayer/sdk 4.3.0 → 4.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (369) hide show
  1. package/lib/cjs/commercelayer.d.ts +2 -2
  2. package/lib/cjs/resource.d.ts +2 -0
  3. package/lib/cjs/resource.js +1 -1
  4. package/lib/cjs/resources/addresses.d.ts +1 -0
  5. package/lib/cjs/resources/addresses.js +1 -1
  6. package/lib/cjs/resources/adyen_gateways.d.ts +2 -0
  7. package/lib/cjs/resources/adyen_gateways.js +1 -1
  8. package/lib/cjs/resources/adyen_payments.d.ts +2 -0
  9. package/lib/cjs/resources/adyen_payments.js +1 -1
  10. package/lib/cjs/resources/authorizations.d.ts +3 -0
  11. package/lib/cjs/resources/authorizations.js +1 -1
  12. package/lib/cjs/resources/avalara_accounts.d.ts +3 -0
  13. package/lib/cjs/resources/avalara_accounts.js +1 -1
  14. package/lib/cjs/resources/billing_info_validation_rules.d.ts +1 -0
  15. package/lib/cjs/resources/billing_info_validation_rules.js +1 -1
  16. package/lib/cjs/resources/bing_geocoders.d.ts +2 -0
  17. package/lib/cjs/resources/bing_geocoders.js +1 -1
  18. package/lib/cjs/resources/braintree_gateways.d.ts +2 -0
  19. package/lib/cjs/resources/braintree_gateways.js +1 -1
  20. package/lib/cjs/resources/braintree_payments.d.ts +2 -0
  21. package/lib/cjs/resources/braintree_payments.js +1 -1
  22. package/lib/cjs/resources/bundles.d.ts +4 -0
  23. package/lib/cjs/resources/bundles.js +1 -1
  24. package/lib/cjs/resources/captures.d.ts +3 -0
  25. package/lib/cjs/resources/captures.js +1 -1
  26. package/lib/cjs/resources/carrier_accounts.d.ts +2 -0
  27. package/lib/cjs/resources/carrier_accounts.js +1 -1
  28. package/lib/cjs/resources/checkout_com_gateways.d.ts +2 -0
  29. package/lib/cjs/resources/checkout_com_gateways.js +1 -1
  30. package/lib/cjs/resources/checkout_com_payments.d.ts +2 -0
  31. package/lib/cjs/resources/checkout_com_payments.js +1 -1
  32. package/lib/cjs/resources/coupon_codes_promotion_rules.d.ts +1 -0
  33. package/lib/cjs/resources/coupon_codes_promotion_rules.js +1 -1
  34. package/lib/cjs/resources/coupon_recipients.d.ts +2 -0
  35. package/lib/cjs/resources/coupon_recipients.js +1 -1
  36. package/lib/cjs/resources/coupons.d.ts +1 -0
  37. package/lib/cjs/resources/coupons.js +1 -1
  38. package/lib/cjs/resources/customer_addresses.d.ts +2 -0
  39. package/lib/cjs/resources/customer_addresses.js +1 -1
  40. package/lib/cjs/resources/customer_groups.d.ts +3 -0
  41. package/lib/cjs/resources/customer_groups.js +1 -1
  42. package/lib/cjs/resources/customer_password_resets.d.ts +1 -0
  43. package/lib/cjs/resources/customer_password_resets.js +1 -1
  44. package/lib/cjs/resources/customer_payment_sources.d.ts +1 -0
  45. package/lib/cjs/resources/customer_payment_sources.js +1 -1
  46. package/lib/cjs/resources/customer_subscriptions.d.ts +1 -0
  47. package/lib/cjs/resources/customer_subscriptions.js +1 -1
  48. package/lib/cjs/resources/customers.d.ts +8 -0
  49. package/lib/cjs/resources/customers.js +1 -1
  50. package/lib/cjs/resources/delivery_lead_times.d.ts +3 -0
  51. package/lib/cjs/resources/delivery_lead_times.js +1 -1
  52. package/lib/cjs/resources/event_callbacks.d.ts +1 -0
  53. package/lib/cjs/resources/event_callbacks.js +1 -1
  54. package/lib/cjs/resources/external_gateways.d.ts +2 -0
  55. package/lib/cjs/resources/external_gateways.js +1 -1
  56. package/lib/cjs/resources/external_payments.d.ts +3 -0
  57. package/lib/cjs/resources/external_payments.js +1 -1
  58. package/lib/cjs/resources/external_promotions.d.ts +5 -0
  59. package/lib/cjs/resources/external_promotions.js +1 -1
  60. package/lib/cjs/resources/external_tax_calculators.d.ts +3 -0
  61. package/lib/cjs/resources/external_tax_calculators.js +1 -1
  62. package/lib/cjs/resources/fixed_amount_promotions.d.ts +5 -0
  63. package/lib/cjs/resources/fixed_amount_promotions.js +1 -1
  64. package/lib/cjs/resources/fixed_price_promotions.d.ts +7 -0
  65. package/lib/cjs/resources/fixed_price_promotions.js +1 -1
  66. package/lib/cjs/resources/free_gift_promotions.d.ts +7 -0
  67. package/lib/cjs/resources/free_gift_promotions.js +1 -1
  68. package/lib/cjs/resources/free_shipping_promotions.d.ts +5 -0
  69. package/lib/cjs/resources/free_shipping_promotions.js +1 -1
  70. package/lib/cjs/resources/geocoders.d.ts +2 -0
  71. package/lib/cjs/resources/geocoders.js +1 -1
  72. package/lib/cjs/resources/gift_card_recipients.d.ts +2 -0
  73. package/lib/cjs/resources/gift_card_recipients.js +1 -1
  74. package/lib/cjs/resources/gift_cards.d.ts +3 -0
  75. package/lib/cjs/resources/gift_cards.js +1 -1
  76. package/lib/cjs/resources/google_geocoders.d.ts +2 -0
  77. package/lib/cjs/resources/google_geocoders.js +1 -1
  78. package/lib/cjs/resources/in_stock_subscriptions.d.ts +3 -0
  79. package/lib/cjs/resources/in_stock_subscriptions.js +1 -1
  80. package/lib/cjs/resources/inventory_models.d.ts +3 -0
  81. package/lib/cjs/resources/inventory_models.js +1 -1
  82. package/lib/cjs/resources/inventory_return_locations.d.ts +2 -0
  83. package/lib/cjs/resources/inventory_return_locations.js +1 -1
  84. package/lib/cjs/resources/inventory_stock_locations.d.ts +2 -0
  85. package/lib/cjs/resources/inventory_stock_locations.js +1 -1
  86. package/lib/cjs/resources/klarna_gateways.d.ts +2 -0
  87. package/lib/cjs/resources/klarna_gateways.js +1 -1
  88. package/lib/cjs/resources/klarna_payments.d.ts +2 -0
  89. package/lib/cjs/resources/klarna_payments.js +1 -1
  90. package/lib/cjs/resources/line_item_options.d.ts +2 -0
  91. package/lib/cjs/resources/line_item_options.js +1 -1
  92. package/lib/cjs/resources/line_items.d.ts +4 -0
  93. package/lib/cjs/resources/line_items.js +1 -1
  94. package/lib/cjs/resources/manual_gateways.d.ts +1 -0
  95. package/lib/cjs/resources/manual_gateways.js +1 -1
  96. package/lib/cjs/resources/manual_tax_calculators.d.ts +4 -0
  97. package/lib/cjs/resources/manual_tax_calculators.js +1 -1
  98. package/lib/cjs/resources/markets.d.ts +6 -0
  99. package/lib/cjs/resources/markets.js +1 -1
  100. package/lib/cjs/resources/merchants.d.ts +2 -0
  101. package/lib/cjs/resources/merchants.js +1 -1
  102. package/lib/cjs/resources/order_copies.d.ts +3 -0
  103. package/lib/cjs/resources/order_copies.js +1 -1
  104. package/lib/cjs/resources/order_subscriptions.d.ts +5 -0
  105. package/lib/cjs/resources/order_subscriptions.js +1 -1
  106. package/lib/cjs/resources/order_validation_rules.d.ts +1 -0
  107. package/lib/cjs/resources/order_validation_rules.js +1 -1
  108. package/lib/cjs/resources/orders.d.ts +16 -0
  109. package/lib/cjs/resources/orders.js +1 -1
  110. package/lib/cjs/resources/packages.d.ts +3 -0
  111. package/lib/cjs/resources/packages.js +1 -1
  112. package/lib/cjs/resources/parcel_line_items.d.ts +2 -0
  113. package/lib/cjs/resources/parcel_line_items.js +1 -1
  114. package/lib/cjs/resources/parcels.d.ts +4 -0
  115. package/lib/cjs/resources/parcels.js +1 -1
  116. package/lib/cjs/resources/payment_gateways.d.ts +1 -0
  117. package/lib/cjs/resources/payment_gateways.js +1 -1
  118. package/lib/cjs/resources/payment_methods.d.ts +3 -0
  119. package/lib/cjs/resources/payment_methods.js +1 -1
  120. package/lib/cjs/resources/paypal_gateways.d.ts +2 -0
  121. package/lib/cjs/resources/paypal_gateways.js +1 -1
  122. package/lib/cjs/resources/paypal_payments.d.ts +2 -0
  123. package/lib/cjs/resources/paypal_payments.js +1 -1
  124. package/lib/cjs/resources/percentage_discount_promotions.d.ts +7 -0
  125. package/lib/cjs/resources/percentage_discount_promotions.js +1 -1
  126. package/lib/cjs/resources/price_lists.d.ts +2 -0
  127. package/lib/cjs/resources/price_lists.js +1 -1
  128. package/lib/cjs/resources/prices.d.ts +3 -0
  129. package/lib/cjs/resources/prices.js +1 -1
  130. package/lib/cjs/resources/promotions.d.ts +5 -0
  131. package/lib/cjs/resources/promotions.js +1 -1
  132. package/lib/cjs/resources/refunds.d.ts +2 -0
  133. package/lib/cjs/resources/refunds.js +1 -1
  134. package/lib/cjs/resources/return_line_items.d.ts +2 -0
  135. package/lib/cjs/resources/return_line_items.js +1 -1
  136. package/lib/cjs/resources/returns.d.ts +7 -0
  137. package/lib/cjs/resources/returns.js +1 -1
  138. package/lib/cjs/resources/shipments.d.ts +13 -0
  139. package/lib/cjs/resources/shipments.js +1 -1
  140. package/lib/cjs/resources/shipping_categories.d.ts +2 -0
  141. package/lib/cjs/resources/shipping_categories.js +1 -1
  142. package/lib/cjs/resources/shipping_methods.d.ts +5 -0
  143. package/lib/cjs/resources/shipping_methods.js +1 -1
  144. package/lib/cjs/resources/shipping_zones.d.ts +1 -0
  145. package/lib/cjs/resources/shipping_zones.js +1 -1
  146. package/lib/cjs/resources/sku_list_items.d.ts +2 -0
  147. package/lib/cjs/resources/sku_list_items.js +1 -1
  148. package/lib/cjs/resources/sku_list_promotion_rules.d.ts +2 -0
  149. package/lib/cjs/resources/sku_list_promotion_rules.js +1 -1
  150. package/lib/cjs/resources/sku_lists.d.ts +3 -0
  151. package/lib/cjs/resources/sku_lists.js +1 -1
  152. package/lib/cjs/resources/sku_options.d.ts +2 -0
  153. package/lib/cjs/resources/sku_options.js +1 -1
  154. package/lib/cjs/resources/skus.d.ts +6 -0
  155. package/lib/cjs/resources/skus.js +1 -1
  156. package/lib/cjs/resources/stock_items.d.ts +3 -0
  157. package/lib/cjs/resources/stock_items.js +1 -1
  158. package/lib/cjs/resources/stock_line_items.d.ts +3 -0
  159. package/lib/cjs/resources/stock_line_items.js +1 -1
  160. package/lib/cjs/resources/stock_locations.d.ts +6 -0
  161. package/lib/cjs/resources/stock_locations.js +1 -1
  162. package/lib/cjs/resources/stock_transfers.d.ts +5 -0
  163. package/lib/cjs/resources/stock_transfers.js +1 -1
  164. package/lib/cjs/resources/stripe_gateways.d.ts +2 -0
  165. package/lib/cjs/resources/stripe_gateways.js +1 -1
  166. package/lib/cjs/resources/stripe_payments.d.ts +2 -0
  167. package/lib/cjs/resources/stripe_payments.js +1 -1
  168. package/lib/cjs/resources/tax_calculators.d.ts +3 -0
  169. package/lib/cjs/resources/tax_calculators.js +1 -1
  170. package/lib/cjs/resources/tax_categories.d.ts +2 -0
  171. package/lib/cjs/resources/tax_categories.js +1 -1
  172. package/lib/cjs/resources/tax_rules.d.ts +1 -0
  173. package/lib/cjs/resources/tax_rules.js +1 -1
  174. package/lib/cjs/resources/taxjar_accounts.d.ts +3 -0
  175. package/lib/cjs/resources/taxjar_accounts.js +1 -1
  176. package/lib/cjs/resources/transactions.d.ts +1 -0
  177. package/lib/cjs/resources/transactions.js +1 -1
  178. package/lib/cjs/resources/voids.d.ts +2 -0
  179. package/lib/cjs/resources/voids.js +1 -1
  180. package/lib/cjs/resources/webhooks.d.ts +1 -0
  181. package/lib/cjs/resources/webhooks.js +1 -1
  182. package/lib/cjs/resources/wire_transfers.d.ts +1 -0
  183. package/lib/cjs/resources/wire_transfers.js +1 -1
  184. package/lib/esm/commercelayer.d.ts +2 -2
  185. package/lib/esm/resource.d.ts +2 -0
  186. package/lib/esm/resource.js +1 -1
  187. package/lib/esm/resources/addresses.d.ts +1 -0
  188. package/lib/esm/resources/addresses.js +1 -1
  189. package/lib/esm/resources/adyen_gateways.d.ts +2 -0
  190. package/lib/esm/resources/adyen_gateways.js +1 -1
  191. package/lib/esm/resources/adyen_payments.d.ts +2 -0
  192. package/lib/esm/resources/adyen_payments.js +1 -1
  193. package/lib/esm/resources/authorizations.d.ts +3 -0
  194. package/lib/esm/resources/authorizations.js +1 -1
  195. package/lib/esm/resources/avalara_accounts.d.ts +3 -0
  196. package/lib/esm/resources/avalara_accounts.js +1 -1
  197. package/lib/esm/resources/billing_info_validation_rules.d.ts +1 -0
  198. package/lib/esm/resources/billing_info_validation_rules.js +1 -1
  199. package/lib/esm/resources/bing_geocoders.d.ts +2 -0
  200. package/lib/esm/resources/bing_geocoders.js +1 -1
  201. package/lib/esm/resources/braintree_gateways.d.ts +2 -0
  202. package/lib/esm/resources/braintree_gateways.js +1 -1
  203. package/lib/esm/resources/braintree_payments.d.ts +2 -0
  204. package/lib/esm/resources/braintree_payments.js +1 -1
  205. package/lib/esm/resources/bundles.d.ts +4 -0
  206. package/lib/esm/resources/bundles.js +1 -1
  207. package/lib/esm/resources/captures.d.ts +3 -0
  208. package/lib/esm/resources/captures.js +1 -1
  209. package/lib/esm/resources/carrier_accounts.d.ts +2 -0
  210. package/lib/esm/resources/carrier_accounts.js +1 -1
  211. package/lib/esm/resources/checkout_com_gateways.d.ts +2 -0
  212. package/lib/esm/resources/checkout_com_gateways.js +1 -1
  213. package/lib/esm/resources/checkout_com_payments.d.ts +2 -0
  214. package/lib/esm/resources/checkout_com_payments.js +1 -1
  215. package/lib/esm/resources/coupon_codes_promotion_rules.d.ts +1 -0
  216. package/lib/esm/resources/coupon_codes_promotion_rules.js +1 -1
  217. package/lib/esm/resources/coupon_recipients.d.ts +2 -0
  218. package/lib/esm/resources/coupon_recipients.js +1 -1
  219. package/lib/esm/resources/coupons.d.ts +1 -0
  220. package/lib/esm/resources/coupons.js +1 -1
  221. package/lib/esm/resources/customer_addresses.d.ts +2 -0
  222. package/lib/esm/resources/customer_addresses.js +1 -1
  223. package/lib/esm/resources/customer_groups.d.ts +3 -0
  224. package/lib/esm/resources/customer_groups.js +1 -1
  225. package/lib/esm/resources/customer_password_resets.d.ts +1 -0
  226. package/lib/esm/resources/customer_password_resets.js +1 -1
  227. package/lib/esm/resources/customer_payment_sources.d.ts +1 -0
  228. package/lib/esm/resources/customer_payment_sources.js +1 -1
  229. package/lib/esm/resources/customer_subscriptions.d.ts +1 -0
  230. package/lib/esm/resources/customer_subscriptions.js +1 -1
  231. package/lib/esm/resources/customers.d.ts +8 -0
  232. package/lib/esm/resources/customers.js +1 -1
  233. package/lib/esm/resources/delivery_lead_times.d.ts +3 -0
  234. package/lib/esm/resources/delivery_lead_times.js +1 -1
  235. package/lib/esm/resources/event_callbacks.d.ts +1 -0
  236. package/lib/esm/resources/event_callbacks.js +1 -1
  237. package/lib/esm/resources/external_gateways.d.ts +2 -0
  238. package/lib/esm/resources/external_gateways.js +1 -1
  239. package/lib/esm/resources/external_payments.d.ts +3 -0
  240. package/lib/esm/resources/external_payments.js +1 -1
  241. package/lib/esm/resources/external_promotions.d.ts +5 -0
  242. package/lib/esm/resources/external_promotions.js +1 -1
  243. package/lib/esm/resources/external_tax_calculators.d.ts +3 -0
  244. package/lib/esm/resources/external_tax_calculators.js +1 -1
  245. package/lib/esm/resources/fixed_amount_promotions.d.ts +5 -0
  246. package/lib/esm/resources/fixed_amount_promotions.js +1 -1
  247. package/lib/esm/resources/fixed_price_promotions.d.ts +7 -0
  248. package/lib/esm/resources/fixed_price_promotions.js +1 -1
  249. package/lib/esm/resources/free_gift_promotions.d.ts +7 -0
  250. package/lib/esm/resources/free_gift_promotions.js +1 -1
  251. package/lib/esm/resources/free_shipping_promotions.d.ts +5 -0
  252. package/lib/esm/resources/free_shipping_promotions.js +1 -1
  253. package/lib/esm/resources/geocoders.d.ts +2 -0
  254. package/lib/esm/resources/geocoders.js +1 -1
  255. package/lib/esm/resources/gift_card_recipients.d.ts +2 -0
  256. package/lib/esm/resources/gift_card_recipients.js +1 -1
  257. package/lib/esm/resources/gift_cards.d.ts +3 -0
  258. package/lib/esm/resources/gift_cards.js +1 -1
  259. package/lib/esm/resources/google_geocoders.d.ts +2 -0
  260. package/lib/esm/resources/google_geocoders.js +1 -1
  261. package/lib/esm/resources/in_stock_subscriptions.d.ts +3 -0
  262. package/lib/esm/resources/in_stock_subscriptions.js +1 -1
  263. package/lib/esm/resources/inventory_models.d.ts +3 -0
  264. package/lib/esm/resources/inventory_models.js +1 -1
  265. package/lib/esm/resources/inventory_return_locations.d.ts +2 -0
  266. package/lib/esm/resources/inventory_return_locations.js +1 -1
  267. package/lib/esm/resources/inventory_stock_locations.d.ts +2 -0
  268. package/lib/esm/resources/inventory_stock_locations.js +1 -1
  269. package/lib/esm/resources/klarna_gateways.d.ts +2 -0
  270. package/lib/esm/resources/klarna_gateways.js +1 -1
  271. package/lib/esm/resources/klarna_payments.d.ts +2 -0
  272. package/lib/esm/resources/klarna_payments.js +1 -1
  273. package/lib/esm/resources/line_item_options.d.ts +2 -0
  274. package/lib/esm/resources/line_item_options.js +1 -1
  275. package/lib/esm/resources/line_items.d.ts +4 -0
  276. package/lib/esm/resources/line_items.js +1 -1
  277. package/lib/esm/resources/manual_gateways.d.ts +1 -0
  278. package/lib/esm/resources/manual_gateways.js +1 -1
  279. package/lib/esm/resources/manual_tax_calculators.d.ts +4 -0
  280. package/lib/esm/resources/manual_tax_calculators.js +1 -1
  281. package/lib/esm/resources/markets.d.ts +6 -0
  282. package/lib/esm/resources/markets.js +1 -1
  283. package/lib/esm/resources/merchants.d.ts +2 -0
  284. package/lib/esm/resources/merchants.js +1 -1
  285. package/lib/esm/resources/order_copies.d.ts +3 -0
  286. package/lib/esm/resources/order_copies.js +1 -1
  287. package/lib/esm/resources/order_subscriptions.d.ts +5 -0
  288. package/lib/esm/resources/order_subscriptions.js +1 -1
  289. package/lib/esm/resources/order_validation_rules.d.ts +1 -0
  290. package/lib/esm/resources/order_validation_rules.js +1 -1
  291. package/lib/esm/resources/orders.d.ts +16 -0
  292. package/lib/esm/resources/orders.js +1 -1
  293. package/lib/esm/resources/packages.d.ts +3 -0
  294. package/lib/esm/resources/packages.js +1 -1
  295. package/lib/esm/resources/parcel_line_items.d.ts +2 -0
  296. package/lib/esm/resources/parcel_line_items.js +1 -1
  297. package/lib/esm/resources/parcels.d.ts +4 -0
  298. package/lib/esm/resources/parcels.js +1 -1
  299. package/lib/esm/resources/payment_gateways.d.ts +1 -0
  300. package/lib/esm/resources/payment_gateways.js +1 -1
  301. package/lib/esm/resources/payment_methods.d.ts +3 -0
  302. package/lib/esm/resources/payment_methods.js +1 -1
  303. package/lib/esm/resources/paypal_gateways.d.ts +2 -0
  304. package/lib/esm/resources/paypal_gateways.js +1 -1
  305. package/lib/esm/resources/paypal_payments.d.ts +2 -0
  306. package/lib/esm/resources/paypal_payments.js +1 -1
  307. package/lib/esm/resources/percentage_discount_promotions.d.ts +7 -0
  308. package/lib/esm/resources/percentage_discount_promotions.js +1 -1
  309. package/lib/esm/resources/price_lists.d.ts +2 -0
  310. package/lib/esm/resources/price_lists.js +1 -1
  311. package/lib/esm/resources/prices.d.ts +3 -0
  312. package/lib/esm/resources/prices.js +1 -1
  313. package/lib/esm/resources/promotions.d.ts +5 -0
  314. package/lib/esm/resources/promotions.js +1 -1
  315. package/lib/esm/resources/refunds.d.ts +2 -0
  316. package/lib/esm/resources/refunds.js +1 -1
  317. package/lib/esm/resources/return_line_items.d.ts +2 -0
  318. package/lib/esm/resources/return_line_items.js +1 -1
  319. package/lib/esm/resources/returns.d.ts +7 -0
  320. package/lib/esm/resources/returns.js +1 -1
  321. package/lib/esm/resources/shipments.d.ts +13 -0
  322. package/lib/esm/resources/shipments.js +1 -1
  323. package/lib/esm/resources/shipping_categories.d.ts +2 -0
  324. package/lib/esm/resources/shipping_categories.js +1 -1
  325. package/lib/esm/resources/shipping_methods.d.ts +5 -0
  326. package/lib/esm/resources/shipping_methods.js +1 -1
  327. package/lib/esm/resources/shipping_zones.d.ts +1 -0
  328. package/lib/esm/resources/shipping_zones.js +1 -1
  329. package/lib/esm/resources/sku_list_items.d.ts +2 -0
  330. package/lib/esm/resources/sku_list_items.js +1 -1
  331. package/lib/esm/resources/sku_list_promotion_rules.d.ts +2 -0
  332. package/lib/esm/resources/sku_list_promotion_rules.js +1 -1
  333. package/lib/esm/resources/sku_lists.d.ts +3 -0
  334. package/lib/esm/resources/sku_lists.js +1 -1
  335. package/lib/esm/resources/sku_options.d.ts +2 -0
  336. package/lib/esm/resources/sku_options.js +1 -1
  337. package/lib/esm/resources/skus.d.ts +6 -0
  338. package/lib/esm/resources/skus.js +1 -1
  339. package/lib/esm/resources/stock_items.d.ts +3 -0
  340. package/lib/esm/resources/stock_items.js +1 -1
  341. package/lib/esm/resources/stock_line_items.d.ts +3 -0
  342. package/lib/esm/resources/stock_line_items.js +1 -1
  343. package/lib/esm/resources/stock_locations.d.ts +6 -0
  344. package/lib/esm/resources/stock_locations.js +1 -1
  345. package/lib/esm/resources/stock_transfers.d.ts +5 -0
  346. package/lib/esm/resources/stock_transfers.js +1 -1
  347. package/lib/esm/resources/stripe_gateways.d.ts +2 -0
  348. package/lib/esm/resources/stripe_gateways.js +1 -1
  349. package/lib/esm/resources/stripe_payments.d.ts +2 -0
  350. package/lib/esm/resources/stripe_payments.js +1 -1
  351. package/lib/esm/resources/tax_calculators.d.ts +3 -0
  352. package/lib/esm/resources/tax_calculators.js +1 -1
  353. package/lib/esm/resources/tax_categories.d.ts +2 -0
  354. package/lib/esm/resources/tax_categories.js +1 -1
  355. package/lib/esm/resources/tax_rules.d.ts +1 -0
  356. package/lib/esm/resources/tax_rules.js +1 -1
  357. package/lib/esm/resources/taxjar_accounts.d.ts +3 -0
  358. package/lib/esm/resources/taxjar_accounts.js +1 -1
  359. package/lib/esm/resources/transactions.d.ts +1 -0
  360. package/lib/esm/resources/transactions.js +1 -1
  361. package/lib/esm/resources/voids.d.ts +2 -0
  362. package/lib/esm/resources/voids.js +1 -1
  363. package/lib/esm/resources/webhooks.d.ts +1 -0
  364. package/lib/esm/resources/webhooks.js +1 -1
  365. package/lib/esm/resources/wire_transfers.d.ts +1 -0
  366. package/lib/esm/resources/wire_transfers.js +1 -1
  367. package/lib/tsconfig.esm.tsbuildinfo +1 -1
  368. package/lib/tsconfig.tsbuildinfo +1 -1
  369. package/package.json +1 -1
@@ -43,6 +43,12 @@ declare class StockLocations extends ApiResource {
43
43
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
44
44
  update(resource: StockLocationUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
45
45
  delete(id: string, options?: ResourcesConfig): Promise<void>;
46
+ address(stockLocationId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Address>;
47
+ inventory_stock_locations(stockLocationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<InventoryStockLocation>>;
48
+ inventory_return_locations(stockLocationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<InventoryReturnLocation>>;
49
+ stock_items(stockLocationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockItem>>;
50
+ stock_transfers(stockLocationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockTransfer>>;
51
+ attachments(stockLocationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
46
52
  isStockLocation(resource: any): resource is StockLocation;
47
53
  relationship(id: string | ResourceId | null): StockLocationRel;
48
54
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockLocations extends resource_1.ApiResource{async list(e,r){return this.resources.list({type:StockLocations.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StockLocations.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:StockLocations.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StockLocations.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:StockLocations.TYPE,id:e},r)}isStockLocation(e){return e.type&&e.type===StockLocations.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockLocations.TYPE}:{id:e.id,type:StockLocations.TYPE}}type(){return StockLocations.TYPE}}StockLocations.TYPE="stock_locations",exports.default=StockLocations;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockLocations extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockLocations.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StockLocations.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:StockLocations.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StockLocations.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:StockLocations.TYPE,id:e},t)}async address(e,t,s){return this.resources.fetch({type:"addresses"},`stock_locations/${e}/address`,t,s)}async inventory_stock_locations(e,t,s){return this.resources.fetch({type:"inventory_stock_locations"},`stock_locations/${e}/inventory_stock_locations`,t,s)}async inventory_return_locations(e,t,s){return this.resources.fetch({type:"inventory_return_locations"},`stock_locations/${e}/inventory_return_locations`,t,s)}async stock_items(e,t,s){return this.resources.fetch({type:"stock_items"},`stock_locations/${e}/stock_items`,t,s)}async stock_transfers(e,t,s){return this.resources.fetch({type:"stock_transfers"},`stock_locations/${e}/stock_transfers`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`stock_locations/${e}/attachments`,t,s)}isStockLocation(e){return e.type&&e.type===StockLocations.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockLocations.TYPE}:{id:e.id,type:StockLocations.TYPE}}type(){return StockLocations.TYPE}}StockLocations.TYPE="stock_locations",exports.default=StockLocations;
@@ -58,6 +58,11 @@ declare class StockTransfers extends ApiResource {
58
58
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
59
59
  update(resource: StockTransferUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
60
60
  delete(id: string, options?: ResourcesConfig): Promise<void>;
61
+ sku(stockTransferId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
62
+ origin_stock_location(stockTransferId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
63
+ destination_stock_location(stockTransferId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
64
+ shipment(stockTransferId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
65
+ line_item(stockTransferId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
61
66
  isStockTransfer(resource: any): resource is StockTransfer;
62
67
  relationship(id: string | ResourceId | null): StockTransferRel;
63
68
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockTransfers extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockTransfers.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StockTransfers.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:StockTransfers.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StockTransfers.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:StockTransfers.TYPE,id:e},t)}isStockTransfer(e){return e.type&&e.type===StockTransfers.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockTransfers.TYPE}:{id:e.id,type:StockTransfers.TYPE}}type(){return StockTransfers.TYPE}}StockTransfers.TYPE="stock_transfers",exports.default=StockTransfers;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockTransfers extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockTransfers.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StockTransfers.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:StockTransfers.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StockTransfers.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:StockTransfers.TYPE,id:e},t)}async sku(e,t,s){return this.resources.fetch({type:"skus"},`stock_transfers/${e}/sku`,t,s)}async origin_stock_location(e,t,s){return this.resources.fetch({type:"stock_locations"},`stock_transfers/${e}/origin_stock_location`,t,s)}async destination_stock_location(e,t,s){return this.resources.fetch({type:"stock_locations"},`stock_transfers/${e}/destination_stock_location`,t,s)}async shipment(e,t,s){return this.resources.fetch({type:"shipments"},`stock_transfers/${e}/shipment`,t,s)}async line_item(e,t,s){return this.resources.fetch({type:"line_items"},`stock_transfers/${e}/line_item`,t,s)}isStockTransfer(e){return e.type&&e.type===StockTransfers.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockTransfers.TYPE}:{id:e.id,type:StockTransfers.TYPE}}type(){return StockTransfers.TYPE}}StockTransfers.TYPE="stock_transfers",exports.default=StockTransfers;
@@ -28,6 +28,8 @@ declare class StripeGateways extends ApiResource {
28
28
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StripeGateway>;
29
29
  update(resource: StripeGatewayUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StripeGateway>;
30
30
  delete(id: string, options?: ResourcesConfig): Promise<void>;
31
+ payment_methods(stripeGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
32
+ stripe_payments(stripeGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StripePayment>>;
31
33
  isStripeGateway(resource: any): resource is StripeGateway;
32
34
  relationship(id: string | ResourceId | null): StripeGatewayRel;
33
35
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StripeGateways extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:StripeGateways.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:StripeGateways.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:StripeGateways.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:StripeGateways.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:StripeGateways.TYPE,id:e},s)}isStripeGateway(e){return e.type&&e.type===StripeGateways.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StripeGateways.TYPE}:{id:e.id,type:StripeGateways.TYPE}}type(){return StripeGateways.TYPE}}StripeGateways.TYPE="stripe_gateways",exports.default=StripeGateways;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StripeGateways extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StripeGateways.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StripeGateways.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:StripeGateways.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StripeGateways.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:StripeGateways.TYPE,id:e},t)}async payment_methods(e,t,s){return this.resources.fetch({type:"payment_methods"},`stripe_gateways/${e}/payment_methods`,t,s)}async stripe_payments(e,t,s){return this.resources.fetch({type:"stripe_payments"},`stripe_gateways/${e}/stripe_payments`,t,s)}isStripeGateway(e){return e.type&&e.type===StripeGateways.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StripeGateways.TYPE}:{id:e.id,type:StripeGateways.TYPE}}type(){return StripeGateways.TYPE}}StripeGateways.TYPE="stripe_gateways",exports.default=StripeGateways;
@@ -32,6 +32,8 @@ declare class StripePayments extends ApiResource {
32
32
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StripePayment>;
33
33
  update(resource: StripePaymentUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StripePayment>;
34
34
  delete(id: string, options?: ResourcesConfig): Promise<void>;
35
+ order(stripePaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
36
+ payment_gateway(stripePaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
35
37
  isStripePayment(resource: any): resource is StripePayment;
36
38
  relationship(id: string | ResourceId | null): StripePaymentRel;
37
39
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StripePayments extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:StripePayments.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:StripePayments.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:StripePayments.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:StripePayments.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:StripePayments.TYPE,id:e},s)}isStripePayment(e){return e.type&&e.type===StripePayments.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StripePayments.TYPE}:{id:e.id,type:StripePayments.TYPE}}type(){return StripePayments.TYPE}}StripePayments.TYPE="stripe_payments",exports.default=StripePayments;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StripePayments extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StripePayments.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:StripePayments.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:StripePayments.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:StripePayments.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:StripePayments.TYPE,id:e},t)}async order(e,t,r){return this.resources.fetch({type:"orders"},`stripe_payments/${e}/order`,t,r)}async payment_gateway(e,t,r){return this.resources.fetch({type:"payment_gateways"},`stripe_payments/${e}/payment_gateway`,t,r)}isStripePayment(e){return e.type&&e.type===StripePayments.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StripePayments.TYPE}:{id:e.id,type:StripePayments.TYPE}}type(){return StripePayments.TYPE}}StripePayments.TYPE="stripe_payments",exports.default=StripePayments;
@@ -16,6 +16,9 @@ declare class TaxCalculators extends ApiResource {
16
16
  static readonly TYPE: 'tax_calculators';
17
17
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<TaxCalculator>>;
18
18
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxCalculator>;
19
+ tax_categories(taxCalculatorId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<TaxCategory>>;
20
+ markets(taxCalculatorId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Market>>;
21
+ attachments(taxCalculatorId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
19
22
  isTaxCalculator(resource: any): resource is TaxCalculator;
20
23
  relationship(id: string | ResourceId | null): TaxCalculatorRel;
21
24
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxCalculators extends resource_1.ApiResource{async list(e,r){return this.resources.list({type:TaxCalculators.TYPE},e,r)}async retrieve(e,r,t){return this.resources.retrieve({type:TaxCalculators.TYPE,id:e},r,t)}isTaxCalculator(e){return e.type&&e.type===TaxCalculators.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxCalculators.TYPE}:{id:e.id,type:TaxCalculators.TYPE}}type(){return TaxCalculators.TYPE}}TaxCalculators.TYPE="tax_calculators",exports.default=TaxCalculators;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxCalculators extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxCalculators.TYPE},e,t)}async retrieve(e,t,r){return this.resources.retrieve({type:TaxCalculators.TYPE,id:e},t,r)}async tax_categories(e,t,r){return this.resources.fetch({type:"tax_categories"},`tax_calculators/${e}/tax_categories`,t,r)}async markets(e,t,r){return this.resources.fetch({type:"markets"},`tax_calculators/${e}/markets`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`tax_calculators/${e}/attachments`,t,r)}isTaxCalculator(e){return e.type&&e.type===TaxCalculators.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxCalculators.TYPE}:{id:e.id,type:TaxCalculators.TYPE}}type(){return TaxCalculators.TYPE}}TaxCalculators.TYPE="tax_calculators",exports.default=TaxCalculators;
@@ -49,6 +49,8 @@ declare class TaxCategories extends ApiResource {
49
49
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxCategory>;
50
50
  update(resource: TaxCategoryUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxCategory>;
51
51
  delete(id: string, options?: ResourcesConfig): Promise<void>;
52
+ sku(taxCategoryId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
53
+ attachments(taxCategoryId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
52
54
  isTaxCategory(resource: any): resource is TaxCategory;
53
55
  relationship(id: string | ResourceId | null): TaxCategoryRel;
54
56
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxCategories extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxCategories.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:TaxCategories.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:TaxCategories.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:TaxCategories.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:TaxCategories.TYPE,id:e},t)}isTaxCategory(e){return e.type&&e.type===TaxCategories.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxCategories.TYPE}:{id:e.id,type:TaxCategories.TYPE}}type(){return TaxCategories.TYPE}}TaxCategories.TYPE="tax_categories",exports.default=TaxCategories;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxCategories extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxCategories.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:TaxCategories.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:TaxCategories.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:TaxCategories.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:TaxCategories.TYPE,id:e},t)}async sku(e,t,s){return this.resources.fetch({type:"skus"},`tax_categories/${e}/sku`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`tax_categories/${e}/attachments`,t,s)}isTaxCategory(e){return e.type&&e.type===TaxCategories.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxCategories.TYPE}:{id:e.id,type:TaxCategories.TYPE}}type(){return TaxCategories.TYPE}}TaxCategories.TYPE="tax_categories",exports.default=TaxCategories;
@@ -60,6 +60,7 @@ declare class TaxRules extends ApiResource {
60
60
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxRule>;
61
61
  update(resource: TaxRuleUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxRule>;
62
62
  delete(id: string, options?: ResourcesConfig): Promise<void>;
63
+ manual_tax_calculator(taxRuleId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ManualTaxCalculator>;
63
64
  isTaxRule(resource: any): resource is TaxRule;
64
65
  relationship(id: string | ResourceId | null): TaxRuleRel;
65
66
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxRules extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxRules.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:TaxRules.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:TaxRules.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:TaxRules.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:TaxRules.TYPE,id:e},t)}isTaxRule(e){return e.type&&e.type===TaxRules.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxRules.TYPE}:{id:e.id,type:TaxRules.TYPE}}type(){return TaxRules.TYPE}}TaxRules.TYPE="tax_rules",exports.default=TaxRules;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxRules extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxRules.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:TaxRules.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:TaxRules.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:TaxRules.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:TaxRules.TYPE,id:e},t)}async manual_tax_calculator(e,t,r){return this.resources.fetch({type:"manual_tax_calculators"},`tax_rules/${e}/manual_tax_calculator`,t,r)}isTaxRule(e){return e.type&&e.type===TaxRules.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxRules.TYPE}:{id:e.id,type:TaxRules.TYPE}}type(){return TaxRules.TYPE}}TaxRules.TYPE="tax_rules",exports.default=TaxRules;
@@ -32,6 +32,9 @@ declare class TaxjarAccounts extends ApiResource {
32
32
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxjarAccount>;
33
33
  update(resource: TaxjarAccountUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<TaxjarAccount>;
34
34
  delete(id: string, options?: ResourcesConfig): Promise<void>;
35
+ tax_categories(taxjarAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<TaxCategory>>;
36
+ markets(taxjarAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Market>>;
37
+ attachments(taxjarAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
35
38
  isTaxjarAccount(resource: any): resource is TaxjarAccount;
36
39
  relationship(id: string | ResourceId | null): TaxjarAccountRel;
37
40
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxjarAccounts extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxjarAccounts.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:TaxjarAccounts.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:TaxjarAccounts.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:TaxjarAccounts.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:TaxjarAccounts.TYPE,id:e},t)}isTaxjarAccount(e){return e.type&&e.type===TaxjarAccounts.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxjarAccounts.TYPE}:{id:e.id,type:TaxjarAccounts.TYPE}}type(){return TaxjarAccounts.TYPE}}TaxjarAccounts.TYPE="taxjar_accounts",exports.default=TaxjarAccounts;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class TaxjarAccounts extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:TaxjarAccounts.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:TaxjarAccounts.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:TaxjarAccounts.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:TaxjarAccounts.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:TaxjarAccounts.TYPE,id:e},t)}async tax_categories(e,t,s){return this.resources.fetch({type:"tax_categories"},`taxjar_accounts/${e}/tax_categories`,t,s)}async markets(e,t,s){return this.resources.fetch({type:"markets"},`taxjar_accounts/${e}/markets`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`taxjar_accounts/${e}/attachments`,t,s)}isTaxjarAccount(e){return e.type&&e.type===TaxjarAccounts.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:TaxjarAccounts.TYPE}:{id:e.id,type:TaxjarAccounts.TYPE}}type(){return TaxjarAccounts.TYPE}}TaxjarAccounts.TYPE="taxjar_accounts",exports.default=TaxjarAccounts;
@@ -22,6 +22,7 @@ declare class Transactions extends ApiResource {
22
22
  static readonly TYPE: 'transactions';
23
23
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Transaction>>;
24
24
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Transaction>;
25
+ order(transactionId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
25
26
  isTransaction(resource: any): resource is Transaction;
26
27
  relationship(id: string | ResourceId | null): TransactionRel;
27
28
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Transactions extends resource_1.ApiResource{async list(e,r){return this.resources.list({type:Transactions.TYPE},e,r)}async retrieve(e,r,t){return this.resources.retrieve({type:Transactions.TYPE,id:e},r,t)}isTransaction(e){return e.type&&e.type===Transactions.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Transactions.TYPE}:{id:e.id,type:Transactions.TYPE}}type(){return Transactions.TYPE}}Transactions.TYPE="transactions",exports.default=Transactions;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Transactions extends resource_1.ApiResource{async list(e,r){return this.resources.list({type:Transactions.TYPE},e,r)}async retrieve(e,r,t){return this.resources.retrieve({type:Transactions.TYPE,id:e},r,t)}async order(e,r,t){return this.resources.fetch({type:"orders"},`transactions/${e}/order`,r,t)}isTransaction(e){return e.type&&e.type===Transactions.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Transactions.TYPE}:{id:e.id,type:Transactions.TYPE}}type(){return Transactions.TYPE}}Transactions.TYPE="transactions",exports.default=Transactions;
@@ -24,6 +24,8 @@ declare class Voids extends ApiResource {
24
24
  static readonly TYPE: 'voids';
25
25
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Void>>;
26
26
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Void>;
27
+ order(voidId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
28
+ reference_authorization(voidId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Authorization>;
27
29
  isVoid(resource: any): resource is Void;
28
30
  relationship(id: string | ResourceId | null): VoidRel;
29
31
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Voids extends resource_1.ApiResource{async list(e,r){return this.resources.list({type:Voids.TYPE},e,r)}async retrieve(e,r,t){return this.resources.retrieve({type:Voids.TYPE,id:e},r,t)}isVoid(e){return e.type&&e.type===Voids.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Voids.TYPE}:{id:e.id,type:Voids.TYPE}}type(){return Voids.TYPE}}Voids.TYPE="voids",exports.default=Voids;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Voids extends resource_1.ApiResource{async list(e,r){return this.resources.list({type:Voids.TYPE},e,r)}async retrieve(e,r,t){return this.resources.retrieve({type:Voids.TYPE,id:e},r,t)}async order(e,r,t){return this.resources.fetch({type:"orders"},`voids/${e}/order`,r,t)}async reference_authorization(e,r,t){return this.resources.fetch({type:"authorizations"},`voids/${e}/reference_authorization`,r,t)}isVoid(e){return e.type&&e.type===Voids.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Voids.TYPE}:{id:e.id,type:Voids.TYPE}}type(){return Voids.TYPE}}Voids.TYPE="voids",exports.default=Voids;
@@ -33,6 +33,7 @@ declare class Webhooks extends ApiResource {
33
33
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Webhook>;
34
34
  update(resource: WebhookUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Webhook>;
35
35
  delete(id: string, options?: ResourcesConfig): Promise<void>;
36
+ last_event_callbacks(webhookId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<EventCallback>>;
36
37
  isWebhook(resource: any): resource is Webhook;
37
38
  relationship(id: string | ResourceId | null): WebhookRel;
38
39
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Webhooks extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:Webhooks.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:Webhooks.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:Webhooks.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:Webhooks.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:Webhooks.TYPE,id:e},t)}isWebhook(e){return e.type&&e.type===Webhooks.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Webhooks.TYPE}:{id:e.id,type:Webhooks.TYPE}}type(){return Webhooks.TYPE}}Webhooks.TYPE="webhooks",exports.default=Webhooks;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Webhooks extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:Webhooks.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:Webhooks.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:Webhooks.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:Webhooks.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:Webhooks.TYPE,id:e},t)}async last_event_callbacks(e,t,r){return this.resources.fetch({type:"event_callbacks"},`webhooks/${e}/last_event_callbacks`,t,r)}isWebhook(e){return e.type&&e.type===Webhooks.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Webhooks.TYPE}:{id:e.id,type:Webhooks.TYPE}}type(){return Webhooks.TYPE}}Webhooks.TYPE="webhooks",exports.default=Webhooks;
@@ -23,6 +23,7 @@ declare class WireTransfers extends ApiResource {
23
23
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<WireTransfer>;
24
24
  update(resource: WireTransferUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<WireTransfer>;
25
25
  delete(id: string, options?: ResourcesConfig): Promise<void>;
26
+ order(wireTransferId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
26
27
  isWireTransfer(resource: any): resource is WireTransfer;
27
28
  relationship(id: string | ResourceId | null): WireTransferRel;
28
29
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class WireTransfers extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:WireTransfers.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:WireTransfers.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:WireTransfers.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:WireTransfers.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:WireTransfers.TYPE,id:e},t)}isWireTransfer(e){return e.type&&e.type===WireTransfers.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:WireTransfers.TYPE}:{id:e.id,type:WireTransfers.TYPE}}type(){return WireTransfers.TYPE}}WireTransfers.TYPE="wire_transfers",exports.default=WireTransfers;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class WireTransfers extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:WireTransfers.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:WireTransfers.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:WireTransfers.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:WireTransfers.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:WireTransfers.TYPE,id:e},t)}async order(e,t,r){return this.resources.fetch({type:"orders"},`wire_transfers/${e}/order`,t,r)}isWireTransfer(e){return e.type&&e.type===WireTransfers.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:WireTransfers.TYPE}:{id:e.id,type:WireTransfers.TYPE}}type(){return WireTransfers.TYPE}}WireTransfers.TYPE="wire_transfers",exports.default=WireTransfers;
@@ -1,10 +1,10 @@
1
1
  import * as api from './api';
2
2
  import { ApiError } from './error';
3
3
  import type { ErrorInterceptor, InterceptorType, RawResponseReader, RequestInterceptor, ResponseInterceptor } from './interceptor';
4
- import { ResourcesConfig, ResourcesInitConfig } from './resource';
4
+ import { ResourcesInitConfig } from './resource';
5
5
  declare type SdkConfig = {};
6
6
  declare type CommerceLayerInitConfig = SdkConfig & ResourcesInitConfig;
7
- declare type CommerceLayerConfig = SdkConfig & ResourcesConfig;
7
+ declare type CommerceLayerConfig = Partial<CommerceLayerInitConfig>;
8
8
  declare class CommerceLayerClient {
9
9
  #private;
10
10
  static get openApiSchemaVersion(): string;
@@ -2,6 +2,7 @@ import { ApiClientInitConfig } from './client';
2
2
  import { QueryParamsRetrieve, QueryParamsList } from './query';
3
3
  import { ResourceTypeLock } from './api';
4
4
  import { InterceptorManager } from './interceptor';
5
+ import { QueryParams } from '.';
5
6
  declare type ResourceNull = {
6
7
  id: null;
7
8
  } & ResourceType;
@@ -62,6 +63,7 @@ declare class ResourceAdapter {
62
63
  create<C extends ResourceCreate, R extends Resource>(resource: C & ResourceType, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<R>;
63
64
  update<U extends ResourceUpdate, R extends Resource>(resource: U & ResourceId, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<R>;
64
65
  delete(resource: ResourceId, options?: ResourcesConfig): Promise<void>;
66
+ fetch<R extends Resource>(resource: ResourceType, path: string, params?: QueryParams, options?: ResourcesConfig): Promise<R | ListResponse<R>>;
65
67
  }
66
68
  declare abstract class ApiResource {
67
69
  static readonly TYPE: ResourceTypeLock;
@@ -1 +1 @@
1
- var w=this&&this.__classPrivateFieldSet||function(i,t,r,e,a){if(e==="m")throw new TypeError("Private method is not writable");if(e==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?i!==t||!a:!t.has(i))throw new TypeError("Cannot write private member to an object whose class did not declare it");return e==="a"?a.call(i,r):a?a.value=r:t.set(i,r),r},n=this&&this.__classPrivateFieldGet||function(i,t,r,e){if(r==="a"&&!e)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?i!==t||!e:!t.has(i))throw new TypeError("Cannot read private member from an object whose class did not declare it");return r==="m"?e:r==="a"?e.call(i):e?e.value:t.get(i)},o,g;import O from"./client";import{denormalize as u,normalize as h}from"./jsonapi";import{generateQueryStringParams as d}from"./query";import m from"./config";import b from"./debug";const c=b();class y extends Array{constructor(t,r){super(...r||[]);this.meta=t}first(){return this.length?this[0]:void 0}last(){return this.length?this[this.length-1]:void 0}get(t){return this.length&&t>=0?this[t]:void 0}}class j{constructor(t){o.set(this,void 0),g.set(this,{}),w(this,o,O.create(t),"f"),this.localConfig(t)}get interceptors(){return n(this,o,"f").interceptors}localConfig(t){}config(t){c("config %o",t),this.localConfig(t),n(this,o,"f").config(t)}async singleton(t,r,e){c("singleton: %o, %O, %O",t,r||{},e||{});const a=d(r,t);(e==null?void 0:e.params)&&Object.assign(a,e==null?void 0:e.params);const s=await n(this,o,"f").request("get",`${t.type}`,void 0,Object.assign(Object.assign({},e),{params:a}));return u(s)}async retrieve(t,r,e){c("retrieve: %o, %O, %O",t,r||{},e||{});const a=d(r,t);(e==null?void 0:e.params)&&Object.assign(a,e==null?void 0:e.params);const s=await n(this,o,"f").request("get",`${t.type}/${t.id}`,void 0,Object.assign(Object.assign({},e),{params:a}));return u(s)}async list(t,r,e){var a,s;c("list: %o, %O, %O",t,r||{},e||{});const l=d(r,t);(e==null?void 0:e.params)&&Object.assign(l,e==null?void 0:e.params);const p=await n(this,o,"f").request("get",`${t.type}`,void 0,Object.assign(Object.assign({},e),{params:l})),f=u(p),v={pageCount:Number((a=p.meta)===null||a===void 0?void 0:a.page_count),recordCount:Number((s=p.meta)===null||s===void 0?void 0:s.record_count),currentPage:(r==null?void 0:r.pageNumber)||m.default.pageNumber,recordsPerPage:(r==null?void 0:r.pageSize)||m.default.pageSize};return new y(v,f)}async create(t,r,e){c("create: %o, %O, %O",t,r||{},e||{});const a=d(r,t);(e==null?void 0:e.params)&&Object.assign(a,e==null?void 0:e.params);const s=h(t),l=await n(this,o,"f").request("post",t.type,s,Object.assign(Object.assign({},e),{params:a}));return u(l)}async update(t,r,e){c("update: %o, %O, %O",t,r||{},e||{});const a=d(r,t);(e==null?void 0:e.params)&&Object.assign(a,e==null?void 0:e.params);const s=h(t),l=await n(this,o,"f").request("patch",`${t.type}/${t.id}`,s,Object.assign(Object.assign({},e),{params:a}));return u(l)}async delete(t,r){c("delete: %o, %O",t,r||{}),await n(this,o,"f").request("delete",`${t.type}/${t.id}`,void 0,r)}}o=new WeakMap,g=new WeakMap;class P{constructor(t){c("new resource instance: %s",this.type()),this.resources=t}}export default j;export{P as ApiResource};
1
+ var y=this&&this.__classPrivateFieldSet||function(s,e,a,t,r){if(t==="m")throw new TypeError("Private method is not writable");if(t==="a"&&!r)throw new TypeError("Private accessor was defined without a setter");if(typeof e=="function"?s!==e||!r:!e.has(s))throw new TypeError("Cannot write private member to an object whose class did not declare it");return t==="a"?r.call(s,a):r?r.value=a:e.set(s,a),a},c=this&&this.__classPrivateFieldGet||function(s,e,a,t){if(a==="a"&&!t)throw new TypeError("Private accessor was defined without a getter");if(typeof e=="function"?s!==e||!t:!e.has(s))throw new TypeError("Cannot read private member from an object whose class did not declare it");return a==="m"?t:a==="a"?t.call(s):t?t.value:e.get(s)},n,f;import j from"./client";import{denormalize as d,normalize as b}from"./jsonapi";import{generateQueryStringParams as p}from"./query";import v from"./config";import P from"./debug";const l=P();class O extends Array{constructor(e,a){super(...a||[]);this.meta=e}first(){return this.length?this[0]:void 0}last(){return this.length?this[this.length-1]:void 0}get(e){return this.length&&e>=0?this[e]:void 0}}class C{constructor(e){n.set(this,void 0),f.set(this,{}),y(this,n,j.create(e),"f"),this.localConfig(e)}get interceptors(){return c(this,n,"f").interceptors}localConfig(e){}config(e){l("config %o",e),this.localConfig(e),c(this,n,"f").config(e)}async singleton(e,a,t){l("singleton: %o, %O, %O",e,a||{},t||{});const r=p(a,e);(t==null?void 0:t.params)&&Object.assign(r,t==null?void 0:t.params);const i=await c(this,n,"f").request("get",`${e.type}`,void 0,Object.assign(Object.assign({},t),{params:r}));return d(i)}async retrieve(e,a,t){l("retrieve: %o, %O, %O",e,a||{},t||{});const r=p(a,e);(t==null?void 0:t.params)&&Object.assign(r,t==null?void 0:t.params);const i=await c(this,n,"f").request("get",`${e.type}/${e.id}`,void 0,Object.assign(Object.assign({},t),{params:r}));return d(i)}async list(e,a,t){var r,i;l("list: %o, %O, %O",e,a||{},t||{});const o=p(a,e);(t==null?void 0:t.params)&&Object.assign(o,t==null?void 0:t.params);const u=await c(this,n,"f").request("get",`${e.type}`,void 0,Object.assign(Object.assign({},t),{params:o})),g=d(u),m={pageCount:Number((r=u.meta)===null||r===void 0?void 0:r.page_count),recordCount:Number((i=u.meta)===null||i===void 0?void 0:i.record_count),currentPage:(a==null?void 0:a.pageNumber)||v.default.pageNumber,recordsPerPage:(a==null?void 0:a.pageSize)||v.default.pageSize};return new O(m,g)}async create(e,a,t){l("create: %o, %O, %O",e,a||{},t||{});const r=p(a,e);(t==null?void 0:t.params)&&Object.assign(r,t==null?void 0:t.params);const i=b(e),o=await c(this,n,"f").request("post",e.type,i,Object.assign(Object.assign({},t),{params:r}));return d(o)}async update(e,a,t){l("update: %o, %O, %O",e,a||{},t||{});const r=p(a,e);(t==null?void 0:t.params)&&Object.assign(r,t==null?void 0:t.params);const i=b(e),o=await c(this,n,"f").request("patch",`${e.type}/${e.id}`,i,Object.assign(Object.assign({},t),{params:r}));return d(o)}async delete(e,a){l("delete: %o, %O",e,a||{}),await c(this,n,"f").request("delete",`${e.type}/${e.id}`,void 0,a)}async fetch(e,a,t,r){var i,o;l("fetch: %o, %O, %O",a,t||{},r||{});const u=p(t,e);(r==null?void 0:r.params)&&Object.assign(u,r==null?void 0:r.params);const g=await c(this,n,"f").request("get",a,void 0,Object.assign(Object.assign({},r),{params:u})),m=d(g);if(Array.isArray(m)){const h=t,w={pageCount:Number((i=g.meta)===null||i===void 0?void 0:i.page_count),recordCount:Number((o=g.meta)===null||o===void 0?void 0:o.record_count),currentPage:(h==null?void 0:h.pageNumber)||v.default.pageNumber,recordsPerPage:(h==null?void 0:h.pageSize)||v.default.pageSize};return new O(w,m)}else return m}}n=new WeakMap,f=new WeakMap;class _{constructor(e){l("new resource instance: %s",this.type()),this.resources=e}}export default C;export{_ as ApiResource};
@@ -79,6 +79,7 @@ declare class Addresses extends ApiResource {
79
79
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Address>;
80
80
  update(resource: AddressUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Address>;
81
81
  delete(id: string, options?: ResourcesConfig): Promise<void>;
82
+ geocoder(addressId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Geocoder>;
82
83
  isAddress(resource: any): resource is Address;
83
84
  relationship(id: string | ResourceId | null): AddressRel;
84
85
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isAddress(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="addresses";export default t;
1
+ import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}async geocoder(e,r,s){return this.resources.fetch({type:"geocoders"},`addresses/${e}/geocoder`,r,s)}isAddress(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="addresses";export default t;
@@ -37,6 +37,8 @@ declare class AdyenGateways extends ApiResource {
37
37
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<AdyenGateway>;
38
38
  update(resource: AdyenGatewayUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<AdyenGateway>;
39
39
  delete(id: string, options?: ResourcesConfig): Promise<void>;
40
+ payment_methods(adyenGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
41
+ adyen_payments(adyenGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<AdyenPayment>>;
40
42
  isAdyenGateway(resource: any): resource is AdyenGateway;
41
43
  relationship(id: string | ResourceId | null): AdyenGatewayRel;
42
44
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isAdyenGateway(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="adyen_gateways";export default t;
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async payment_methods(e,t,r){return this.resources.fetch({type:"payment_methods"},`adyen_gateways/${e}/payment_methods`,t,r)}async adyen_payments(e,t,r){return this.resources.fetch({type:"adyen_payments"},`adyen_gateways/${e}/adyen_payments`,t,r)}isAdyenGateway(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="adyen_gateways";export default s;
@@ -34,6 +34,8 @@ declare class AdyenPayments extends ApiResource {
34
34
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<AdyenPayment>;
35
35
  update(resource: AdyenPaymentUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<AdyenPayment>;
36
36
  delete(id: string, options?: ResourcesConfig): Promise<void>;
37
+ order(adyenPaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
38
+ payment_gateway(adyenPaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
37
39
  isAdyenPayment(resource: any): resource is AdyenPayment;
38
40
  relationship(id: string | ResourceId | null): AdyenPaymentRel;
39
41
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isAdyenPayment(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="adyen_payments";export default t;
1
+ import{ApiResource as a}from"../resource";class r extends a{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:r.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:r.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async order(e,t,s){return this.resources.fetch({type:"orders"},`adyen_payments/${e}/order`,t,s)}async payment_gateway(e,t,s){return this.resources.fetch({type:"payment_gateways"},`adyen_payments/${e}/payment_gateway`,t,s)}isAdyenPayment(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="adyen_payments";export default r;
@@ -46,6 +46,9 @@ declare class Authorizations extends ApiResource {
46
46
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Authorization>>;
47
47
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Authorization>;
48
48
  update(resource: AuthorizationUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Authorization>;
49
+ order(authorizationId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
50
+ captures(authorizationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Capture>>;
51
+ voids(authorizationId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Void>>;
49
52
  isAuthorization(resource: any): resource is Authorization;
50
53
  relationship(id: string | ResourceId | null): AuthorizationRel;
51
54
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as r}from"../resource";class e extends r{async list(t,s){return this.resources.list({type:e.TYPE},t,s)}async retrieve(t,s,i){return this.resources.retrieve({type:e.TYPE,id:t},s,i)}async update(t,s,i){return this.resources.update(Object.assign(Object.assign({},t),{type:e.TYPE}),s,i)}isAuthorization(t){return t.type&&t.type===e.TYPE}relationship(t){return t===null||typeof t=="string"?{id:t,type:e.TYPE}:{id:t.id,type:e.TYPE}}type(){return e.TYPE}}e.TYPE="authorizations";export default e;
1
+ import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async order(e,r,s){return this.resources.fetch({type:"orders"},`authorizations/${e}/order`,r,s)}async captures(e,r,s){return this.resources.fetch({type:"captures"},`authorizations/${e}/captures`,r,s)}async voids(e,r,s){return this.resources.fetch({type:"voids"},`authorizations/${e}/voids`,r,s)}isAuthorization(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="authorizations";export default t;
@@ -41,6 +41,9 @@ declare class AvalaraAccounts extends ApiResource {
41
41
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<AvalaraAccount>;
42
42
  update(resource: AvalaraAccountUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<AvalaraAccount>;
43
43
  delete(id: string, options?: ResourcesConfig): Promise<void>;
44
+ tax_categories(avalaraAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<TaxCategory>>;
45
+ markets(avalaraAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Market>>;
46
+ attachments(avalaraAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
44
47
  isAvalaraAccount(resource: any): resource is AvalaraAccount;
45
48
  relationship(id: string | ResourceId | null): AvalaraAccountRel;
46
49
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as a}from"../resource";class t extends a{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isAvalaraAccount(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="avalara_accounts";export default t;
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async tax_categories(e,t,r){return this.resources.fetch({type:"tax_categories"},`avalara_accounts/${e}/tax_categories`,t,r)}async markets(e,t,r){return this.resources.fetch({type:"markets"},`avalara_accounts/${e}/markets`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`avalara_accounts/${e}/attachments`,t,r)}isAvalaraAccount(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="avalara_accounts";export default s;
@@ -23,6 +23,7 @@ declare class BillingInfoValidationRules extends ApiResource {
23
23
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BillingInfoValidationRule>;
24
24
  update(resource: BillingInfoValidationRuleUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BillingInfoValidationRule>;
25
25
  delete(id: string, options?: ResourcesConfig): Promise<void>;
26
+ market(billingInfoValidationRuleId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
26
27
  isBillingInfoValidationRule(resource: any): resource is BillingInfoValidationRule;
27
28
  relationship(id: string | ResourceId | null): BillingInfoValidationRuleRel;
28
29
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as s}from"../resource";class t extends s{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,i){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,i)}async retrieve(e,r,i){return this.resources.retrieve({type:t.TYPE,id:e},r,i)}async update(e,r,i){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,i)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isBillingInfoValidationRule(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="billing_info_validation_rules";export default t;
1
+ import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}async market(e,r,s){return this.resources.fetch({type:"markets"},`billing_info_validation_rules/${e}/market`,r,s)}isBillingInfoValidationRule(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="billing_info_validation_rules";export default t;
@@ -25,6 +25,8 @@ declare class BingGeocoders extends ApiResource {
25
25
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BingGeocoder>;
26
26
  update(resource: BingGeocoderUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BingGeocoder>;
27
27
  delete(id: string, options?: ResourcesConfig): Promise<void>;
28
+ addresses(bingGeocoderId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Address>>;
29
+ attachments(bingGeocoderId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
28
30
  isBingGeocoder(resource: any): resource is BingGeocoder;
29
31
  relationship(id: string | ResourceId | null): BingGeocoderRel;
30
32
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class s extends i{async list(e,r){return this.resources.list({type:s.TYPE},e,r)}async create(e,r,t){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),r,t)}async retrieve(e,r,t){return this.resources.retrieve({type:s.TYPE,id:e},r,t)}async update(e,r,t){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),r,t)}async delete(e,r){await this.resources.delete({type:s.TYPE,id:e},r)}isBingGeocoder(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="bing_geocoders";export default s;
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async addresses(e,t,r){return this.resources.fetch({type:"addresses"},`bing_geocoders/${e}/addresses`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`bing_geocoders/${e}/attachments`,t,r)}isBingGeocoder(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="bing_geocoders";export default s;
@@ -46,6 +46,8 @@ declare class BraintreeGateways extends ApiResource {
46
46
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BraintreeGateway>;
47
47
  update(resource: BraintreeGatewayUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BraintreeGateway>;
48
48
  delete(id: string, options?: ResourcesConfig): Promise<void>;
49
+ payment_methods(braintreeGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
50
+ braintree_payments(braintreeGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<BraintreePayment>>;
49
51
  isBraintreeGateway(resource: any): resource is BraintreeGateway;
50
52
  relationship(id: string | ResourceId | null): BraintreeGatewayRel;
51
53
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}isBraintreeGateway(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="braintree_gateways";export default t;
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async payment_methods(e,t,r){return this.resources.fetch({type:"payment_methods"},`braintree_gateways/${e}/payment_methods`,t,r)}async braintree_payments(e,t,r){return this.resources.fetch({type:"braintree_payments"},`braintree_gateways/${e}/braintree_payments`,t,r)}isBraintreeGateway(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="braintree_gateways";export default s;
@@ -37,6 +37,8 @@ declare class BraintreePayments extends ApiResource {
37
37
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BraintreePayment>;
38
38
  update(resource: BraintreePaymentUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<BraintreePayment>;
39
39
  delete(id: string, options?: ResourcesConfig): Promise<void>;
40
+ order(braintreePaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
41
+ payment_gateway(braintreePaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
40
42
  isBraintreePayment(resource: any): resource is BraintreePayment;
41
43
  relationship(id: string | ResourceId | null): BraintreePaymentRel;
42
44
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}isBraintreePayment(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="braintree_payments";export default t;
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async order(e,t,r){return this.resources.fetch({type:"orders"},`braintree_payments/${e}/order`,t,r)}async payment_gateway(e,t,r){return this.resources.fetch({type:"payment_gateways"},`braintree_payments/${e}/payment_gateway`,t,r)}isBraintreePayment(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="braintree_payments";export default s;
@@ -62,6 +62,10 @@ declare class Bundles extends ApiResource {
62
62
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Bundle>;
63
63
  update(resource: BundleUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Bundle>;
64
64
  delete(id: string, options?: ResourcesConfig): Promise<void>;
65
+ market(bundleId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
66
+ sku_list(bundleId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
67
+ skus(bundleId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
68
+ attachments(bundleId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
65
69
  isBundle(resource: any): resource is Bundle;
66
70
  relationship(id: string | ResourceId | null): BundleRel;
67
71
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isBundle(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="bundles";export default t;
1
+ import{ApiResource as n}from"../resource";class r extends n{async list(e,s){return this.resources.list({type:r.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:r.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:r.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:r.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:r.TYPE,id:e},s)}async market(e,s,t){return this.resources.fetch({type:"markets"},`bundles/${e}/market`,s,t)}async sku_list(e,s,t){return this.resources.fetch({type:"sku_lists"},`bundles/${e}/sku_list`,s,t)}async skus(e,s,t){return this.resources.fetch({type:"skus"},`bundles/${e}/skus`,s,t)}async attachments(e,s,t){return this.resources.fetch({type:"attachments"},`bundles/${e}/attachments`,s,t)}isBundle(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="bundles";export default r;
@@ -37,6 +37,9 @@ declare class Captures extends ApiResource {
37
37
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Capture>>;
38
38
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Capture>;
39
39
  update(resource: CaptureUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Capture>;
40
+ order(captureId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
41
+ reference_authorization(captureId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Authorization>;
42
+ refunds(captureId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Refund>>;
40
43
  isCapture(resource: any): resource is Capture;
41
44
  relationship(id: string | ResourceId | null): CaptureRel;
42
45
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}isCapture(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="captures";export default t;
1
+ import{ApiResource as u}from"../resource";class t extends u{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async order(e,r,s){return this.resources.fetch({type:"orders"},`captures/${e}/order`,r,s)}async reference_authorization(e,r,s){return this.resources.fetch({type:"authorizations"},`captures/${e}/reference_authorization`,r,s)}async refunds(e,r,s){return this.resources.fetch({type:"refunds"},`captures/${e}/refunds`,r,s)}isCapture(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="captures";export default t;
@@ -16,6 +16,8 @@ declare class CarrierAccounts extends ApiResource {
16
16
  static readonly TYPE: 'carrier_accounts';
17
17
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<CarrierAccount>>;
18
18
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CarrierAccount>;
19
+ market(carrierAccountId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
20
+ attachments(carrierAccountId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
19
21
  isCarrierAccount(resource: any): resource is CarrierAccount;
20
22
  relationship(id: string | ResourceId | null): CarrierAccountRel;
21
23
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as s}from"../resource";class t extends s{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async retrieve(e,r,i){return this.resources.retrieve({type:t.TYPE,id:e},r,i)}isCarrierAccount(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="carrier_accounts";export default t;
1
+ import{ApiResource as c}from"../resource";class e extends c{async list(t,r){return this.resources.list({type:e.TYPE},t,r)}async retrieve(t,r,s){return this.resources.retrieve({type:e.TYPE,id:t},r,s)}async market(t,r,s){return this.resources.fetch({type:"markets"},`carrier_accounts/${t}/market`,r,s)}async attachments(t,r,s){return this.resources.fetch({type:"attachments"},`carrier_accounts/${t}/attachments`,r,s)}isCarrierAccount(t){return t.type&&t.type===e.TYPE}relationship(t){return t===null||typeof t=="string"?{id:t,type:e.TYPE}:{id:t.id,type:e.TYPE}}type(){return e.TYPE}}e.TYPE="carrier_accounts";export default e;
@@ -35,6 +35,8 @@ declare class CheckoutComGateways extends ApiResource {
35
35
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CheckoutComGateway>;
36
36
  update(resource: CheckoutComGatewayUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CheckoutComGateway>;
37
37
  delete(id: string, options?: ResourcesConfig): Promise<void>;
38
+ payment_methods(checkoutComGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
39
+ checkout_com_payments(checkoutComGatewayId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<CheckoutComPayment>>;
38
40
  isCheckoutComGateway(resource: any): resource is CheckoutComGateway;
39
41
  relationship(id: string | ResourceId | null): CheckoutComGatewayRel;
40
42
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}isCheckoutComGateway(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="checkout_com_gateways";export default t;
1
+ import{ApiResource as c}from"../resource";class s extends c{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async payment_methods(e,t,r){return this.resources.fetch({type:"payment_methods"},`checkout_com_gateways/${e}/payment_methods`,t,r)}async checkout_com_payments(e,t,r){return this.resources.fetch({type:"checkout_com_payments"},`checkout_com_gateways/${e}/checkout_com_payments`,t,r)}isCheckoutComGateway(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="checkout_com_gateways";export default s;
@@ -40,6 +40,8 @@ declare class CheckoutComPayments extends ApiResource {
40
40
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CheckoutComPayment>;
41
41
  update(resource: CheckoutComPaymentUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CheckoutComPayment>;
42
42
  delete(id: string, options?: ResourcesConfig): Promise<void>;
43
+ order(checkoutComPaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
44
+ payment_gateway(checkoutComPaymentId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
43
45
  isCheckoutComPayment(resource: any): resource is CheckoutComPayment;
44
46
  relationship(id: string | ResourceId | null): CheckoutComPaymentRel;
45
47
  type(): string;
@@ -1 +1 @@
1
- import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}isCheckoutComPayment(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="checkout_com_payments";export default t;
1
+ import{ApiResource as a}from"../resource";class r extends a{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:r.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:r.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async order(e,t,s){return this.resources.fetch({type:"orders"},`checkout_com_payments/${e}/order`,t,s)}async payment_gateway(e,t,s){return this.resources.fetch({type:"payment_gateways"},`checkout_com_payments/${e}/payment_gateway`,t,s)}isCheckoutComPayment(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="checkout_com_payments";export default r;
@@ -50,6 +50,7 @@ declare class CouponCodesPromotionRules extends ApiResource {
50
50
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CouponCodesPromotionRule>;
51
51
  update(resource: CouponCodesPromotionRuleUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<CouponCodesPromotionRule>;
52
52
  delete(id: string, options?: ResourcesConfig): Promise<void>;
53
+ coupons(couponCodesPromotionRuleId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Coupon>>;
53
54
  isCouponCodesPromotionRule(resource: any): resource is CouponCodesPromotionRule;
54
55
  relationship(id: string | ResourceId | null): CouponCodesPromotionRuleRel;
55
56
  type(): string;