@commercelayer/sdk 4.6.1 → 4.7.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 (378) hide show
  1. package/README.md +4 -4
  2. package/lib/cjs/resources/addresses.d.ts +3 -3
  3. package/lib/cjs/resources/addresses.js +1 -1
  4. package/lib/cjs/resources/adjustments.d.ts +1 -1
  5. package/lib/cjs/resources/adyen_gateways.d.ts +5 -5
  6. package/lib/cjs/resources/adyen_gateways.js +1 -1
  7. package/lib/cjs/resources/adyen_payments.d.ts +5 -5
  8. package/lib/cjs/resources/adyen_payments.js +1 -1
  9. package/lib/cjs/resources/application.d.ts +1 -1
  10. package/lib/cjs/resources/attachments.d.ts +31 -31
  11. package/lib/cjs/resources/authorizations.d.ts +7 -7
  12. package/lib/cjs/resources/authorizations.js +1 -1
  13. package/lib/cjs/resources/avalara_accounts.d.ts +7 -7
  14. package/lib/cjs/resources/avalara_accounts.js +1 -1
  15. package/lib/cjs/resources/billing_info_validation_rules.d.ts +3 -3
  16. package/lib/cjs/resources/billing_info_validation_rules.js +1 -1
  17. package/lib/cjs/resources/bing_geocoders.d.ts +5 -5
  18. package/lib/cjs/resources/bing_geocoders.js +1 -1
  19. package/lib/cjs/resources/braintree_gateways.d.ts +5 -5
  20. package/lib/cjs/resources/braintree_gateways.js +1 -1
  21. package/lib/cjs/resources/braintree_payments.d.ts +5 -5
  22. package/lib/cjs/resources/braintree_payments.js +1 -1
  23. package/lib/cjs/resources/bundles.d.ts +9 -9
  24. package/lib/cjs/resources/bundles.js +1 -1
  25. package/lib/cjs/resources/captures.d.ts +7 -7
  26. package/lib/cjs/resources/captures.js +1 -1
  27. package/lib/cjs/resources/carrier_accounts.d.ts +5 -5
  28. package/lib/cjs/resources/carrier_accounts.js +1 -1
  29. package/lib/cjs/resources/checkout_com_gateways.d.ts +5 -5
  30. package/lib/cjs/resources/checkout_com_gateways.js +1 -1
  31. package/lib/cjs/resources/checkout_com_payments.d.ts +5 -5
  32. package/lib/cjs/resources/checkout_com_payments.js +1 -1
  33. package/lib/cjs/resources/coupon_codes_promotion_rules.d.ts +9 -9
  34. package/lib/cjs/resources/coupon_codes_promotion_rules.js +1 -1
  35. package/lib/cjs/resources/coupon_recipients.d.ts +5 -5
  36. package/lib/cjs/resources/coupon_recipients.js +1 -1
  37. package/lib/cjs/resources/coupons.d.ts +3 -3
  38. package/lib/cjs/resources/coupons.js +1 -1
  39. package/lib/cjs/resources/customer_addresses.d.ts +5 -5
  40. package/lib/cjs/resources/customer_addresses.js +1 -1
  41. package/lib/cjs/resources/customer_groups.d.ts +7 -7
  42. package/lib/cjs/resources/customer_groups.js +1 -1
  43. package/lib/cjs/resources/customer_password_resets.d.ts +3 -3
  44. package/lib/cjs/resources/customer_password_resets.js +1 -1
  45. package/lib/cjs/resources/customer_payment_sources.d.ts +11 -11
  46. package/lib/cjs/resources/customer_payment_sources.js +1 -1
  47. package/lib/cjs/resources/customer_subscriptions.d.ts +3 -3
  48. package/lib/cjs/resources/customer_subscriptions.js +1 -1
  49. package/lib/cjs/resources/customers.d.ts +17 -17
  50. package/lib/cjs/resources/customers.js +1 -1
  51. package/lib/cjs/resources/delivery_lead_times.d.ts +7 -7
  52. package/lib/cjs/resources/delivery_lead_times.js +1 -1
  53. package/lib/cjs/resources/event_callbacks.d.ts +3 -3
  54. package/lib/cjs/resources/event_callbacks.js +1 -1
  55. package/lib/cjs/resources/external_gateways.d.ts +5 -5
  56. package/lib/cjs/resources/external_gateways.js +1 -1
  57. package/lib/cjs/resources/external_payments.d.ts +7 -7
  58. package/lib/cjs/resources/external_payments.js +1 -1
  59. package/lib/cjs/resources/external_promotions.d.ts +12 -12
  60. package/lib/cjs/resources/external_promotions.js +1 -1
  61. package/lib/cjs/resources/external_tax_calculators.d.ts +7 -7
  62. package/lib/cjs/resources/external_tax_calculators.js +1 -1
  63. package/lib/cjs/resources/fixed_amount_promotions.d.ts +12 -12
  64. package/lib/cjs/resources/fixed_amount_promotions.js +1 -1
  65. package/lib/cjs/resources/fixed_price_promotions.d.ts +16 -16
  66. package/lib/cjs/resources/fixed_price_promotions.js +1 -1
  67. package/lib/cjs/resources/free_gift_promotions.d.ts +16 -16
  68. package/lib/cjs/resources/free_gift_promotions.js +1 -1
  69. package/lib/cjs/resources/free_shipping_promotions.d.ts +12 -12
  70. package/lib/cjs/resources/free_shipping_promotions.js +1 -1
  71. package/lib/cjs/resources/geocoders.d.ts +5 -5
  72. package/lib/cjs/resources/geocoders.js +1 -1
  73. package/lib/cjs/resources/gift_card_recipients.d.ts +5 -5
  74. package/lib/cjs/resources/gift_card_recipients.js +1 -1
  75. package/lib/cjs/resources/gift_cards.d.ts +7 -7
  76. package/lib/cjs/resources/gift_cards.js +1 -1
  77. package/lib/cjs/resources/google_geocoders.d.ts +5 -5
  78. package/lib/cjs/resources/google_geocoders.js +1 -1
  79. package/lib/cjs/resources/imports.d.ts +1 -1
  80. package/lib/cjs/resources/in_stock_subscriptions.d.ts +7 -7
  81. package/lib/cjs/resources/in_stock_subscriptions.js +1 -1
  82. package/lib/cjs/resources/inventory_models.d.ts +7 -7
  83. package/lib/cjs/resources/inventory_models.js +1 -1
  84. package/lib/cjs/resources/inventory_return_locations.d.ts +5 -5
  85. package/lib/cjs/resources/inventory_return_locations.js +1 -1
  86. package/lib/cjs/resources/inventory_stock_locations.d.ts +5 -5
  87. package/lib/cjs/resources/inventory_stock_locations.js +1 -1
  88. package/lib/cjs/resources/klarna_gateways.d.ts +5 -5
  89. package/lib/cjs/resources/klarna_gateways.js +1 -1
  90. package/lib/cjs/resources/klarna_payments.d.ts +5 -5
  91. package/lib/cjs/resources/klarna_payments.js +1 -1
  92. package/lib/cjs/resources/line_item_options.d.ts +5 -5
  93. package/lib/cjs/resources/line_item_options.js +1 -1
  94. package/lib/cjs/resources/line_items.d.ts +19 -19
  95. package/lib/cjs/resources/line_items.js +1 -1
  96. package/lib/cjs/resources/manual_gateways.d.ts +3 -3
  97. package/lib/cjs/resources/manual_gateways.js +1 -1
  98. package/lib/cjs/resources/manual_tax_calculators.d.ts +9 -9
  99. package/lib/cjs/resources/manual_tax_calculators.js +1 -1
  100. package/lib/cjs/resources/markets.d.ts +13 -13
  101. package/lib/cjs/resources/markets.js +1 -1
  102. package/lib/cjs/resources/merchants.d.ts +5 -5
  103. package/lib/cjs/resources/merchants.js +1 -1
  104. package/lib/cjs/resources/order_amount_promotion_rules.d.ts +7 -7
  105. package/lib/cjs/resources/order_copies.d.ts +6 -6
  106. package/lib/cjs/resources/order_copies.js +1 -1
  107. package/lib/cjs/resources/order_subscriptions.d.ts +10 -10
  108. package/lib/cjs/resources/order_subscriptions.js +1 -1
  109. package/lib/cjs/resources/order_validation_rules.d.ts +3 -3
  110. package/lib/cjs/resources/order_validation_rules.js +1 -1
  111. package/lib/cjs/resources/orders.d.ts +39 -39
  112. package/lib/cjs/resources/orders.js +1 -1
  113. package/lib/cjs/resources/organization.d.ts +1 -1
  114. package/lib/cjs/resources/packages.d.ts +7 -7
  115. package/lib/cjs/resources/packages.js +1 -1
  116. package/lib/cjs/resources/parcel_line_items.d.ts +5 -5
  117. package/lib/cjs/resources/parcel_line_items.js +1 -1
  118. package/lib/cjs/resources/parcels.d.ts +9 -9
  119. package/lib/cjs/resources/parcels.js +1 -1
  120. package/lib/cjs/resources/payment_gateways.d.ts +3 -3
  121. package/lib/cjs/resources/payment_gateways.js +1 -1
  122. package/lib/cjs/resources/payment_methods.d.ts +7 -7
  123. package/lib/cjs/resources/payment_methods.js +1 -1
  124. package/lib/cjs/resources/paypal_gateways.d.ts +5 -5
  125. package/lib/cjs/resources/paypal_gateways.js +1 -1
  126. package/lib/cjs/resources/paypal_payments.d.ts +5 -5
  127. package/lib/cjs/resources/paypal_payments.js +1 -1
  128. package/lib/cjs/resources/percentage_discount_promotions.d.ts +16 -16
  129. package/lib/cjs/resources/percentage_discount_promotions.js +1 -1
  130. package/lib/cjs/resources/price_lists.d.ts +5 -5
  131. package/lib/cjs/resources/price_lists.js +1 -1
  132. package/lib/cjs/resources/prices.d.ts +7 -7
  133. package/lib/cjs/resources/prices.js +1 -1
  134. package/lib/cjs/resources/promotion_rules.d.ts +7 -7
  135. package/lib/cjs/resources/promotions.d.ts +12 -12
  136. package/lib/cjs/resources/promotions.js +1 -1
  137. package/lib/cjs/resources/refunds.d.ts +5 -5
  138. package/lib/cjs/resources/refunds.js +1 -1
  139. package/lib/cjs/resources/return_line_items.d.ts +5 -5
  140. package/lib/cjs/resources/return_line_items.js +1 -1
  141. package/lib/cjs/resources/returns.d.ts +14 -14
  142. package/lib/cjs/resources/returns.js +1 -1
  143. package/lib/cjs/resources/shipments.d.ts +25 -25
  144. package/lib/cjs/resources/shipments.js +1 -1
  145. package/lib/cjs/resources/shipping_categories.d.ts +5 -5
  146. package/lib/cjs/resources/shipping_categories.js +1 -1
  147. package/lib/cjs/resources/shipping_methods.d.ts +11 -11
  148. package/lib/cjs/resources/shipping_methods.js +1 -1
  149. package/lib/cjs/resources/shipping_zones.d.ts +3 -3
  150. package/lib/cjs/resources/shipping_zones.js +1 -1
  151. package/lib/cjs/resources/sku_list_items.d.ts +5 -5
  152. package/lib/cjs/resources/sku_list_items.js +1 -1
  153. package/lib/cjs/resources/sku_list_promotion_rules.d.ts +11 -11
  154. package/lib/cjs/resources/sku_list_promotion_rules.js +1 -1
  155. package/lib/cjs/resources/sku_lists.d.ts +7 -7
  156. package/lib/cjs/resources/sku_lists.js +1 -1
  157. package/lib/cjs/resources/sku_options.d.ts +5 -5
  158. package/lib/cjs/resources/sku_options.js +1 -1
  159. package/lib/cjs/resources/skus.d.ts +13 -13
  160. package/lib/cjs/resources/skus.js +1 -1
  161. package/lib/cjs/resources/stock_items.d.ts +7 -7
  162. package/lib/cjs/resources/stock_items.js +1 -1
  163. package/lib/cjs/resources/stock_line_items.d.ts +7 -7
  164. package/lib/cjs/resources/stock_line_items.js +1 -1
  165. package/lib/cjs/resources/stock_locations.d.ts +13 -13
  166. package/lib/cjs/resources/stock_locations.js +1 -1
  167. package/lib/cjs/resources/stock_transfers.d.ts +10 -10
  168. package/lib/cjs/resources/stock_transfers.js +1 -1
  169. package/lib/cjs/resources/stripe_gateways.d.ts +5 -5
  170. package/lib/cjs/resources/stripe_gateways.js +1 -1
  171. package/lib/cjs/resources/stripe_payments.d.ts +5 -5
  172. package/lib/cjs/resources/stripe_payments.js +1 -1
  173. package/lib/cjs/resources/tax_calculators.d.ts +7 -7
  174. package/lib/cjs/resources/tax_calculators.js +1 -1
  175. package/lib/cjs/resources/tax_categories.d.ts +9 -9
  176. package/lib/cjs/resources/tax_categories.js +1 -1
  177. package/lib/cjs/resources/tax_rules.d.ts +3 -3
  178. package/lib/cjs/resources/tax_rules.js +1 -1
  179. package/lib/cjs/resources/taxjar_accounts.d.ts +7 -7
  180. package/lib/cjs/resources/taxjar_accounts.js +1 -1
  181. package/lib/cjs/resources/transactions.d.ts +3 -3
  182. package/lib/cjs/resources/transactions.js +1 -1
  183. package/lib/cjs/resources/voids.d.ts +5 -5
  184. package/lib/cjs/resources/voids.js +1 -1
  185. package/lib/cjs/resources/webhooks.d.ts +3 -3
  186. package/lib/cjs/resources/webhooks.js +1 -1
  187. package/lib/cjs/resources/wire_transfers.d.ts +3 -3
  188. package/lib/cjs/resources/wire_transfers.js +1 -1
  189. package/lib/esm/resources/addresses.d.ts +3 -3
  190. package/lib/esm/resources/addresses.js +1 -1
  191. package/lib/esm/resources/adjustments.d.ts +1 -1
  192. package/lib/esm/resources/adyen_gateways.d.ts +5 -5
  193. package/lib/esm/resources/adyen_gateways.js +1 -1
  194. package/lib/esm/resources/adyen_payments.d.ts +5 -5
  195. package/lib/esm/resources/adyen_payments.js +1 -1
  196. package/lib/esm/resources/application.d.ts +1 -1
  197. package/lib/esm/resources/attachments.d.ts +31 -31
  198. package/lib/esm/resources/authorizations.d.ts +7 -7
  199. package/lib/esm/resources/authorizations.js +1 -1
  200. package/lib/esm/resources/avalara_accounts.d.ts +7 -7
  201. package/lib/esm/resources/avalara_accounts.js +1 -1
  202. package/lib/esm/resources/billing_info_validation_rules.d.ts +3 -3
  203. package/lib/esm/resources/billing_info_validation_rules.js +1 -1
  204. package/lib/esm/resources/bing_geocoders.d.ts +5 -5
  205. package/lib/esm/resources/bing_geocoders.js +1 -1
  206. package/lib/esm/resources/braintree_gateways.d.ts +5 -5
  207. package/lib/esm/resources/braintree_gateways.js +1 -1
  208. package/lib/esm/resources/braintree_payments.d.ts +5 -5
  209. package/lib/esm/resources/braintree_payments.js +1 -1
  210. package/lib/esm/resources/bundles.d.ts +9 -9
  211. package/lib/esm/resources/bundles.js +1 -1
  212. package/lib/esm/resources/captures.d.ts +7 -7
  213. package/lib/esm/resources/captures.js +1 -1
  214. package/lib/esm/resources/carrier_accounts.d.ts +5 -5
  215. package/lib/esm/resources/carrier_accounts.js +1 -1
  216. package/lib/esm/resources/checkout_com_gateways.d.ts +5 -5
  217. package/lib/esm/resources/checkout_com_gateways.js +1 -1
  218. package/lib/esm/resources/checkout_com_payments.d.ts +5 -5
  219. package/lib/esm/resources/checkout_com_payments.js +1 -1
  220. package/lib/esm/resources/coupon_codes_promotion_rules.d.ts +9 -9
  221. package/lib/esm/resources/coupon_codes_promotion_rules.js +1 -1
  222. package/lib/esm/resources/coupon_recipients.d.ts +5 -5
  223. package/lib/esm/resources/coupon_recipients.js +1 -1
  224. package/lib/esm/resources/coupons.d.ts +3 -3
  225. package/lib/esm/resources/coupons.js +1 -1
  226. package/lib/esm/resources/customer_addresses.d.ts +5 -5
  227. package/lib/esm/resources/customer_addresses.js +1 -1
  228. package/lib/esm/resources/customer_groups.d.ts +7 -7
  229. package/lib/esm/resources/customer_groups.js +1 -1
  230. package/lib/esm/resources/customer_password_resets.d.ts +3 -3
  231. package/lib/esm/resources/customer_password_resets.js +1 -1
  232. package/lib/esm/resources/customer_payment_sources.d.ts +11 -11
  233. package/lib/esm/resources/customer_payment_sources.js +1 -1
  234. package/lib/esm/resources/customer_subscriptions.d.ts +3 -3
  235. package/lib/esm/resources/customer_subscriptions.js +1 -1
  236. package/lib/esm/resources/customers.d.ts +17 -17
  237. package/lib/esm/resources/customers.js +1 -1
  238. package/lib/esm/resources/delivery_lead_times.d.ts +7 -7
  239. package/lib/esm/resources/delivery_lead_times.js +1 -1
  240. package/lib/esm/resources/event_callbacks.d.ts +3 -3
  241. package/lib/esm/resources/event_callbacks.js +1 -1
  242. package/lib/esm/resources/external_gateways.d.ts +5 -5
  243. package/lib/esm/resources/external_gateways.js +1 -1
  244. package/lib/esm/resources/external_payments.d.ts +7 -7
  245. package/lib/esm/resources/external_payments.js +1 -1
  246. package/lib/esm/resources/external_promotions.d.ts +12 -12
  247. package/lib/esm/resources/external_promotions.js +1 -1
  248. package/lib/esm/resources/external_tax_calculators.d.ts +7 -7
  249. package/lib/esm/resources/external_tax_calculators.js +1 -1
  250. package/lib/esm/resources/fixed_amount_promotions.d.ts +12 -12
  251. package/lib/esm/resources/fixed_amount_promotions.js +1 -1
  252. package/lib/esm/resources/fixed_price_promotions.d.ts +16 -16
  253. package/lib/esm/resources/fixed_price_promotions.js +1 -1
  254. package/lib/esm/resources/free_gift_promotions.d.ts +16 -16
  255. package/lib/esm/resources/free_gift_promotions.js +1 -1
  256. package/lib/esm/resources/free_shipping_promotions.d.ts +12 -12
  257. package/lib/esm/resources/free_shipping_promotions.js +1 -1
  258. package/lib/esm/resources/geocoders.d.ts +5 -5
  259. package/lib/esm/resources/geocoders.js +1 -1
  260. package/lib/esm/resources/gift_card_recipients.d.ts +5 -5
  261. package/lib/esm/resources/gift_card_recipients.js +1 -1
  262. package/lib/esm/resources/gift_cards.d.ts +7 -7
  263. package/lib/esm/resources/gift_cards.js +1 -1
  264. package/lib/esm/resources/google_geocoders.d.ts +5 -5
  265. package/lib/esm/resources/google_geocoders.js +1 -1
  266. package/lib/esm/resources/imports.d.ts +1 -1
  267. package/lib/esm/resources/in_stock_subscriptions.d.ts +7 -7
  268. package/lib/esm/resources/in_stock_subscriptions.js +1 -1
  269. package/lib/esm/resources/inventory_models.d.ts +7 -7
  270. package/lib/esm/resources/inventory_models.js +1 -1
  271. package/lib/esm/resources/inventory_return_locations.d.ts +5 -5
  272. package/lib/esm/resources/inventory_return_locations.js +1 -1
  273. package/lib/esm/resources/inventory_stock_locations.d.ts +5 -5
  274. package/lib/esm/resources/inventory_stock_locations.js +1 -1
  275. package/lib/esm/resources/klarna_gateways.d.ts +5 -5
  276. package/lib/esm/resources/klarna_gateways.js +1 -1
  277. package/lib/esm/resources/klarna_payments.d.ts +5 -5
  278. package/lib/esm/resources/klarna_payments.js +1 -1
  279. package/lib/esm/resources/line_item_options.d.ts +5 -5
  280. package/lib/esm/resources/line_item_options.js +1 -1
  281. package/lib/esm/resources/line_items.d.ts +19 -19
  282. package/lib/esm/resources/line_items.js +1 -1
  283. package/lib/esm/resources/manual_gateways.d.ts +3 -3
  284. package/lib/esm/resources/manual_gateways.js +1 -1
  285. package/lib/esm/resources/manual_tax_calculators.d.ts +9 -9
  286. package/lib/esm/resources/manual_tax_calculators.js +1 -1
  287. package/lib/esm/resources/markets.d.ts +13 -13
  288. package/lib/esm/resources/markets.js +1 -1
  289. package/lib/esm/resources/merchants.d.ts +5 -5
  290. package/lib/esm/resources/merchants.js +1 -1
  291. package/lib/esm/resources/order_amount_promotion_rules.d.ts +7 -7
  292. package/lib/esm/resources/order_copies.d.ts +6 -6
  293. package/lib/esm/resources/order_copies.js +1 -1
  294. package/lib/esm/resources/order_subscriptions.d.ts +10 -10
  295. package/lib/esm/resources/order_subscriptions.js +1 -1
  296. package/lib/esm/resources/order_validation_rules.d.ts +3 -3
  297. package/lib/esm/resources/order_validation_rules.js +1 -1
  298. package/lib/esm/resources/orders.d.ts +39 -39
  299. package/lib/esm/resources/orders.js +1 -1
  300. package/lib/esm/resources/organization.d.ts +1 -1
  301. package/lib/esm/resources/packages.d.ts +7 -7
  302. package/lib/esm/resources/packages.js +1 -1
  303. package/lib/esm/resources/parcel_line_items.d.ts +5 -5
  304. package/lib/esm/resources/parcel_line_items.js +1 -1
  305. package/lib/esm/resources/parcels.d.ts +9 -9
  306. package/lib/esm/resources/parcels.js +1 -1
  307. package/lib/esm/resources/payment_gateways.d.ts +3 -3
  308. package/lib/esm/resources/payment_gateways.js +1 -1
  309. package/lib/esm/resources/payment_methods.d.ts +7 -7
  310. package/lib/esm/resources/payment_methods.js +1 -1
  311. package/lib/esm/resources/paypal_gateways.d.ts +5 -5
  312. package/lib/esm/resources/paypal_gateways.js +1 -1
  313. package/lib/esm/resources/paypal_payments.d.ts +5 -5
  314. package/lib/esm/resources/paypal_payments.js +1 -1
  315. package/lib/esm/resources/percentage_discount_promotions.d.ts +16 -16
  316. package/lib/esm/resources/percentage_discount_promotions.js +1 -1
  317. package/lib/esm/resources/price_lists.d.ts +5 -5
  318. package/lib/esm/resources/price_lists.js +1 -1
  319. package/lib/esm/resources/prices.d.ts +7 -7
  320. package/lib/esm/resources/prices.js +1 -1
  321. package/lib/esm/resources/promotion_rules.d.ts +7 -7
  322. package/lib/esm/resources/promotions.d.ts +12 -12
  323. package/lib/esm/resources/promotions.js +1 -1
  324. package/lib/esm/resources/refunds.d.ts +5 -5
  325. package/lib/esm/resources/refunds.js +1 -1
  326. package/lib/esm/resources/return_line_items.d.ts +5 -5
  327. package/lib/esm/resources/return_line_items.js +1 -1
  328. package/lib/esm/resources/returns.d.ts +14 -14
  329. package/lib/esm/resources/returns.js +1 -1
  330. package/lib/esm/resources/shipments.d.ts +25 -25
  331. package/lib/esm/resources/shipments.js +1 -1
  332. package/lib/esm/resources/shipping_categories.d.ts +5 -5
  333. package/lib/esm/resources/shipping_categories.js +1 -1
  334. package/lib/esm/resources/shipping_methods.d.ts +11 -11
  335. package/lib/esm/resources/shipping_methods.js +1 -1
  336. package/lib/esm/resources/shipping_zones.d.ts +3 -3
  337. package/lib/esm/resources/shipping_zones.js +1 -1
  338. package/lib/esm/resources/sku_list_items.d.ts +5 -5
  339. package/lib/esm/resources/sku_list_items.js +1 -1
  340. package/lib/esm/resources/sku_list_promotion_rules.d.ts +11 -11
  341. package/lib/esm/resources/sku_list_promotion_rules.js +1 -1
  342. package/lib/esm/resources/sku_lists.d.ts +7 -7
  343. package/lib/esm/resources/sku_lists.js +1 -1
  344. package/lib/esm/resources/sku_options.d.ts +5 -5
  345. package/lib/esm/resources/sku_options.js +1 -1
  346. package/lib/esm/resources/skus.d.ts +13 -13
  347. package/lib/esm/resources/skus.js +1 -1
  348. package/lib/esm/resources/stock_items.d.ts +7 -7
  349. package/lib/esm/resources/stock_items.js +1 -1
  350. package/lib/esm/resources/stock_line_items.d.ts +7 -7
  351. package/lib/esm/resources/stock_line_items.js +1 -1
  352. package/lib/esm/resources/stock_locations.d.ts +13 -13
  353. package/lib/esm/resources/stock_locations.js +1 -1
  354. package/lib/esm/resources/stock_transfers.d.ts +10 -10
  355. package/lib/esm/resources/stock_transfers.js +1 -1
  356. package/lib/esm/resources/stripe_gateways.d.ts +5 -5
  357. package/lib/esm/resources/stripe_gateways.js +1 -1
  358. package/lib/esm/resources/stripe_payments.d.ts +5 -5
  359. package/lib/esm/resources/stripe_payments.js +1 -1
  360. package/lib/esm/resources/tax_calculators.d.ts +7 -7
  361. package/lib/esm/resources/tax_calculators.js +1 -1
  362. package/lib/esm/resources/tax_categories.d.ts +9 -9
  363. package/lib/esm/resources/tax_categories.js +1 -1
  364. package/lib/esm/resources/tax_rules.d.ts +3 -3
  365. package/lib/esm/resources/tax_rules.js +1 -1
  366. package/lib/esm/resources/taxjar_accounts.d.ts +7 -7
  367. package/lib/esm/resources/taxjar_accounts.js +1 -1
  368. package/lib/esm/resources/transactions.d.ts +3 -3
  369. package/lib/esm/resources/transactions.js +1 -1
  370. package/lib/esm/resources/voids.d.ts +5 -5
  371. package/lib/esm/resources/voids.js +1 -1
  372. package/lib/esm/resources/webhooks.d.ts +3 -3
  373. package/lib/esm/resources/webhooks.js +1 -1
  374. package/lib/esm/resources/wire_transfers.d.ts +3 -3
  375. package/lib/esm/resources/wire_transfers.js +1 -1
  376. package/lib/tsconfig.esm.tsbuildinfo +1 -1
  377. package/lib/tsconfig.tsbuildinfo +1 -1
  378. package/package.json +1 -1
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class ShippingCategories extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:ShippingCategories.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:ShippingCategories.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:ShippingCategories.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:ShippingCategories.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:ShippingCategories.TYPE,id:e},t)}async skus(e,t,s){return this.resources.fetch({type:"skus"},`shipping_categories/${e}/skus`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`shipping_categories/${e}/attachments`,t,s)}isShippingCategory(e){return e.type&&e.type===ShippingCategories.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:ShippingCategories.TYPE}:{id:e.id,type:ShippingCategories.TYPE}}type(){return ShippingCategories.TYPE}}ShippingCategories.TYPE="shipping_categories",exports.default=ShippingCategories;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class ShippingCategories extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:ShippingCategories.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:ShippingCategories.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:ShippingCategories.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:ShippingCategories.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:ShippingCategories.TYPE,id:e},t)}async skus(e,t,s){const r=e.id||e;return this.resources.fetch({type:"skus"},`shipping_categories/${r}/skus`,t,s)}async attachments(e,t,s){const r=e.id||e;return this.resources.fetch({type:"attachments"},`shipping_categories/${r}/attachments`,t,s)}isShippingCategory(e){return e.type&&e.type===ShippingCategories.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:ShippingCategories.TYPE}:{id:e.id,type:ShippingCategories.TYPE}}type(){return ShippingCategories.TYPE}}ShippingCategories.TYPE="shipping_categories",exports.default=ShippingCategories;
@@ -1,10 +1,10 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Market } from './markets';
4
- import { ShippingZone } from './shipping_zones';
5
- import { ShippingCategory } from './shipping_categories';
6
- import { DeliveryLeadTime } from './delivery_lead_times';
7
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Market } from './markets';
4
+ import type { ShippingZone } from './shipping_zones';
5
+ import type { ShippingCategory } from './shipping_categories';
6
+ import type { DeliveryLeadTime } from './delivery_lead_times';
7
+ import type { Attachment } from './attachments';
8
8
  declare type ShippingMethodRel = ResourceRel & {
9
9
  type: typeof ShippingMethods.TYPE;
10
10
  };
@@ -61,11 +61,11 @@ declare class ShippingMethods extends ApiResource {
61
61
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingMethod>;
62
62
  update(resource: ShippingMethodUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingMethod>;
63
63
  delete(id: string, options?: ResourcesConfig): Promise<void>;
64
- market(shippingMethodId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
65
- shipping_zone(shippingMethodId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingZone>;
66
- shipping_category(shippingMethodId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingCategory>;
67
- delivery_lead_time_for_shipment(shippingMethodId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<DeliveryLeadTime>;
68
- attachments(shippingMethodId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
64
+ market(shippingMethodId: string | ShippingMethod, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
65
+ shipping_zone(shippingMethodId: string | ShippingMethod, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingZone>;
66
+ shipping_category(shippingMethodId: string | ShippingMethod, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingCategory>;
67
+ delivery_lead_time_for_shipment(shippingMethodId: string | ShippingMethod, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<DeliveryLeadTime>;
68
+ attachments(shippingMethodId: string | ShippingMethod, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
69
69
  isShippingMethod(resource: any): resource is ShippingMethod;
70
70
  relationship(id: string | ResourceId | null): ShippingMethodRel;
71
71
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class ShippingMethods extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:ShippingMethods.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:ShippingMethods.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:ShippingMethods.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:ShippingMethods.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:ShippingMethods.TYPE,id:e},t)}async market(e,t,s){return this.resources.fetch({type:"markets"},`shipping_methods/${e}/market`,t,s)}async shipping_zone(e,t,s){return this.resources.fetch({type:"shipping_zones"},`shipping_methods/${e}/shipping_zone`,t,s)}async shipping_category(e,t,s){return this.resources.fetch({type:"shipping_categories"},`shipping_methods/${e}/shipping_category`,t,s)}async delivery_lead_time_for_shipment(e,t,s){return this.resources.fetch({type:"delivery_lead_times"},`shipping_methods/${e}/delivery_lead_time_for_shipment`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`shipping_methods/${e}/attachments`,t,s)}isShippingMethod(e){return e.type&&e.type===ShippingMethods.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:ShippingMethods.TYPE}:{id:e.id,type:ShippingMethods.TYPE}}type(){return ShippingMethods.TYPE}}ShippingMethods.TYPE="shipping_methods",exports.default=ShippingMethods;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class ShippingMethods extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:ShippingMethods.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:ShippingMethods.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:ShippingMethods.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:ShippingMethods.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:ShippingMethods.TYPE,id:e},t)}async market(e,t,s){const r=e.id||e;return this.resources.fetch({type:"markets"},`shipping_methods/${r}/market`,t,s)}async shipping_zone(e,t,s){const r=e.id||e;return this.resources.fetch({type:"shipping_zones"},`shipping_methods/${r}/shipping_zone`,t,s)}async shipping_category(e,t,s){const r=e.id||e;return this.resources.fetch({type:"shipping_categories"},`shipping_methods/${r}/shipping_category`,t,s)}async delivery_lead_time_for_shipment(e,t,s){const r=e.id||e;return this.resources.fetch({type:"delivery_lead_times"},`shipping_methods/${r}/delivery_lead_time_for_shipment`,t,s)}async attachments(e,t,s){const r=e.id||e;return this.resources.fetch({type:"attachments"},`shipping_methods/${r}/attachments`,t,s)}isShippingMethod(e){return e.type&&e.type===ShippingMethods.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:ShippingMethods.TYPE}:{id:e.id,type:ShippingMethods.TYPE}}type(){return ShippingMethods.TYPE}}ShippingMethods.TYPE="shipping_methods",exports.default=ShippingMethods;
@@ -1,6 +1,6 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Attachment } from './attachments';
4
4
  declare type ShippingZoneRel = ResourceRel & {
5
5
  type: typeof ShippingZones.TYPE;
6
6
  };
@@ -39,7 +39,7 @@ declare class ShippingZones extends ApiResource {
39
39
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingZone>;
40
40
  update(resource: ShippingZoneUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingZone>;
41
41
  delete(id: string, options?: ResourcesConfig): Promise<void>;
42
- attachments(shippingZoneId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
42
+ attachments(shippingZoneId: string | ShippingZone, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
43
43
  isShippingZone(resource: any): resource is ShippingZone;
44
44
  relationship(id: string | ResourceId | null): ShippingZoneRel;
45
45
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class ShippingZones extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:ShippingZones.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:ShippingZones.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:ShippingZones.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:ShippingZones.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:ShippingZones.TYPE,id:e},t)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`shipping_zones/${e}/attachments`,t,r)}isShippingZone(e){return e.type&&e.type===ShippingZones.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:ShippingZones.TYPE}:{id:e.id,type:ShippingZones.TYPE}}type(){return ShippingZones.TYPE}}ShippingZones.TYPE="shipping_zones",exports.default=ShippingZones;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class ShippingZones extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:ShippingZones.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:ShippingZones.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:ShippingZones.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:ShippingZones.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:ShippingZones.TYPE,id:e},t)}async attachments(e,t,s){const r=e.id||e;return this.resources.fetch({type:"attachments"},`shipping_zones/${r}/attachments`,t,s)}isShippingZone(e){return e.type&&e.type===ShippingZones.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:ShippingZones.TYPE}:{id:e.id,type:ShippingZones.TYPE}}type(){return ShippingZones.TYPE}}ShippingZones.TYPE="shipping_zones",exports.default=ShippingZones;
@@ -1,7 +1,7 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { SkuList } from './sku_lists';
4
- import { Sku } from './skus';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { SkuList } from './sku_lists';
4
+ import type { Sku } from './skus';
5
5
  declare type SkuListItemRel = ResourceRel & {
6
6
  type: typeof SkuListItems.TYPE;
7
7
  };
@@ -37,8 +37,8 @@ declare class SkuListItems extends ApiResource {
37
37
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuListItem>;
38
38
  update(resource: SkuListItemUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuListItem>;
39
39
  delete(id: string, options?: ResourcesConfig): Promise<void>;
40
- sku_list(skuListItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
41
- sku(skuListItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
40
+ sku_list(skuListItemId: string | SkuListItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
41
+ sku(skuListItemId: string | SkuListItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
42
42
  isSkuListItem(resource: any): resource is SkuListItem;
43
43
  relationship(id: string | ResourceId | null): SkuListItemRel;
44
44
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuListItems extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:SkuListItems.TYPE},e,s)}async create(e,s,r){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuListItems.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:SkuListItems.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuListItems.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:SkuListItems.TYPE,id:e},s)}async sku_list(e,s,r){return this.resources.fetch({type:"sku_lists"},`sku_list_items/${e}/sku_list`,s,r)}async sku(e,s,r){return this.resources.fetch({type:"skus"},`sku_list_items/${e}/sku`,s,r)}isSkuListItem(e){return e.type&&e.type===SkuListItems.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuListItems.TYPE}:{id:e.id,type:SkuListItems.TYPE}}type(){return SkuListItems.TYPE}}SkuListItems.TYPE="sku_list_items",exports.default=SkuListItems;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuListItems extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:SkuListItems.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuListItems.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:SkuListItems.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuListItems.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:SkuListItems.TYPE,id:e},s)}async sku_list(e,s,t){const r=e.id||e;return this.resources.fetch({type:"sku_lists"},`sku_list_items/${r}/sku_list`,s,t)}async sku(e,s,t){const r=e.id||e;return this.resources.fetch({type:"skus"},`sku_list_items/${r}/sku`,s,t)}isSkuListItem(e){return e.type&&e.type===SkuListItems.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuListItems.TYPE}:{id:e.id,type:SkuListItems.TYPE}}type(){return SkuListItems.TYPE}}SkuListItems.TYPE="sku_list_items",exports.default=SkuListItems;
@@ -1,13 +1,13 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { PercentageDiscountPromotion } from './percentage_discount_promotions';
4
- import { FreeShippingPromotion } from './free_shipping_promotions';
5
- import { FixedAmountPromotion } from './fixed_amount_promotions';
6
- import { FreeGiftPromotion } from './free_gift_promotions';
7
- import { FixedPricePromotion } from './fixed_price_promotions';
8
- import { ExternalPromotion } from './external_promotions';
9
- import { SkuList } from './sku_lists';
10
- import { Sku } from './skus';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { PercentageDiscountPromotion } from './percentage_discount_promotions';
4
+ import type { FreeShippingPromotion } from './free_shipping_promotions';
5
+ import type { FixedAmountPromotion } from './fixed_amount_promotions';
6
+ import type { FreeGiftPromotion } from './free_gift_promotions';
7
+ import type { FixedPricePromotion } from './fixed_price_promotions';
8
+ import type { ExternalPromotion } from './external_promotions';
9
+ import type { SkuList } from './sku_lists';
10
+ import type { Sku } from './skus';
11
11
  declare type SkuListPromotionRuleRel = ResourceRel & {
12
12
  type: typeof SkuListPromotionRules.TYPE;
13
13
  };
@@ -58,8 +58,8 @@ declare class SkuListPromotionRules extends ApiResource {
58
58
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuListPromotionRule>;
59
59
  update(resource: SkuListPromotionRuleUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuListPromotionRule>;
60
60
  delete(id: string, options?: ResourcesConfig): Promise<void>;
61
- sku_list(skuListPromotionRuleId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
62
- skus(skuListPromotionRuleId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
61
+ sku_list(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
62
+ skus(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
63
63
  isSkuListPromotionRule(resource: any): resource is SkuListPromotionRule;
64
64
  relationship(id: string | ResourceId | null): SkuListPromotionRuleRel;
65
65
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuListPromotionRules extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:SkuListPromotionRules.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuListPromotionRules.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:SkuListPromotionRules.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuListPromotionRules.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:SkuListPromotionRules.TYPE,id:e},s)}async sku_list(e,s,t){return this.resources.fetch({type:"sku_lists"},`sku_list_promotion_rules/${e}/sku_list`,s,t)}async skus(e,s,t){return this.resources.fetch({type:"skus"},`sku_list_promotion_rules/${e}/skus`,s,t)}isSkuListPromotionRule(e){return e.type&&e.type===SkuListPromotionRules.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuListPromotionRules.TYPE}:{id:e.id,type:SkuListPromotionRules.TYPE}}type(){return SkuListPromotionRules.TYPE}}SkuListPromotionRules.TYPE="sku_list_promotion_rules",exports.default=SkuListPromotionRules;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuListPromotionRules extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:SkuListPromotionRules.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuListPromotionRules.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:SkuListPromotionRules.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuListPromotionRules.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:SkuListPromotionRules.TYPE,id:e},s)}async sku_list(e,s,t){const r=e.id||e;return this.resources.fetch({type:"sku_lists"},`sku_list_promotion_rules/${r}/sku_list`,s,t)}async skus(e,s,t){const r=e.id||e;return this.resources.fetch({type:"skus"},`sku_list_promotion_rules/${r}/skus`,s,t)}isSkuListPromotionRule(e){return e.type&&e.type===SkuListPromotionRules.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuListPromotionRules.TYPE}:{id:e.id,type:SkuListPromotionRules.TYPE}}type(){return SkuListPromotionRules.TYPE}}SkuListPromotionRules.TYPE="sku_list_promotion_rules",exports.default=SkuListPromotionRules;
@@ -1,8 +1,8 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Sku } from './skus';
4
- import { SkuListItem } from './sku_list_items';
5
- import { Bundle } from './bundles';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Sku } from './skus';
4
+ import type { SkuListItem } from './sku_list_items';
5
+ import type { Bundle } from './bundles';
6
6
  declare type SkuListRel = ResourceRel & {
7
7
  type: typeof SkuLists.TYPE;
8
8
  };
@@ -38,9 +38,9 @@ declare class SkuLists extends ApiResource {
38
38
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
39
39
  update(resource: SkuListUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
40
40
  delete(id: string, options?: ResourcesConfig): Promise<void>;
41
- skus(skuListId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
42
- sku_list_items(skuListId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SkuListItem>>;
43
- bundles(skuListId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Bundle>>;
41
+ skus(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
42
+ sku_list_items(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SkuListItem>>;
43
+ bundles(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Bundle>>;
44
44
  isSkuList(resource: any): resource is SkuList;
45
45
  relationship(id: string | ResourceId | null): SkuListRel;
46
46
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuLists extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:SkuLists.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuLists.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:SkuLists.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuLists.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:SkuLists.TYPE,id:e},s)}async skus(e,s,t){return this.resources.fetch({type:"skus"},`sku_lists/${e}/skus`,s,t)}async sku_list_items(e,s,t){return this.resources.fetch({type:"sku_list_items"},`sku_lists/${e}/sku_list_items`,s,t)}async bundles(e,s,t){return this.resources.fetch({type:"bundles"},`sku_lists/${e}/bundles`,s,t)}isSkuList(e){return e.type&&e.type===SkuLists.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuLists.TYPE}:{id:e.id,type:SkuLists.TYPE}}type(){return SkuLists.TYPE}}SkuLists.TYPE="sku_lists",exports.default=SkuLists;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuLists extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:SkuLists.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuLists.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:SkuLists.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuLists.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:SkuLists.TYPE,id:e},s)}async skus(e,s,t){const r=e.id||e;return this.resources.fetch({type:"skus"},`sku_lists/${r}/skus`,s,t)}async sku_list_items(e,s,t){const r=e.id||e;return this.resources.fetch({type:"sku_list_items"},`sku_lists/${r}/sku_list_items`,s,t)}async bundles(e,s,t){const r=e.id||e;return this.resources.fetch({type:"bundles"},`sku_lists/${r}/bundles`,s,t)}isSkuList(e){return e.type&&e.type===SkuLists.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuLists.TYPE}:{id:e.id,type:SkuLists.TYPE}}type(){return SkuLists.TYPE}}SkuLists.TYPE="sku_lists",exports.default=SkuLists;
@@ -1,7 +1,7 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Market } from './markets';
4
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Market } from './markets';
4
+ import type { Attachment } from './attachments';
5
5
  declare type SkuOptionRel = ResourceRel & {
6
6
  type: typeof SkuOptions.TYPE;
7
7
  };
@@ -46,8 +46,8 @@ declare class SkuOptions extends ApiResource {
46
46
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuOption>;
47
47
  update(resource: SkuOptionUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuOption>;
48
48
  delete(id: string, options?: ResourcesConfig): Promise<void>;
49
- market(skuOptionId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
50
- attachments(skuOptionId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
49
+ market(skuOptionId: string | SkuOption, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Market>;
50
+ attachments(skuOptionId: string | SkuOption, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
51
51
  isSkuOption(resource: any): resource is SkuOption;
52
52
  relationship(id: string | ResourceId | null): SkuOptionRel;
53
53
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuOptions extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:SkuOptions.TYPE},e,t)}async create(e,t,r){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuOptions.TYPE}),t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:SkuOptions.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuOptions.TYPE}),t,r)}async delete(e,t){await this.resources.delete({type:SkuOptions.TYPE,id:e},t)}async market(e,t,r){return this.resources.fetch({type:"markets"},`sku_options/${e}/market`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`sku_options/${e}/attachments`,t,r)}isSkuOption(e){return e.type&&e.type===SkuOptions.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuOptions.TYPE}:{id:e.id,type:SkuOptions.TYPE}}type(){return SkuOptions.TYPE}}SkuOptions.TYPE="sku_options",exports.default=SkuOptions;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class SkuOptions extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:SkuOptions.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:SkuOptions.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:SkuOptions.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:SkuOptions.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:SkuOptions.TYPE,id:e},t)}async market(e,t,s){const r=e.id||e;return this.resources.fetch({type:"markets"},`sku_options/${r}/market`,t,s)}async attachments(e,t,s){const r=e.id||e;return this.resources.fetch({type:"attachments"},`sku_options/${r}/attachments`,t,s)}isSkuOption(e){return e.type&&e.type===SkuOptions.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:SkuOptions.TYPE}:{id:e.id,type:SkuOptions.TYPE}}type(){return SkuOptions.TYPE}}SkuOptions.TYPE="sku_options",exports.default=SkuOptions;
@@ -1,11 +1,11 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { ShippingCategory } from './shipping_categories';
4
- import { Price } from './prices';
5
- import { StockItem } from './stock_items';
6
- import { DeliveryLeadTime } from './delivery_lead_times';
7
- import { SkuOption } from './sku_options';
8
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { ShippingCategory } from './shipping_categories';
4
+ import type { Price } from './prices';
5
+ import type { StockItem } from './stock_items';
6
+ import type { DeliveryLeadTime } from './delivery_lead_times';
7
+ import type { SkuOption } from './sku_options';
8
+ import type { Attachment } from './attachments';
9
9
  declare type SkuRel = ResourceRel & {
10
10
  type: typeof Skus.TYPE;
11
11
  };
@@ -64,12 +64,12 @@ declare class Skus extends ApiResource {
64
64
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
65
65
  update(resource: SkuUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
66
66
  delete(id: string, options?: ResourcesConfig): Promise<void>;
67
- shipping_category(skuId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingCategory>;
68
- prices(skuId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Price>>;
69
- stock_items(skuId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockItem>>;
70
- delivery_lead_times(skuId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<DeliveryLeadTime>>;
71
- sku_options(skuId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SkuOption>>;
72
- attachments(skuId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
67
+ shipping_category(skuId: string | Sku, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingCategory>;
68
+ prices(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Price>>;
69
+ stock_items(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockItem>>;
70
+ delivery_lead_times(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<DeliveryLeadTime>>;
71
+ sku_options(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SkuOption>>;
72
+ attachments(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
73
73
  isSku(resource: any): resource is Sku;
74
74
  relationship(id: string | ResourceId | null): SkuRel;
75
75
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Skus extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:Skus.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:Skus.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:Skus.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:Skus.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:Skus.TYPE,id:e},s)}async shipping_category(e,s,t){return this.resources.fetch({type:"shipping_categories"},`skus/${e}/shipping_category`,s,t)}async prices(e,s,t){return this.resources.fetch({type:"prices"},`skus/${e}/prices`,s,t)}async stock_items(e,s,t){return this.resources.fetch({type:"stock_items"},`skus/${e}/stock_items`,s,t)}async delivery_lead_times(e,s,t){return this.resources.fetch({type:"delivery_lead_times"},`skus/${e}/delivery_lead_times`,s,t)}async sku_options(e,s,t){return this.resources.fetch({type:"sku_options"},`skus/${e}/sku_options`,s,t)}async attachments(e,s,t){return this.resources.fetch({type:"attachments"},`skus/${e}/attachments`,s,t)}isSku(e){return e.type&&e.type===Skus.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Skus.TYPE}:{id:e.id,type:Skus.TYPE}}type(){return Skus.TYPE}}Skus.TYPE="skus",exports.default=Skus;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class Skus extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:Skus.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:Skus.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:Skus.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:Skus.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:Skus.TYPE,id:e},s)}async shipping_category(e,s,t){const r=e.id||e;return this.resources.fetch({type:"shipping_categories"},`skus/${r}/shipping_category`,s,t)}async prices(e,s,t){const r=e.id||e;return this.resources.fetch({type:"prices"},`skus/${r}/prices`,s,t)}async stock_items(e,s,t){const r=e.id||e;return this.resources.fetch({type:"stock_items"},`skus/${r}/stock_items`,s,t)}async delivery_lead_times(e,s,t){const r=e.id||e;return this.resources.fetch({type:"delivery_lead_times"},`skus/${r}/delivery_lead_times`,s,t)}async sku_options(e,s,t){const r=e.id||e;return this.resources.fetch({type:"sku_options"},`skus/${r}/sku_options`,s,t)}async attachments(e,s,t){const r=e.id||e;return this.resources.fetch({type:"attachments"},`skus/${r}/attachments`,s,t)}isSku(e){return e.type&&e.type===Skus.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:Skus.TYPE}:{id:e.id,type:Skus.TYPE}}type(){return Skus.TYPE}}Skus.TYPE="skus",exports.default=Skus;
@@ -1,8 +1,8 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { StockLocation } from './stock_locations';
4
- import { Sku } from './skus';
5
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { StockLocation } from './stock_locations';
4
+ import type { Sku } from './skus';
5
+ import type { Attachment } from './attachments';
6
6
  declare type StockItemRel = ResourceRel & {
7
7
  type: typeof StockItems.TYPE;
8
8
  };
@@ -38,9 +38,9 @@ declare class StockItems extends ApiResource {
38
38
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
39
39
  update(resource: StockItemUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
40
40
  delete(id: string, options?: ResourcesConfig): Promise<void>;
41
- stock_location(stockItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
42
- sku(stockItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
43
- attachments(stockItemId: string, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
41
+ stock_location(stockItemId: string | StockItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
42
+ sku(stockItemId: string | StockItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
43
+ attachments(stockItemId: string | StockItem, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
44
44
  isStockItem(resource: any): resource is StockItem;
45
45
  relationship(id: string | ResourceId | null): StockItemRel;
46
46
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockItems extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockItems.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StockItems.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:StockItems.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StockItems.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:StockItems.TYPE,id:e},t)}async stock_location(e,t,s){return this.resources.fetch({type:"stock_locations"},`stock_items/${e}/stock_location`,t,s)}async sku(e,t,s){return this.resources.fetch({type:"skus"},`stock_items/${e}/sku`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`stock_items/${e}/attachments`,t,s)}isStockItem(e){return e.type&&e.type===StockItems.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockItems.TYPE}:{id:e.id,type:StockItems.TYPE}}type(){return StockItems.TYPE}}StockItems.TYPE="stock_items",exports.default=StockItems;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockItems extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockItems.TYPE},e,t)}async create(e,t,s){return this.resources.create(Object.assign(Object.assign({},e),{type:StockItems.TYPE}),t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:StockItems.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update(Object.assign(Object.assign({},e),{type:StockItems.TYPE}),t,s)}async delete(e,t){await this.resources.delete({type:StockItems.TYPE,id:e},t)}async stock_location(e,t,s){const r=e.id||e;return this.resources.fetch({type:"stock_locations"},`stock_items/${r}/stock_location`,t,s)}async sku(e,t,s){const r=e.id||e;return this.resources.fetch({type:"skus"},`stock_items/${r}/sku`,t,s)}async attachments(e,t,s){const r=e.id||e;return this.resources.fetch({type:"attachments"},`stock_items/${r}/attachments`,t,s)}isStockItem(e){return e.type&&e.type===StockItems.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockItems.TYPE}:{id:e.id,type:StockItems.TYPE}}type(){return StockItems.TYPE}}StockItems.TYPE="stock_items",exports.default=StockItems;
@@ -1,8 +1,8 @@
1
1
  import { ApiResource, Resource, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Shipment } from './shipments';
4
- import { LineItem } from './line_items';
5
- import { StockItem } from './stock_items';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Shipment } from './shipments';
4
+ import type { LineItem } from './line_items';
5
+ import type { StockItem } from './stock_items';
6
6
  declare type StockLineItemRel = ResourceRel & {
7
7
  type: typeof StockLineItems.TYPE;
8
8
  };
@@ -18,9 +18,9 @@ declare class StockLineItems extends ApiResource {
18
18
  static readonly TYPE: 'stock_line_items';
19
19
  list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockLineItem>>;
20
20
  retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLineItem>;
21
- shipment(stockLineItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
22
- line_item(stockLineItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
23
- stock_item(stockLineItemId: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
21
+ shipment(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
22
+ line_item(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
23
+ stock_item(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
24
24
  isStockLineItem(resource: any): resource is StockLineItem;
25
25
  relationship(id: string | ResourceId | null): StockLineItemRel;
26
26
  type(): string;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockLineItems extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockLineItems.TYPE},e,t)}async retrieve(e,t,s){return this.resources.retrieve({type:StockLineItems.TYPE,id:e},t,s)}async shipment(e,t,s){return this.resources.fetch({type:"shipments"},`stock_line_items/${e}/shipment`,t,s)}async line_item(e,t,s){return this.resources.fetch({type:"line_items"},`stock_line_items/${e}/line_item`,t,s)}async stock_item(e,t,s){return this.resources.fetch({type:"stock_items"},`stock_line_items/${e}/stock_item`,t,s)}isStockLineItem(e){return e.type&&e.type===StockLineItems.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockLineItems.TYPE}:{id:e.id,type:StockLineItems.TYPE}}type(){return StockLineItems.TYPE}}StockLineItems.TYPE="stock_line_items",exports.default=StockLineItems;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockLineItems extends resource_1.ApiResource{async list(e,t){return this.resources.list({type:StockLineItems.TYPE},e,t)}async retrieve(e,t,s){return this.resources.retrieve({type:StockLineItems.TYPE,id:e},t,s)}async shipment(e,t,s){const r=e.id||e;return this.resources.fetch({type:"shipments"},`stock_line_items/${r}/shipment`,t,s)}async line_item(e,t,s){const r=e.id||e;return this.resources.fetch({type:"line_items"},`stock_line_items/${r}/line_item`,t,s)}async stock_item(e,t,s){const r=e.id||e;return this.resources.fetch({type:"stock_items"},`stock_line_items/${r}/stock_item`,t,s)}isStockLineItem(e){return e.type&&e.type===StockLineItems.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:StockLineItems.TYPE}:{id:e.id,type:StockLineItems.TYPE}}type(){return StockLineItems.TYPE}}StockLineItems.TYPE="stock_line_items",exports.default=StockLineItems;
@@ -1,11 +1,11 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Address } from './addresses';
4
- import { InventoryStockLocation } from './inventory_stock_locations';
5
- import { InventoryReturnLocation } from './inventory_return_locations';
6
- import { StockItem } from './stock_items';
7
- import { StockTransfer } from './stock_transfers';
8
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Address } from './addresses';
4
+ import type { InventoryStockLocation } from './inventory_stock_locations';
5
+ import type { InventoryReturnLocation } from './inventory_return_locations';
6
+ import type { StockItem } from './stock_items';
7
+ import type { StockTransfer } from './stock_transfers';
8
+ import type { Attachment } from './attachments';
9
9
  declare type StockLocationRel = ResourceRel & {
10
10
  type: typeof StockLocations.TYPE;
11
11
  };
@@ -43,12 +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
+ address(stockLocationId: string | StockLocation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Address>;
47
+ inventory_stock_locations(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<InventoryStockLocation>>;
48
+ inventory_return_locations(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<InventoryReturnLocation>>;
49
+ stock_items(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockItem>>;
50
+ stock_transfers(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockTransfer>>;
51
+ attachments(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
52
52
  isStockLocation(resource: any): resource is StockLocation;
53
53
  relationship(id: string | ResourceId | null): StockLocationRel;
54
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,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;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockLocations extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:StockLocations.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:StockLocations.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:StockLocations.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:StockLocations.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:StockLocations.TYPE,id:e},s)}async address(e,s,t){const r=e.id||e;return this.resources.fetch({type:"addresses"},`stock_locations/${r}/address`,s,t)}async inventory_stock_locations(e,s,t){const r=e.id||e;return this.resources.fetch({type:"inventory_stock_locations"},`stock_locations/${r}/inventory_stock_locations`,s,t)}async inventory_return_locations(e,s,t){const r=e.id||e;return this.resources.fetch({type:"inventory_return_locations"},`stock_locations/${r}/inventory_return_locations`,s,t)}async stock_items(e,s,t){const r=e.id||e;return this.resources.fetch({type:"stock_items"},`stock_locations/${r}/stock_items`,s,t)}async stock_transfers(e,s,t){const r=e.id||e;return this.resources.fetch({type:"stock_transfers"},`stock_locations/${r}/stock_transfers`,s,t)}async attachments(e,s,t){const r=e.id||e;return this.resources.fetch({type:"attachments"},`stock_locations/${r}/attachments`,s,t)}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,9 +1,9 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Sku } from './skus';
4
- import { StockLocation } from './stock_locations';
5
- import { Shipment } from './shipments';
6
- import { LineItem } from './line_items';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Sku } from './skus';
4
+ import type { StockLocation } from './stock_locations';
5
+ import type { Shipment } from './shipments';
6
+ import type { LineItem } from './line_items';
7
7
  declare type StockTransferRel = ResourceRel & {
8
8
  type: typeof StockTransfers.TYPE;
9
9
  };
@@ -58,11 +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
+ sku(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
62
+ origin_stock_location(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
63
+ destination_stock_location(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
64
+ shipment(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
65
+ line_item(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
66
66
  isStockTransfer(resource: any): resource is StockTransfer;
67
67
  relationship(id: string | ResourceId | null): StockTransferRel;
68
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)}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;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const resource_1=require("../resource");class StockTransfers extends resource_1.ApiResource{async list(e,s){return this.resources.list({type:StockTransfers.TYPE},e,s)}async create(e,s,t){return this.resources.create(Object.assign(Object.assign({},e),{type:StockTransfers.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:StockTransfers.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:StockTransfers.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:StockTransfers.TYPE,id:e},s)}async sku(e,s,t){const r=e.id||e;return this.resources.fetch({type:"skus"},`stock_transfers/${r}/sku`,s,t)}async origin_stock_location(e,s,t){const r=e.id||e;return this.resources.fetch({type:"stock_locations"},`stock_transfers/${r}/origin_stock_location`,s,t)}async destination_stock_location(e,s,t){const r=e.id||e;return this.resources.fetch({type:"stock_locations"},`stock_transfers/${r}/destination_stock_location`,s,t)}async shipment(e,s,t){const r=e.id||e;return this.resources.fetch({type:"shipments"},`stock_transfers/${r}/shipment`,s,t)}async line_item(e,s,t){const r=e.id||e;return this.resources.fetch({type:"line_items"},`stock_transfers/${r}/line_item`,s,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,7 +1,7 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { PaymentMethod } from './payment_methods';
4
- import { StripePayment } from './stripe_payments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { PaymentMethod } from './payment_methods';
4
+ import type { StripePayment } from './stripe_payments';
5
5
  declare type StripeGatewayRel = ResourceRel & {
6
6
  type: typeof StripeGateways.TYPE;
7
7
  };
@@ -28,8 +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
+ payment_methods(stripeGatewayId: string | StripeGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
32
+ stripe_payments(stripeGatewayId: string | StripeGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StripePayment>>;
33
33
  isStripeGateway(resource: any): resource is StripeGateway;
34
34
  relationship(id: string | ResourceId | null): StripeGatewayRel;
35
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,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;
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){const r=e.id||e;return this.resources.fetch({type:"payment_methods"},`stripe_gateways/${r}/payment_methods`,t,s)}async stripe_payments(e,t,s){const r=e.id||e;return this.resources.fetch({type:"stripe_payments"},`stripe_gateways/${r}/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;
@@ -1,7 +1,7 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Order } from './orders';
4
- import { PaymentGateway } from './payment_gateways';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Order } from './orders';
4
+ import type { PaymentGateway } from './payment_gateways';
5
5
  declare type StripePaymentRel = ResourceRel & {
6
6
  type: typeof StripePayments.TYPE;
7
7
  };
@@ -32,8 +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
+ order(stripePaymentId: string | StripePayment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
36
+ payment_gateway(stripePaymentId: string | StripePayment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
37
37
  isStripePayment(resource: any): resource is StripePayment;
38
38
  relationship(id: string | ResourceId | null): StripePaymentRel;
39
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,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;
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,t){return this.resources.create(Object.assign(Object.assign({},e),{type:StripePayments.TYPE}),s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:StripePayments.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update(Object.assign(Object.assign({},e),{type:StripePayments.TYPE}),s,t)}async delete(e,s){await this.resources.delete({type:StripePayments.TYPE,id:e},s)}async order(e,s,t){const r=e.id||e;return this.resources.fetch({type:"orders"},`stripe_payments/${r}/order`,s,t)}async payment_gateway(e,s,t){const r=e.id||e;return this.resources.fetch({type:"payment_gateways"},`stripe_payments/${r}/payment_gateway`,s,t)}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,8 +1,8 @@
1
1
  import { ApiResource, Resource, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { TaxCategory } from './tax_categories';
4
- import { Market } from './markets';
5
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { TaxCategory } from './tax_categories';
4
+ import type { Market } from './markets';
5
+ import type { Attachment } from './attachments';
6
6
  declare type TaxCalculatorRel = ResourceRel & {
7
7
  type: typeof TaxCalculators.TYPE;
8
8
  };
@@ -16,9 +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
+ tax_categories(taxCalculatorId: string | TaxCalculator, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<TaxCategory>>;
20
+ markets(taxCalculatorId: string | TaxCalculator, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Market>>;
21
+ attachments(taxCalculatorId: string | TaxCalculator, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
22
22
  isTaxCalculator(resource: any): resource is TaxCalculator;
23
23
  relationship(id: string | ResourceId | null): TaxCalculatorRel;
24
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,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;
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){const s=e.id||e;return this.resources.fetch({type:"tax_categories"},`tax_calculators/${s}/tax_categories`,t,r)}async markets(e,t,r){const s=e.id||e;return this.resources.fetch({type:"markets"},`tax_calculators/${s}/markets`,t,r)}async attachments(e,t,r){const s=e.id||e;return this.resources.fetch({type:"attachments"},`tax_calculators/${s}/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;
@@ -1,11 +1,11 @@
1
1
  import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
2
- import { QueryParamsList, QueryParamsRetrieve } from '../query';
3
- import { Sku } from './skus';
4
- import { AvalaraAccount } from './avalara_accounts';
5
- import { TaxjarAccount } from './taxjar_accounts';
6
- import { ManualTaxCalculator } from './manual_tax_calculators';
7
- import { ExternalTaxCalculator } from './external_tax_calculators';
8
- import { Attachment } from './attachments';
2
+ import type { QueryParamsList, QueryParamsRetrieve } from '../query';
3
+ import type { Sku } from './skus';
4
+ import type { AvalaraAccount } from './avalara_accounts';
5
+ import type { TaxjarAccount } from './taxjar_accounts';
6
+ import type { ManualTaxCalculator } from './manual_tax_calculators';
7
+ import type { ExternalTaxCalculator } from './external_tax_calculators';
8
+ import type { Attachment } from './attachments';
9
9
  declare type TaxCategoryRel = ResourceRel & {
10
10
  type: typeof TaxCategories.TYPE;
11
11
  };
@@ -49,8 +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
+ sku(taxCategoryId: string | TaxCategory, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
53
+ attachments(taxCategoryId: string | TaxCategory, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
54
54
  isTaxCategory(resource: any): resource is TaxCategory;
55
55
  relationship(id: string | ResourceId | null): TaxCategoryRel;
56
56
  type(): string;