@commercelayer/sdk 3.2.1 → 3.6.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 (647) hide show
  1. package/lib/api.d.ts +1 -0
  2. package/lib/api.js +1 -0
  3. package/lib/cjs/api.d.ts +1 -1
  4. package/lib/cjs/client.js +1 -1
  5. package/lib/cjs/commercelayer.js +1 -1
  6. package/lib/cjs/common.js +1 -1
  7. package/lib/cjs/debug.d.ts +1 -3
  8. package/lib/cjs/debug.js +1 -1
  9. package/lib/cjs/error.d.ts +1 -26
  10. package/lib/cjs/index.js +1 -1
  11. package/lib/cjs/interceptor.d.ts +1 -19
  12. package/lib/cjs/jsonapi.js +1 -1
  13. package/lib/cjs/model.d.ts +1 -1
  14. package/lib/cjs/query.js +1 -1
  15. package/lib/cjs/resource.d.ts +6 -2
  16. package/lib/cjs/resource.js +1 -1
  17. package/lib/cjs/resources/addresses.d.ts +5 -5
  18. package/lib/cjs/resources/addresses.js +1 -1
  19. package/lib/cjs/resources/adjustments.d.ts +4 -4
  20. package/lib/cjs/resources/adjustments.js +1 -1
  21. package/lib/cjs/resources/adyen_gateways.d.ts +5 -5
  22. package/lib/cjs/resources/adyen_gateways.js +1 -1
  23. package/lib/cjs/resources/adyen_payments.d.ts +6 -5
  24. package/lib/cjs/resources/adyen_payments.js +1 -1
  25. package/lib/cjs/resources/application.d.ts +4 -4
  26. package/lib/cjs/resources/application.js +1 -1
  27. package/lib/cjs/resources/attachments.d.ts +34 -34
  28. package/lib/cjs/resources/attachments.js +1 -1
  29. package/lib/cjs/resources/authorizations.d.ts +4 -4
  30. package/lib/cjs/resources/authorizations.js +1 -1
  31. package/lib/cjs/resources/avalara_accounts.d.ts +5 -5
  32. package/lib/cjs/resources/avalara_accounts.js +1 -1
  33. package/lib/cjs/resources/billing_info_validation_rules.d.ts +5 -5
  34. package/lib/cjs/resources/billing_info_validation_rules.js +1 -1
  35. package/lib/cjs/resources/bing_geocoders.d.ts +4 -4
  36. package/lib/cjs/resources/bing_geocoders.js +1 -1
  37. package/lib/cjs/resources/braintree_gateways.d.ts +5 -5
  38. package/lib/cjs/resources/braintree_gateways.js +1 -1
  39. package/lib/cjs/resources/braintree_payments.d.ts +5 -5
  40. package/lib/cjs/resources/braintree_payments.js +1 -1
  41. package/lib/cjs/resources/bundles.d.ts +11 -6
  42. package/lib/cjs/resources/bundles.js +1 -1
  43. package/lib/cjs/resources/captures.d.ts +4 -4
  44. package/lib/cjs/resources/captures.js +1 -1
  45. package/lib/cjs/resources/carrier_accounts.d.ts +4 -4
  46. package/lib/cjs/resources/carrier_accounts.js +1 -1
  47. package/lib/cjs/resources/checkout_com_gateways.d.ts +5 -5
  48. package/lib/cjs/resources/checkout_com_gateways.js +1 -1
  49. package/lib/cjs/resources/checkout_com_payments.d.ts +13 -5
  50. package/lib/cjs/resources/checkout_com_payments.js +1 -1
  51. package/lib/cjs/resources/coupon_codes_promotion_rules.d.ts +11 -11
  52. package/lib/cjs/resources/coupon_codes_promotion_rules.js +1 -1
  53. package/lib/cjs/resources/coupon_recipients.d.ts +5 -5
  54. package/lib/cjs/resources/coupon_recipients.js +1 -1
  55. package/lib/cjs/resources/coupons.d.ts +5 -5
  56. package/lib/cjs/resources/coupons.js +1 -1
  57. package/lib/cjs/resources/customer_addresses.d.ts +6 -6
  58. package/lib/cjs/resources/customer_addresses.js +1 -1
  59. package/lib/cjs/resources/customer_groups.d.ts +4 -4
  60. package/lib/cjs/resources/customer_groups.js +1 -1
  61. package/lib/cjs/resources/customer_password_resets.d.ts +4 -4
  62. package/lib/cjs/resources/customer_password_resets.js +1 -1
  63. package/lib/cjs/resources/customer_payment_sources.d.ts +13 -13
  64. package/lib/cjs/resources/customer_payment_sources.js +1 -1
  65. package/lib/cjs/resources/customer_subscriptions.d.ts +4 -4
  66. package/lib/cjs/resources/customer_subscriptions.js +1 -1
  67. package/lib/cjs/resources/customers.d.ts +5 -5
  68. package/lib/cjs/resources/customers.js +1 -1
  69. package/lib/cjs/resources/delivery_lead_times.d.ts +6 -6
  70. package/lib/cjs/resources/delivery_lead_times.js +1 -1
  71. package/lib/cjs/resources/event_callbacks.d.ts +4 -4
  72. package/lib/cjs/resources/event_callbacks.js +1 -1
  73. package/lib/cjs/resources/external_gateways.d.ts +4 -4
  74. package/lib/cjs/resources/external_gateways.js +1 -1
  75. package/lib/cjs/resources/external_payments.d.ts +5 -5
  76. package/lib/cjs/resources/external_payments.js +1 -1
  77. package/lib/cjs/resources/external_promotions.d.ts +12 -9
  78. package/lib/cjs/resources/external_promotions.js +1 -1
  79. package/lib/cjs/resources/external_tax_calculators.d.ts +5 -5
  80. package/lib/cjs/resources/external_tax_calculators.js +1 -1
  81. package/lib/cjs/resources/fixed_amount_promotions.d.ts +12 -9
  82. package/lib/cjs/resources/fixed_amount_promotions.js +1 -1
  83. package/lib/cjs/resources/fixed_price_promotions.d.ts +13 -10
  84. package/lib/cjs/resources/fixed_price_promotions.js +1 -1
  85. package/lib/cjs/resources/free_gift_promotions.d.ts +13 -10
  86. package/lib/cjs/resources/free_gift_promotions.js +1 -1
  87. package/lib/cjs/resources/free_shipping_promotions.d.ts +12 -9
  88. package/lib/cjs/resources/free_shipping_promotions.js +1 -1
  89. package/lib/cjs/resources/geocoders.d.ts +4 -4
  90. package/lib/cjs/resources/geocoders.js +1 -1
  91. package/lib/cjs/resources/gift_card_recipients.d.ts +5 -5
  92. package/lib/cjs/resources/gift_card_recipients.js +1 -1
  93. package/lib/cjs/resources/gift_cards.d.ts +7 -7
  94. package/lib/cjs/resources/gift_cards.js +1 -1
  95. package/lib/cjs/resources/google_geocoders.d.ts +4 -4
  96. package/lib/cjs/resources/google_geocoders.js +1 -1
  97. package/lib/cjs/resources/imports.d.ts +4 -4
  98. package/lib/cjs/resources/imports.js +1 -1
  99. package/lib/cjs/resources/in_stock_subscriptions.d.ts +7 -7
  100. package/lib/cjs/resources/in_stock_subscriptions.js +1 -1
  101. package/lib/cjs/resources/inventory_models.d.ts +4 -4
  102. package/lib/cjs/resources/inventory_models.js +1 -1
  103. package/lib/cjs/resources/inventory_return_locations.d.ts +6 -6
  104. package/lib/cjs/resources/inventory_return_locations.js +1 -1
  105. package/lib/cjs/resources/inventory_stock_locations.d.ts +6 -6
  106. package/lib/cjs/resources/inventory_stock_locations.js +1 -1
  107. package/lib/cjs/resources/klarna_gateways.d.ts +5 -5
  108. package/lib/cjs/resources/klarna_gateways.js +1 -1
  109. package/lib/cjs/resources/klarna_payments.d.ts +5 -5
  110. package/lib/cjs/resources/klarna_payments.js +1 -1
  111. package/lib/cjs/resources/line_item_options.d.ts +6 -6
  112. package/lib/cjs/resources/line_item_options.js +1 -1
  113. package/lib/cjs/resources/line_items.d.ts +15 -15
  114. package/lib/cjs/resources/line_items.js +1 -1
  115. package/lib/cjs/resources/manual_gateways.d.ts +4 -4
  116. package/lib/cjs/resources/manual_gateways.js +1 -1
  117. package/lib/cjs/resources/manual_tax_calculators.d.ts +6 -6
  118. package/lib/cjs/resources/manual_tax_calculators.js +1 -1
  119. package/lib/cjs/resources/markets.d.ts +9 -9
  120. package/lib/cjs/resources/markets.js +1 -1
  121. package/lib/cjs/resources/merchants.d.ts +5 -5
  122. package/lib/cjs/resources/merchants.js +1 -1
  123. package/lib/cjs/resources/order_amount_promotion_rules.d.ts +10 -10
  124. package/lib/cjs/resources/order_amount_promotion_rules.js +1 -1
  125. package/lib/cjs/resources/order_copies.d.ts +5 -5
  126. package/lib/cjs/resources/order_copies.js +1 -1
  127. package/lib/cjs/resources/order_subscriptions.d.ts +6 -6
  128. package/lib/cjs/resources/order_subscriptions.js +1 -1
  129. package/lib/cjs/resources/order_validation_rules.d.ts +4 -4
  130. package/lib/cjs/resources/order_validation_rules.js +1 -1
  131. package/lib/cjs/resources/orders.d.ts +16 -16
  132. package/lib/cjs/resources/orders.js +1 -1
  133. package/lib/cjs/resources/organization.d.ts +4 -4
  134. package/lib/cjs/resources/organization.js +1 -1
  135. package/lib/cjs/resources/packages.d.ts +5 -5
  136. package/lib/cjs/resources/packages.js +1 -1
  137. package/lib/cjs/resources/parcel_line_items.d.ts +6 -6
  138. package/lib/cjs/resources/parcel_line_items.js +1 -1
  139. package/lib/cjs/resources/parcels.d.ts +6 -6
  140. package/lib/cjs/resources/parcels.js +1 -1
  141. package/lib/cjs/resources/payment_gateways.d.ts +4 -4
  142. package/lib/cjs/resources/payment_gateways.js +1 -1
  143. package/lib/cjs/resources/payment_methods.d.ts +10 -7
  144. package/lib/cjs/resources/payment_methods.js +1 -1
  145. package/lib/cjs/resources/paypal_gateways.d.ts +4 -6
  146. package/lib/cjs/resources/paypal_gateways.js +1 -1
  147. package/lib/cjs/resources/paypal_payments.d.ts +9 -5
  148. package/lib/cjs/resources/paypal_payments.js +1 -1
  149. package/lib/cjs/resources/percentage_discount_promotions.d.ts +13 -10
  150. package/lib/cjs/resources/percentage_discount_promotions.js +1 -1
  151. package/lib/cjs/resources/price_lists.d.ts +4 -4
  152. package/lib/cjs/resources/price_lists.js +1 -1
  153. package/lib/cjs/resources/prices.d.ts +6 -6
  154. package/lib/cjs/resources/prices.js +1 -1
  155. package/lib/cjs/resources/promotion_rules.d.ts +4 -4
  156. package/lib/cjs/resources/promotion_rules.js +1 -1
  157. package/lib/cjs/resources/promotions.d.ts +5 -4
  158. package/lib/cjs/resources/promotions.js +1 -1
  159. package/lib/cjs/resources/refunds.d.ts +4 -4
  160. package/lib/cjs/resources/refunds.js +1 -1
  161. package/lib/cjs/resources/return_line_items.d.ts +6 -6
  162. package/lib/cjs/resources/return_line_items.js +1 -1
  163. package/lib/cjs/resources/returns.d.ts +6 -6
  164. package/lib/cjs/resources/returns.js +1 -1
  165. package/lib/cjs/resources/shipments.d.ts +5 -5
  166. package/lib/cjs/resources/shipments.js +1 -1
  167. package/lib/cjs/resources/shipping_categories.d.ts +4 -4
  168. package/lib/cjs/resources/shipping_categories.js +1 -1
  169. package/lib/cjs/resources/shipping_methods.d.ts +11 -9
  170. package/lib/cjs/resources/shipping_methods.js +1 -1
  171. package/lib/cjs/resources/shipping_zones.d.ts +4 -4
  172. package/lib/cjs/resources/shipping_zones.js +1 -1
  173. package/lib/cjs/resources/sku_list_items.d.ts +6 -6
  174. package/lib/cjs/resources/sku_list_items.js +1 -1
  175. package/lib/cjs/resources/sku_list_promotion_rules.d.ts +11 -11
  176. package/lib/cjs/resources/sku_list_promotion_rules.js +1 -1
  177. package/lib/cjs/resources/sku_lists.d.ts +4 -4
  178. package/lib/cjs/resources/sku_lists.js +1 -1
  179. package/lib/cjs/resources/sku_options.d.ts +9 -6
  180. package/lib/cjs/resources/sku_options.js +1 -1
  181. package/lib/cjs/resources/skus.d.ts +5 -5
  182. package/lib/cjs/resources/skus.js +1 -1
  183. package/lib/cjs/resources/stock_items.d.ts +6 -6
  184. package/lib/cjs/resources/stock_items.js +1 -1
  185. package/lib/cjs/resources/stock_line_items.d.ts +4 -4
  186. package/lib/cjs/resources/stock_line_items.js +1 -1
  187. package/lib/cjs/resources/stock_locations.d.ts +5 -5
  188. package/lib/cjs/resources/stock_locations.js +1 -1
  189. package/lib/cjs/resources/stock_transfers.d.ts +8 -8
  190. package/lib/cjs/resources/stock_transfers.js +1 -1
  191. package/lib/cjs/resources/stripe_gateways.d.ts +4 -4
  192. package/lib/cjs/resources/stripe_gateways.js +1 -1
  193. package/lib/cjs/resources/stripe_payments.d.ts +9 -5
  194. package/lib/cjs/resources/stripe_payments.js +1 -1
  195. package/lib/cjs/resources/tax_calculators.d.ts +4 -4
  196. package/lib/cjs/resources/tax_calculators.js +1 -1
  197. package/lib/cjs/resources/tax_categories.d.ts +9 -9
  198. package/lib/cjs/resources/tax_categories.js +1 -1
  199. package/lib/cjs/resources/tax_rules.d.ts +5 -5
  200. package/lib/cjs/resources/tax_rules.js +1 -1
  201. package/lib/cjs/resources/taxjar_accounts.d.ts +5 -5
  202. package/lib/cjs/resources/taxjar_accounts.js +1 -1
  203. package/lib/cjs/resources/transactions.d.ts +4 -4
  204. package/lib/cjs/resources/transactions.js +1 -1
  205. package/lib/cjs/resources/voids.d.ts +4 -4
  206. package/lib/cjs/resources/voids.js +1 -1
  207. package/lib/cjs/resources/webhooks.d.ts +4 -4
  208. package/lib/cjs/resources/webhooks.js +1 -1
  209. package/lib/cjs/resources/wire_transfers.d.ts +5 -5
  210. package/lib/cjs/resources/wire_transfers.js +1 -1
  211. package/lib/cjs/static.js +1 -1
  212. package/lib/cjs/util.d.ts +1 -3
  213. package/lib/client.d.ts +2 -0
  214. package/lib/client.js +1 -0
  215. package/lib/commercelayer.d.ts +1 -0
  216. package/lib/commercelayer.js +1 -0
  217. package/lib/common.d.ts +1 -0
  218. package/lib/common.js +1 -0
  219. package/lib/config.d.ts +1 -0
  220. package/lib/config.js +1 -0
  221. package/lib/debug.d.ts +1 -0
  222. package/lib/debug.js +1 -0
  223. package/lib/error.d.ts +1 -0
  224. package/lib/error.js +1 -0
  225. package/lib/esm/api.d.ts +1 -1
  226. package/lib/esm/client.js +1 -1
  227. package/lib/esm/commercelayer.js +1 -1
  228. package/lib/esm/common.js +1 -1
  229. package/lib/esm/debug.d.ts +1 -3
  230. package/lib/esm/debug.js +1 -1
  231. package/lib/esm/error.d.ts +1 -26
  232. package/lib/esm/error.js +1 -1
  233. package/lib/esm/interceptor.d.ts +1 -19
  234. package/lib/esm/jsonapi.js +1 -1
  235. package/lib/esm/model.d.ts +1 -1
  236. package/lib/esm/query.js +1 -1
  237. package/lib/esm/resource.d.ts +6 -2
  238. package/lib/esm/resource.js +1 -1
  239. package/lib/esm/resources/addresses.d.ts +5 -5
  240. package/lib/esm/resources/addresses.js +1 -1
  241. package/lib/esm/resources/adjustments.d.ts +4 -4
  242. package/lib/esm/resources/adjustments.js +1 -1
  243. package/lib/esm/resources/adyen_gateways.d.ts +5 -5
  244. package/lib/esm/resources/adyen_gateways.js +1 -1
  245. package/lib/esm/resources/adyen_payments.d.ts +6 -5
  246. package/lib/esm/resources/adyen_payments.js +1 -1
  247. package/lib/esm/resources/application.d.ts +4 -4
  248. package/lib/esm/resources/application.js +1 -1
  249. package/lib/esm/resources/attachments.d.ts +34 -34
  250. package/lib/esm/resources/attachments.js +1 -1
  251. package/lib/esm/resources/authorizations.d.ts +4 -4
  252. package/lib/esm/resources/authorizations.js +1 -1
  253. package/lib/esm/resources/avalara_accounts.d.ts +5 -5
  254. package/lib/esm/resources/avalara_accounts.js +1 -1
  255. package/lib/esm/resources/billing_info_validation_rules.d.ts +5 -5
  256. package/lib/esm/resources/billing_info_validation_rules.js +1 -1
  257. package/lib/esm/resources/bing_geocoders.d.ts +4 -4
  258. package/lib/esm/resources/bing_geocoders.js +1 -1
  259. package/lib/esm/resources/braintree_gateways.d.ts +5 -5
  260. package/lib/esm/resources/braintree_gateways.js +1 -1
  261. package/lib/esm/resources/braintree_payments.d.ts +5 -5
  262. package/lib/esm/resources/braintree_payments.js +1 -1
  263. package/lib/esm/resources/bundles.d.ts +11 -6
  264. package/lib/esm/resources/bundles.js +1 -1
  265. package/lib/esm/resources/captures.d.ts +4 -4
  266. package/lib/esm/resources/captures.js +1 -1
  267. package/lib/esm/resources/carrier_accounts.d.ts +4 -4
  268. package/lib/esm/resources/carrier_accounts.js +1 -1
  269. package/lib/esm/resources/checkout_com_gateways.d.ts +5 -5
  270. package/lib/esm/resources/checkout_com_gateways.js +1 -1
  271. package/lib/esm/resources/checkout_com_payments.d.ts +13 -5
  272. package/lib/esm/resources/checkout_com_payments.js +1 -1
  273. package/lib/esm/resources/coupon_codes_promotion_rules.d.ts +11 -11
  274. package/lib/esm/resources/coupon_codes_promotion_rules.js +1 -1
  275. package/lib/esm/resources/coupon_recipients.d.ts +5 -5
  276. package/lib/esm/resources/coupon_recipients.js +1 -1
  277. package/lib/esm/resources/coupons.d.ts +5 -5
  278. package/lib/esm/resources/coupons.js +1 -1
  279. package/lib/esm/resources/customer_addresses.d.ts +6 -6
  280. package/lib/esm/resources/customer_addresses.js +1 -1
  281. package/lib/esm/resources/customer_groups.d.ts +4 -4
  282. package/lib/esm/resources/customer_groups.js +1 -1
  283. package/lib/esm/resources/customer_password_resets.d.ts +4 -4
  284. package/lib/esm/resources/customer_password_resets.js +1 -1
  285. package/lib/esm/resources/customer_payment_sources.d.ts +13 -13
  286. package/lib/esm/resources/customer_payment_sources.js +1 -1
  287. package/lib/esm/resources/customer_subscriptions.d.ts +4 -4
  288. package/lib/esm/resources/customer_subscriptions.js +1 -1
  289. package/lib/esm/resources/customers.d.ts +5 -5
  290. package/lib/esm/resources/customers.js +1 -1
  291. package/lib/esm/resources/delivery_lead_times.d.ts +6 -6
  292. package/lib/esm/resources/delivery_lead_times.js +1 -1
  293. package/lib/esm/resources/event_callbacks.d.ts +4 -4
  294. package/lib/esm/resources/event_callbacks.js +1 -1
  295. package/lib/esm/resources/external_gateways.d.ts +4 -4
  296. package/lib/esm/resources/external_gateways.js +1 -1
  297. package/lib/esm/resources/external_payments.d.ts +5 -5
  298. package/lib/esm/resources/external_payments.js +1 -1
  299. package/lib/esm/resources/external_promotions.d.ts +12 -9
  300. package/lib/esm/resources/external_promotions.js +1 -1
  301. package/lib/esm/resources/external_tax_calculators.d.ts +5 -5
  302. package/lib/esm/resources/external_tax_calculators.js +1 -1
  303. package/lib/esm/resources/fixed_amount_promotions.d.ts +12 -9
  304. package/lib/esm/resources/fixed_amount_promotions.js +1 -1
  305. package/lib/esm/resources/fixed_price_promotions.d.ts +13 -10
  306. package/lib/esm/resources/fixed_price_promotions.js +1 -1
  307. package/lib/esm/resources/free_gift_promotions.d.ts +13 -10
  308. package/lib/esm/resources/free_gift_promotions.js +1 -1
  309. package/lib/esm/resources/free_shipping_promotions.d.ts +12 -9
  310. package/lib/esm/resources/free_shipping_promotions.js +1 -1
  311. package/lib/esm/resources/geocoders.d.ts +4 -4
  312. package/lib/esm/resources/geocoders.js +1 -1
  313. package/lib/esm/resources/gift_card_recipients.d.ts +5 -5
  314. package/lib/esm/resources/gift_card_recipients.js +1 -1
  315. package/lib/esm/resources/gift_cards.d.ts +7 -7
  316. package/lib/esm/resources/gift_cards.js +1 -1
  317. package/lib/esm/resources/google_geocoders.d.ts +4 -4
  318. package/lib/esm/resources/google_geocoders.js +1 -1
  319. package/lib/esm/resources/imports.d.ts +4 -4
  320. package/lib/esm/resources/imports.js +1 -1
  321. package/lib/esm/resources/in_stock_subscriptions.d.ts +7 -7
  322. package/lib/esm/resources/in_stock_subscriptions.js +1 -1
  323. package/lib/esm/resources/inventory_models.d.ts +4 -4
  324. package/lib/esm/resources/inventory_models.js +1 -1
  325. package/lib/esm/resources/inventory_return_locations.d.ts +6 -6
  326. package/lib/esm/resources/inventory_return_locations.js +1 -1
  327. package/lib/esm/resources/inventory_stock_locations.d.ts +6 -6
  328. package/lib/esm/resources/inventory_stock_locations.js +1 -1
  329. package/lib/esm/resources/klarna_gateways.d.ts +5 -5
  330. package/lib/esm/resources/klarna_gateways.js +1 -1
  331. package/lib/esm/resources/klarna_payments.d.ts +5 -5
  332. package/lib/esm/resources/klarna_payments.js +1 -1
  333. package/lib/esm/resources/line_item_options.d.ts +6 -6
  334. package/lib/esm/resources/line_item_options.js +1 -1
  335. package/lib/esm/resources/line_items.d.ts +15 -15
  336. package/lib/esm/resources/line_items.js +1 -1
  337. package/lib/esm/resources/manual_gateways.d.ts +4 -4
  338. package/lib/esm/resources/manual_gateways.js +1 -1
  339. package/lib/esm/resources/manual_tax_calculators.d.ts +6 -6
  340. package/lib/esm/resources/manual_tax_calculators.js +1 -1
  341. package/lib/esm/resources/markets.d.ts +9 -9
  342. package/lib/esm/resources/markets.js +1 -1
  343. package/lib/esm/resources/merchants.d.ts +5 -5
  344. package/lib/esm/resources/merchants.js +1 -1
  345. package/lib/esm/resources/order_amount_promotion_rules.d.ts +10 -10
  346. package/lib/esm/resources/order_amount_promotion_rules.js +1 -1
  347. package/lib/esm/resources/order_copies.d.ts +5 -5
  348. package/lib/esm/resources/order_copies.js +1 -1
  349. package/lib/esm/resources/order_subscriptions.d.ts +6 -6
  350. package/lib/esm/resources/order_subscriptions.js +1 -1
  351. package/lib/esm/resources/order_validation_rules.d.ts +4 -4
  352. package/lib/esm/resources/order_validation_rules.js +1 -1
  353. package/lib/esm/resources/orders.d.ts +16 -16
  354. package/lib/esm/resources/orders.js +1 -1
  355. package/lib/esm/resources/organization.d.ts +4 -4
  356. package/lib/esm/resources/organization.js +1 -1
  357. package/lib/esm/resources/packages.d.ts +5 -5
  358. package/lib/esm/resources/packages.js +1 -1
  359. package/lib/esm/resources/parcel_line_items.d.ts +6 -6
  360. package/lib/esm/resources/parcel_line_items.js +1 -1
  361. package/lib/esm/resources/parcels.d.ts +6 -6
  362. package/lib/esm/resources/parcels.js +1 -1
  363. package/lib/esm/resources/payment_gateways.d.ts +4 -4
  364. package/lib/esm/resources/payment_gateways.js +1 -1
  365. package/lib/esm/resources/payment_methods.d.ts +10 -7
  366. package/lib/esm/resources/payment_methods.js +1 -1
  367. package/lib/esm/resources/paypal_gateways.d.ts +4 -6
  368. package/lib/esm/resources/paypal_gateways.js +1 -1
  369. package/lib/esm/resources/paypal_payments.d.ts +9 -5
  370. package/lib/esm/resources/paypal_payments.js +1 -1
  371. package/lib/esm/resources/percentage_discount_promotions.d.ts +13 -10
  372. package/lib/esm/resources/percentage_discount_promotions.js +1 -1
  373. package/lib/esm/resources/price_lists.d.ts +4 -4
  374. package/lib/esm/resources/price_lists.js +1 -1
  375. package/lib/esm/resources/prices.d.ts +6 -6
  376. package/lib/esm/resources/prices.js +1 -1
  377. package/lib/esm/resources/promotion_rules.d.ts +4 -4
  378. package/lib/esm/resources/promotion_rules.js +1 -1
  379. package/lib/esm/resources/promotions.d.ts +5 -4
  380. package/lib/esm/resources/promotions.js +1 -1
  381. package/lib/esm/resources/refunds.d.ts +4 -4
  382. package/lib/esm/resources/refunds.js +1 -1
  383. package/lib/esm/resources/return_line_items.d.ts +6 -6
  384. package/lib/esm/resources/return_line_items.js +1 -1
  385. package/lib/esm/resources/returns.d.ts +6 -6
  386. package/lib/esm/resources/returns.js +1 -1
  387. package/lib/esm/resources/shipments.d.ts +5 -5
  388. package/lib/esm/resources/shipments.js +1 -1
  389. package/lib/esm/resources/shipping_categories.d.ts +4 -4
  390. package/lib/esm/resources/shipping_categories.js +1 -1
  391. package/lib/esm/resources/shipping_methods.d.ts +11 -9
  392. package/lib/esm/resources/shipping_methods.js +1 -1
  393. package/lib/esm/resources/shipping_zones.d.ts +4 -4
  394. package/lib/esm/resources/shipping_zones.js +1 -1
  395. package/lib/esm/resources/sku_list_items.d.ts +6 -6
  396. package/lib/esm/resources/sku_list_items.js +1 -1
  397. package/lib/esm/resources/sku_list_promotion_rules.d.ts +11 -11
  398. package/lib/esm/resources/sku_list_promotion_rules.js +1 -1
  399. package/lib/esm/resources/sku_lists.d.ts +4 -4
  400. package/lib/esm/resources/sku_lists.js +1 -1
  401. package/lib/esm/resources/sku_options.d.ts +9 -6
  402. package/lib/esm/resources/sku_options.js +1 -1
  403. package/lib/esm/resources/skus.d.ts +5 -5
  404. package/lib/esm/resources/skus.js +1 -1
  405. package/lib/esm/resources/stock_items.d.ts +6 -6
  406. package/lib/esm/resources/stock_items.js +1 -1
  407. package/lib/esm/resources/stock_line_items.d.ts +4 -4
  408. package/lib/esm/resources/stock_line_items.js +1 -1
  409. package/lib/esm/resources/stock_locations.d.ts +5 -5
  410. package/lib/esm/resources/stock_locations.js +1 -1
  411. package/lib/esm/resources/stock_transfers.d.ts +8 -8
  412. package/lib/esm/resources/stock_transfers.js +1 -1
  413. package/lib/esm/resources/stripe_gateways.d.ts +4 -4
  414. package/lib/esm/resources/stripe_gateways.js +1 -1
  415. package/lib/esm/resources/stripe_payments.d.ts +9 -5
  416. package/lib/esm/resources/stripe_payments.js +1 -1
  417. package/lib/esm/resources/tax_calculators.d.ts +4 -4
  418. package/lib/esm/resources/tax_calculators.js +1 -1
  419. package/lib/esm/resources/tax_categories.d.ts +9 -9
  420. package/lib/esm/resources/tax_categories.js +1 -1
  421. package/lib/esm/resources/tax_rules.d.ts +5 -5
  422. package/lib/esm/resources/tax_rules.js +1 -1
  423. package/lib/esm/resources/taxjar_accounts.d.ts +5 -5
  424. package/lib/esm/resources/taxjar_accounts.js +1 -1
  425. package/lib/esm/resources/transactions.d.ts +4 -4
  426. package/lib/esm/resources/transactions.js +1 -1
  427. package/lib/esm/resources/voids.d.ts +4 -4
  428. package/lib/esm/resources/voids.js +1 -1
  429. package/lib/esm/resources/webhooks.d.ts +4 -4
  430. package/lib/esm/resources/webhooks.js +1 -1
  431. package/lib/esm/resources/wire_transfers.d.ts +5 -5
  432. package/lib/esm/resources/wire_transfers.js +1 -1
  433. package/lib/esm/static.js +1 -1
  434. package/lib/esm/util.d.ts +1 -3
  435. package/lib/index.d.ts +1 -0
  436. package/lib/index.js +1 -0
  437. package/lib/interceptor.d.ts +1 -0
  438. package/lib/interceptor.js +1 -0
  439. package/lib/jsonapi.d.ts +1 -0
  440. package/lib/jsonapi.js +1 -0
  441. package/lib/model.d.ts +1 -0
  442. package/lib/model.js +1 -0
  443. package/lib/query.d.ts +1 -0
  444. package/lib/query.js +1 -0
  445. package/lib/resource.d.ts +1 -0
  446. package/lib/resource.js +1 -0
  447. package/lib/resources/addresses.d.ts +1 -0
  448. package/lib/resources/addresses.js +1 -0
  449. package/lib/resources/adjustments.d.ts +1 -0
  450. package/lib/resources/adjustments.js +1 -0
  451. package/lib/resources/adyen_gateways.d.ts +1 -0
  452. package/lib/resources/adyen_gateways.js +1 -0
  453. package/lib/resources/adyen_payments.d.ts +1 -0
  454. package/lib/resources/adyen_payments.js +1 -0
  455. package/lib/resources/application.d.ts +1 -0
  456. package/lib/resources/application.js +1 -0
  457. package/lib/resources/attachments.d.ts +1 -0
  458. package/lib/resources/attachments.js +1 -0
  459. package/lib/resources/authorizations.d.ts +1 -0
  460. package/lib/resources/authorizations.js +1 -0
  461. package/lib/resources/avalara_accounts.d.ts +1 -0
  462. package/lib/resources/avalara_accounts.js +1 -0
  463. package/lib/resources/billing_info_validation_rules.d.ts +1 -0
  464. package/lib/resources/billing_info_validation_rules.js +1 -0
  465. package/lib/resources/bing_geocoders.d.ts +1 -0
  466. package/lib/resources/bing_geocoders.js +1 -0
  467. package/lib/resources/braintree_gateways.d.ts +1 -0
  468. package/lib/resources/braintree_gateways.js +1 -0
  469. package/lib/resources/braintree_payments.d.ts +1 -0
  470. package/lib/resources/braintree_payments.js +1 -0
  471. package/lib/resources/bundles.d.ts +1 -0
  472. package/lib/resources/bundles.js +1 -0
  473. package/lib/resources/captures.d.ts +1 -0
  474. package/lib/resources/captures.js +1 -0
  475. package/lib/resources/carrier_accounts.d.ts +1 -0
  476. package/lib/resources/carrier_accounts.js +1 -0
  477. package/lib/resources/checkout_com_gateways.d.ts +1 -0
  478. package/lib/resources/checkout_com_gateways.js +1 -0
  479. package/lib/resources/checkout_com_payments.d.ts +1 -0
  480. package/lib/resources/checkout_com_payments.js +1 -0
  481. package/lib/resources/coupon_codes_promotion_rules.d.ts +1 -0
  482. package/lib/resources/coupon_codes_promotion_rules.js +1 -0
  483. package/lib/resources/coupon_recipients.d.ts +1 -0
  484. package/lib/resources/coupon_recipients.js +1 -0
  485. package/lib/resources/coupons.d.ts +1 -0
  486. package/lib/resources/coupons.js +1 -0
  487. package/lib/resources/customer_addresses.d.ts +1 -0
  488. package/lib/resources/customer_addresses.js +1 -0
  489. package/lib/resources/customer_groups.d.ts +1 -0
  490. package/lib/resources/customer_groups.js +1 -0
  491. package/lib/resources/customer_password_resets.d.ts +1 -0
  492. package/lib/resources/customer_password_resets.js +1 -0
  493. package/lib/resources/customer_payment_sources.d.ts +1 -0
  494. package/lib/resources/customer_payment_sources.js +1 -0
  495. package/lib/resources/customer_subscriptions.d.ts +1 -0
  496. package/lib/resources/customer_subscriptions.js +1 -0
  497. package/lib/resources/customers.d.ts +1 -0
  498. package/lib/resources/customers.js +1 -0
  499. package/lib/resources/delivery_lead_times.d.ts +1 -0
  500. package/lib/resources/delivery_lead_times.js +1 -0
  501. package/lib/resources/event_callbacks.d.ts +1 -0
  502. package/lib/resources/event_callbacks.js +1 -0
  503. package/lib/resources/external_gateways.d.ts +1 -0
  504. package/lib/resources/external_gateways.js +1 -0
  505. package/lib/resources/external_payments.d.ts +1 -0
  506. package/lib/resources/external_payments.js +1 -0
  507. package/lib/resources/external_promotions.d.ts +1 -0
  508. package/lib/resources/external_promotions.js +1 -0
  509. package/lib/resources/external_tax_calculators.d.ts +1 -0
  510. package/lib/resources/external_tax_calculators.js +1 -0
  511. package/lib/resources/fixed_amount_promotions.d.ts +1 -0
  512. package/lib/resources/fixed_amount_promotions.js +1 -0
  513. package/lib/resources/fixed_price_promotions.d.ts +1 -0
  514. package/lib/resources/fixed_price_promotions.js +1 -0
  515. package/lib/resources/free_gift_promotions.d.ts +1 -0
  516. package/lib/resources/free_gift_promotions.js +1 -0
  517. package/lib/resources/free_shipping_promotions.d.ts +1 -0
  518. package/lib/resources/free_shipping_promotions.js +1 -0
  519. package/lib/resources/geocoders.d.ts +1 -0
  520. package/lib/resources/geocoders.js +1 -0
  521. package/lib/resources/gift_card_recipients.d.ts +1 -0
  522. package/lib/resources/gift_card_recipients.js +1 -0
  523. package/lib/resources/gift_cards.d.ts +1 -0
  524. package/lib/resources/gift_cards.js +1 -0
  525. package/lib/resources/google_geocoders.d.ts +1 -0
  526. package/lib/resources/google_geocoders.js +1 -0
  527. package/lib/resources/imports.d.ts +1 -0
  528. package/lib/resources/imports.js +1 -0
  529. package/lib/resources/in_stock_subscriptions.d.ts +1 -0
  530. package/lib/resources/in_stock_subscriptions.js +1 -0
  531. package/lib/resources/inventory_models.d.ts +1 -0
  532. package/lib/resources/inventory_models.js +1 -0
  533. package/lib/resources/inventory_return_locations.d.ts +1 -0
  534. package/lib/resources/inventory_return_locations.js +1 -0
  535. package/lib/resources/inventory_stock_locations.d.ts +1 -0
  536. package/lib/resources/inventory_stock_locations.js +1 -0
  537. package/lib/resources/klarna_gateways.d.ts +1 -0
  538. package/lib/resources/klarna_gateways.js +1 -0
  539. package/lib/resources/klarna_payments.d.ts +1 -0
  540. package/lib/resources/klarna_payments.js +1 -0
  541. package/lib/resources/line_item_options.d.ts +1 -0
  542. package/lib/resources/line_item_options.js +1 -0
  543. package/lib/resources/line_items.d.ts +1 -0
  544. package/lib/resources/line_items.js +1 -0
  545. package/lib/resources/manual_gateways.d.ts +1 -0
  546. package/lib/resources/manual_gateways.js +1 -0
  547. package/lib/resources/manual_tax_calculators.d.ts +1 -0
  548. package/lib/resources/manual_tax_calculators.js +1 -0
  549. package/lib/resources/markets.d.ts +1 -0
  550. package/lib/resources/markets.js +1 -0
  551. package/lib/resources/merchants.d.ts +1 -0
  552. package/lib/resources/merchants.js +1 -0
  553. package/lib/resources/order_amount_promotion_rules.d.ts +1 -0
  554. package/lib/resources/order_amount_promotion_rules.js +1 -0
  555. package/lib/resources/order_copies.d.ts +1 -0
  556. package/lib/resources/order_copies.js +1 -0
  557. package/lib/resources/order_subscriptions.d.ts +1 -0
  558. package/lib/resources/order_subscriptions.js +1 -0
  559. package/lib/resources/order_validation_rules.d.ts +1 -0
  560. package/lib/resources/order_validation_rules.js +1 -0
  561. package/lib/resources/orders.d.ts +1 -0
  562. package/lib/resources/orders.js +1 -0
  563. package/lib/resources/organization.d.ts +1 -0
  564. package/lib/resources/organization.js +1 -0
  565. package/lib/resources/packages.d.ts +1 -0
  566. package/lib/resources/packages.js +1 -0
  567. package/lib/resources/parcel_line_items.d.ts +1 -0
  568. package/lib/resources/parcel_line_items.js +1 -0
  569. package/lib/resources/parcels.d.ts +1 -0
  570. package/lib/resources/parcels.js +1 -0
  571. package/lib/resources/payment_gateways.d.ts +1 -0
  572. package/lib/resources/payment_gateways.js +1 -0
  573. package/lib/resources/payment_methods.d.ts +1 -0
  574. package/lib/resources/payment_methods.js +1 -0
  575. package/lib/resources/paypal_gateways.d.ts +1 -0
  576. package/lib/resources/paypal_gateways.js +1 -0
  577. package/lib/resources/paypal_payments.d.ts +1 -0
  578. package/lib/resources/paypal_payments.js +1 -0
  579. package/lib/resources/percentage_discount_promotions.d.ts +1 -0
  580. package/lib/resources/percentage_discount_promotions.js +1 -0
  581. package/lib/resources/price_lists.d.ts +1 -0
  582. package/lib/resources/price_lists.js +1 -0
  583. package/lib/resources/prices.d.ts +1 -0
  584. package/lib/resources/prices.js +1 -0
  585. package/lib/resources/promotion_rules.d.ts +1 -0
  586. package/lib/resources/promotion_rules.js +1 -0
  587. package/lib/resources/promotions.d.ts +1 -0
  588. package/lib/resources/promotions.js +1 -0
  589. package/lib/resources/refunds.d.ts +1 -0
  590. package/lib/resources/refunds.js +1 -0
  591. package/lib/resources/return_line_items.d.ts +1 -0
  592. package/lib/resources/return_line_items.js +1 -0
  593. package/lib/resources/returns.d.ts +1 -0
  594. package/lib/resources/returns.js +1 -0
  595. package/lib/resources/shipments.d.ts +1 -0
  596. package/lib/resources/shipments.js +1 -0
  597. package/lib/resources/shipping_categories.d.ts +1 -0
  598. package/lib/resources/shipping_categories.js +1 -0
  599. package/lib/resources/shipping_methods.d.ts +1 -0
  600. package/lib/resources/shipping_methods.js +1 -0
  601. package/lib/resources/shipping_zones.d.ts +1 -0
  602. package/lib/resources/shipping_zones.js +1 -0
  603. package/lib/resources/sku_list_items.d.ts +1 -0
  604. package/lib/resources/sku_list_items.js +1 -0
  605. package/lib/resources/sku_list_promotion_rules.d.ts +1 -0
  606. package/lib/resources/sku_list_promotion_rules.js +1 -0
  607. package/lib/resources/sku_lists.d.ts +1 -0
  608. package/lib/resources/sku_lists.js +1 -0
  609. package/lib/resources/sku_options.d.ts +1 -0
  610. package/lib/resources/sku_options.js +1 -0
  611. package/lib/resources/skus.d.ts +1 -0
  612. package/lib/resources/skus.js +1 -0
  613. package/lib/resources/stock_items.d.ts +1 -0
  614. package/lib/resources/stock_items.js +1 -0
  615. package/lib/resources/stock_line_items.d.ts +1 -0
  616. package/lib/resources/stock_line_items.js +1 -0
  617. package/lib/resources/stock_locations.d.ts +1 -0
  618. package/lib/resources/stock_locations.js +1 -0
  619. package/lib/resources/stock_transfers.d.ts +1 -0
  620. package/lib/resources/stock_transfers.js +1 -0
  621. package/lib/resources/stripe_gateways.d.ts +1 -0
  622. package/lib/resources/stripe_gateways.js +1 -0
  623. package/lib/resources/stripe_payments.d.ts +1 -0
  624. package/lib/resources/stripe_payments.js +1 -0
  625. package/lib/resources/tax_calculators.d.ts +1 -0
  626. package/lib/resources/tax_calculators.js +1 -0
  627. package/lib/resources/tax_categories.d.ts +1 -0
  628. package/lib/resources/tax_categories.js +1 -0
  629. package/lib/resources/tax_rules.d.ts +1 -0
  630. package/lib/resources/tax_rules.js +1 -0
  631. package/lib/resources/taxjar_accounts.d.ts +1 -0
  632. package/lib/resources/taxjar_accounts.js +1 -0
  633. package/lib/resources/transactions.d.ts +1 -0
  634. package/lib/resources/transactions.js +1 -0
  635. package/lib/resources/voids.d.ts +1 -0
  636. package/lib/resources/voids.js +1 -0
  637. package/lib/resources/webhooks.d.ts +1 -0
  638. package/lib/resources/webhooks.js +1 -0
  639. package/lib/resources/wire_transfers.d.ts +1 -0
  640. package/lib/resources/wire_transfers.js +1 -0
  641. package/lib/static.d.ts +1 -0
  642. package/lib/static.js +1 -0
  643. package/lib/tsconfig.esm.tsbuildinfo +1 -1
  644. package/lib/tsconfig.tsbuildinfo +1 -1
  645. package/lib/util.d.ts +2 -0
  646. package/lib/util.js +1 -0
  647. package/package.json +1 -1
@@ -0,0 +1 @@
1
+ import{ApiResource as u}from"../resource";class t extends u{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update({...e,type:t.TYPE},r,s)}async order(e,r,s){return this.resources.fetch({type:"orders"},`captures/${e}/order`,r,s)}async reference_authorization(e,r,s){return this.resources.fetch({type:"authorizations"},`captures/${e}/reference_authorization`,r,s)}async refunds(e,r,s){return this.resources.fetch({type:"refunds"},`captures/${e}/refunds`,r,s)}isCapture(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="captures";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{Attachment}from'./attachments';declare type CarrierAccountRel=ResourceRel&{type:typeof CarrierAccounts.TYPE;};interface CarrierAccount extends Resource{name?:string;easypost_type?:string;easypost_id?:string;market?:Market;attachments?:Attachment[];}declare class CarrierAccounts extends ApiResource{static readonly TYPE:'carrier_accounts';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CarrierAccount>>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CarrierAccount>;market(carrierAccountId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;attachments(carrierAccountId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isCarrierAccount(resource:any):resource is CarrierAccount;relationship(id:string|ResourceId|null):CarrierAccountRel;type():string;}export default CarrierAccounts;export{CarrierAccount};
@@ -0,0 +1 @@
1
+ import{ApiResource as c}from"../resource";class e extends c{async list(t,r){return this.resources.list({type:e.TYPE},t,r)}async retrieve(t,r,s){return this.resources.retrieve({type:e.TYPE,id:t},r,s)}async market(t,r,s){return this.resources.fetch({type:"markets"},`carrier_accounts/${t}/market`,r,s)}async attachments(t,r,s){return this.resources.fetch({type:"attachments"},`carrier_accounts/${t}/attachments`,r,s)}isCarrierAccount(t){return t.type&&t.type===e.TYPE}relationship(t){return t===null||typeof t=="string"?{id:t,type:e.TYPE}:{id:t.id,type:e.TYPE}}type(){return e.TYPE}}e.TYPE="carrier_accounts";export default e;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{PaymentMethod}from'./payment_methods';import{CheckoutComPayment}from'./checkout_com_payments';declare type CheckoutComGatewayRel=ResourceRel&{type:typeof CheckoutComGateways.TYPE;};declare type CheckoutComPaymentRel=ResourceRel&{type:'checkout_com_payments';};interface CheckoutComGateway extends Resource{name?:string;webhook_endpoint_id?:string;webhook_endpoint_secret?:string;webhook_endpoint_url?:string;payment_methods?:PaymentMethod[];checkout_com_payments?:CheckoutComPayment[];}interface CheckoutComGatewayCreate extends ResourceCreate{name:string;secret_key:string;public_key:string;checkout_com_payments?:CheckoutComPaymentRel[];}interface CheckoutComGatewayUpdate extends ResourceUpdate{name?:string;secret_key?:string;public_key?:string;checkout_com_payments?:CheckoutComPaymentRel[];}declare class CheckoutComGateways extends ApiResource{static readonly TYPE:'checkout_com_gateways';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CheckoutComGateway>>;create(resource:CheckoutComGatewayCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CheckoutComGateway>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CheckoutComGateway>;update(resource:CheckoutComGatewayUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CheckoutComGateway>;delete(id:string,options?:ResourcesConfig):Promise<void>;payment_methods(checkoutComGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;checkout_com_payments(checkoutComGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CheckoutComPayment>>;isCheckoutComGateway(resource:any):resource is CheckoutComGateway;relationship(id:string|ResourceId|null):CheckoutComGatewayRel;type():string;}export default CheckoutComGateways;export{CheckoutComGateway,CheckoutComGatewayCreate,CheckoutComGatewayUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class r extends s{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,c){return this.resources.create({...e,type:r.TYPE},t,c)}async retrieve(e,t,c){return this.resources.retrieve({type:r.TYPE,id:e},t,c)}async update(e,t,c){return this.resources.update({...e,type:r.TYPE},t,c)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async payment_methods(e,t,c){return this.resources.fetch({type:"payment_methods"},`checkout_com_gateways/${e}/payment_methods`,t,c)}async checkout_com_payments(e,t,c){return this.resources.fetch({type:"checkout_com_payments"},`checkout_com_gateways/${e}/checkout_com_payments`,t,c)}isCheckoutComGateway(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="checkout_com_gateways";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Order}from'./orders';import{PaymentGateway}from'./payment_gateways';declare type CheckoutComPaymentRel=ResourceRel&{type:typeof CheckoutComPayments.TYPE;};declare type OrderRel=ResourceRel&{type:'orders';};interface CheckoutComPayment extends Resource{payment_type?:string;token?:string;session_id?:string;source_id?:string;customer_token?:string;redirect_uri?:string;payment_response?:object;order?:Order;payment_gateway?:PaymentGateway;}interface CheckoutComPaymentCreate extends ResourceCreate{payment_type:string;token:string;session_id?:string;order:OrderRel;}interface CheckoutComPaymentUpdate extends ResourceUpdate{payment_type?:string;token?:string;session_id?:string;_details?:boolean;_refresh?:boolean;order?:OrderRel;}declare class CheckoutComPayments extends ApiResource{static readonly TYPE:'checkout_com_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CheckoutComPayment>>;create(resource:CheckoutComPaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CheckoutComPayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CheckoutComPayment>;update(resource:CheckoutComPaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CheckoutComPayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(checkoutComPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(checkoutComPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;isCheckoutComPayment(resource:any):resource is CheckoutComPayment;relationship(id:string|ResourceId|null):CheckoutComPaymentRel;type():string;}export default CheckoutComPayments;export{CheckoutComPayment,CheckoutComPaymentCreate,CheckoutComPaymentUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async order(e,t,r){return this.resources.fetch({type:"orders"},`checkout_com_payments/${e}/order`,t,r)}async payment_gateway(e,t,r){return this.resources.fetch({type:"payment_gateways"},`checkout_com_payments/${e}/payment_gateway`,t,r)}isCheckoutComPayment(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="checkout_com_payments";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{PercentageDiscountPromotion}from'./percentage_discount_promotions';import{FreeShippingPromotion}from'./free_shipping_promotions';import{FixedAmountPromotion}from'./fixed_amount_promotions';import{FreeGiftPromotion}from'./free_gift_promotions';import{FixedPricePromotion}from'./fixed_price_promotions';import{ExternalPromotion}from'./external_promotions';import{Coupon}from'./coupons';declare type CouponCodesPromotionRuleRel=ResourceRel&{type:typeof CouponCodesPromotionRules.TYPE;};declare type PercentageDiscountPromotionRel=ResourceRel&{type:'percentage_discount_promotions';};declare type FreeShippingPromotionRel=ResourceRel&{type:'free_shipping_promotions';};declare type FixedAmountPromotionRel=ResourceRel&{type:'fixed_amount_promotions';};declare type FreeGiftPromotionRel=ResourceRel&{type:'free_gift_promotions';};declare type FixedPricePromotionRel=ResourceRel&{type:'fixed_price_promotions';};declare type ExternalPromotionRel=ResourceRel&{type:'external_promotions';};declare type CouponRel=ResourceRel&{type:'coupons';};interface CouponCodesPromotionRule extends Resource{promotion?:PercentageDiscountPromotion|FreeShippingPromotion|FixedAmountPromotion|FreeGiftPromotion|FixedPricePromotion|ExternalPromotion;coupons?:Coupon[];}interface CouponCodesPromotionRuleCreate extends ResourceCreate{promotion:PercentageDiscountPromotionRel|FreeShippingPromotionRel|FixedAmountPromotionRel|FreeGiftPromotionRel|FixedPricePromotionRel|ExternalPromotionRel;coupons?:CouponRel[];}interface CouponCodesPromotionRuleUpdate extends ResourceUpdate{promotion?:PercentageDiscountPromotionRel|FreeShippingPromotionRel|FixedAmountPromotionRel|FreeGiftPromotionRel|FixedPricePromotionRel|ExternalPromotionRel;coupons?:CouponRel[];}declare class CouponCodesPromotionRules extends ApiResource{static readonly TYPE:'coupon_codes_promotion_rules';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CouponCodesPromotionRule>>;create(resource:CouponCodesPromotionRuleCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;update(resource:CouponCodesPromotionRuleUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;delete(id:string,options?:ResourcesConfig):Promise<void>;coupons(couponCodesPromotionRuleId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Coupon>>;isCouponCodesPromotionRule(resource:any):resource is CouponCodesPromotionRule;relationship(id:string|ResourceId|null):CouponCodesPromotionRuleRel;type():string;}export default CouponCodesPromotionRules;export{CouponCodesPromotionRule,CouponCodesPromotionRuleCreate,CouponCodesPromotionRuleUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as r}from"../resource";class t extends r{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,o){return this.resources.create({...e,type:t.TYPE},s,o)}async retrieve(e,s,o){return this.resources.retrieve({type:t.TYPE,id:e},s,o)}async update(e,s,o){return this.resources.update({...e,type:t.TYPE},s,o)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}async coupons(e,s,o){return this.resources.fetch({type:"coupons"},`coupon_codes_promotion_rules/${e}/coupons`,s,o)}isCouponCodesPromotionRule(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="coupon_codes_promotion_rules";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';import{Attachment}from'./attachments';declare type CouponRecipientRel=ResourceRel&{type:typeof CouponRecipients.TYPE;};declare type CustomerRel=ResourceRel&{type:'customers';};interface CouponRecipient extends Resource{email?:string;first_name?:string;last_name?:string;customer?:Customer;attachments?:Attachment[];}interface CouponRecipientCreate extends ResourceCreate{email:string;first_name?:string;last_name?:string;customer?:CustomerRel;}interface CouponRecipientUpdate extends ResourceUpdate{email?:string;first_name?:string;last_name?:string;customer?:CustomerRel;}declare class CouponRecipients extends ApiResource{static readonly TYPE:'coupon_recipients';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CouponRecipient>>;create(resource:CouponRecipientCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponRecipient>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponRecipient>;update(resource:CouponRecipientUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponRecipient>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer(couponRecipientId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;attachments(couponRecipientId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isCouponRecipient(resource:any):resource is CouponRecipient;relationship(id:string|ResourceId|null):CouponRecipientRel;type():string;}export default CouponRecipients;export{CouponRecipient,CouponRecipientCreate,CouponRecipientUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as c}from"../resource";class r extends c{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async customer(e,t,s){return this.resources.fetch({type:"customers"},`coupon_recipients/${e}/customer`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`coupon_recipients/${e}/attachments`,t,s)}isCouponRecipient(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="coupon_recipients";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{CouponCodesPromotionRule}from'./coupon_codes_promotion_rules';declare type CouponRel=ResourceRel&{type:typeof Coupons.TYPE;};declare type CouponCodesPromotionRuleRel=ResourceRel&{type:'coupon_codes_promotion_rules';};interface Coupon extends Resource{code?:string;customer_single_use?:boolean;usage_limit?:number;usage_count?:number;recipient_email?:string;promotion_rule?:CouponCodesPromotionRule;}interface CouponCreate extends ResourceCreate{code:string;customer_single_use?:boolean;usage_limit:number;recipient_email?:string;promotion_rule:CouponCodesPromotionRuleRel;}interface CouponUpdate extends ResourceUpdate{code?:string;customer_single_use?:boolean;usage_limit?:number;recipient_email?:string;promotion_rule?:CouponCodesPromotionRuleRel;}declare class Coupons extends ApiResource{static readonly TYPE:'coupons';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Coupon>>;create(resource:CouponCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Coupon>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Coupon>;update(resource:CouponUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Coupon>;delete(id:string,options?:ResourcesConfig):Promise<void>;promotion_rule(couponId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;isCoupon(resource:any):resource is Coupon;relationship(id:string|ResourceId|null):CouponRel;type():string;}export default Coupons;export{Coupon,CouponCreate,CouponUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as o}from"../resource";class t extends o{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create({...e,type:t.TYPE},r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update({...e,type:t.TYPE},r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}async promotion_rule(e,r,s){return this.resources.fetch({type:"coupon_codes_promotion_rules"},`coupons/${e}/promotion_rule`,r,s)}isCoupon(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="coupons";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';import{Address}from'./addresses';declare type CustomerAddressRel=ResourceRel&{type:typeof CustomerAddresses.TYPE;};declare type CustomerRel=ResourceRel&{type:'customers';};declare type AddressRel=ResourceRel&{type:'addresses';};interface CustomerAddress extends Resource{name?:string;customer?:Customer;address?:Address;}interface CustomerAddressCreate extends ResourceCreate{customer:CustomerRel;address:AddressRel;}interface CustomerAddressUpdate extends ResourceUpdate{customer?:CustomerRel;address?:AddressRel;}declare class CustomerAddresses extends ApiResource{static readonly TYPE:'customer_addresses';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerAddress>>;create(resource:CustomerAddressCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerAddress>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerAddress>;update(resource:CustomerAddressUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerAddress>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer(customerAddressId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;address(customerAddressId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;isCustomerAddress(resource:any):resource is CustomerAddress;relationship(id:string|ResourceId|null):CustomerAddressRel;type():string;}export default CustomerAddresses;export{CustomerAddress,CustomerAddressCreate,CustomerAddressUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as u}from"../resource";class r extends u{async list(e,s){return this.resources.list({type:r.TYPE},e,s)}async create(e,s,t){return this.resources.create({...e,type:r.TYPE},s,t)}async retrieve(e,s,t){return this.resources.retrieve({type:r.TYPE,id:e},s,t)}async update(e,s,t){return this.resources.update({...e,type:r.TYPE},s,t)}async delete(e,s){await this.resources.delete({type:r.TYPE,id:e},s)}async customer(e,s,t){return this.resources.fetch({type:"customers"},`customer_addresses/${e}/customer`,s,t)}async address(e,s,t){return this.resources.fetch({type:"addresses"},`customer_addresses/${e}/address`,s,t)}isCustomerAddress(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="customer_addresses";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';import{Market}from'./markets';import{Attachment}from'./attachments';declare type CustomerGroupRel=ResourceRel&{type:typeof CustomerGroups.TYPE;};interface CustomerGroup extends Resource{name?:string;customers?:Customer[];markets?:Market[];attachments?:Attachment[];}interface CustomerGroupCreate extends ResourceCreate{name:string;}interface CustomerGroupUpdate extends ResourceUpdate{name?:string;}declare class CustomerGroups extends ApiResource{static readonly TYPE:'customer_groups';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerGroup>>;create(resource:CustomerGroupCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerGroup>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerGroup>;update(resource:CustomerGroupUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerGroup>;delete(id:string,options?:ResourcesConfig):Promise<void>;customers(customerGroupId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Customer>>;markets(customerGroupId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Market>>;attachments(customerGroupId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isCustomerGroup(resource:any):resource is CustomerGroup;relationship(id:string|ResourceId|null):CustomerGroupRel;type():string;}export default CustomerGroups;export{CustomerGroup,CustomerGroupCreate,CustomerGroupUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as u}from"../resource";class r extends u{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async customers(e,t,s){return this.resources.fetch({type:"customers"},`customer_groups/${e}/customers`,t,s)}async markets(e,t,s){return this.resources.fetch({type:"markets"},`customer_groups/${e}/markets`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`customer_groups/${e}/attachments`,t,s)}isCustomerGroup(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="customer_groups";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';declare type CustomerPasswordResetRel=ResourceRel&{type:typeof CustomerPasswordResets.TYPE;};interface CustomerPasswordReset extends Resource{customer_email?:string;reset_password_token?:string;reset_password_at?:string;customer?:Customer;}interface CustomerPasswordResetCreate extends ResourceCreate{customer_email:string;}interface CustomerPasswordResetUpdate extends ResourceUpdate{customer_password?:string;_reset_password_token?:string;}declare class CustomerPasswordResets extends ApiResource{static readonly TYPE:'customer_password_resets';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPasswordReset>>;create(resource:CustomerPasswordResetCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPasswordReset>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPasswordReset>;update(resource:CustomerPasswordResetUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPasswordReset>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer(customerPasswordResetId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;isCustomerPasswordReset(resource:any):resource is CustomerPasswordReset;relationship(id:string|ResourceId|null):CustomerPasswordResetRel;type():string;}export default CustomerPasswordResets;export{CustomerPasswordReset,CustomerPasswordResetCreate,CustomerPasswordResetUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as u}from"../resource";class t extends u{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create({...e,type:t.TYPE},r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update({...e,type:t.TYPE},r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}async customer(e,r,s){return this.resources.fetch({type:"customers"},`customer_password_resets/${e}/customer`,r,s)}isCustomerPasswordReset(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="customer_password_resets";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';import{AdyenPayment}from'./adyen_payments';import{BraintreePayment}from'./braintree_payments';import{CheckoutComPayment}from'./checkout_com_payments';import{ExternalPayment}from'./external_payments';import{KlarnaPayment}from'./klarna_payments';import{PaypalPayment}from'./paypal_payments';import{StripePayment}from'./stripe_payments';import{WireTransfer}from'./wire_transfers';declare type CustomerPaymentSourceRel=ResourceRel&{type:typeof CustomerPaymentSources.TYPE;};declare type CustomerRel=ResourceRel&{type:'customers';};declare type AdyenPaymentRel=ResourceRel&{type:'adyen_payments';};declare type BraintreePaymentRel=ResourceRel&{type:'braintree_payments';};declare type CheckoutComPaymentRel=ResourceRel&{type:'checkout_com_payments';};declare type ExternalPaymentRel=ResourceRel&{type:'external_payments';};declare type KlarnaPaymentRel=ResourceRel&{type:'klarna_payments';};declare type PaypalPaymentRel=ResourceRel&{type:'paypal_payments';};declare type StripePaymentRel=ResourceRel&{type:'stripe_payments';};declare type WireTransferRel=ResourceRel&{type:'wire_transfers';};interface CustomerPaymentSource extends Resource{name?:string;customer_token?:string;payment_source_token?:string;customer?:Customer;payment_source?:AdyenPayment|BraintreePayment|CheckoutComPayment|ExternalPayment|KlarnaPayment|PaypalPayment|StripePayment|WireTransfer;}interface CustomerPaymentSourceCreate extends ResourceCreate{customer:CustomerRel;payment_source:AdyenPaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|StripePaymentRel|WireTransferRel;}interface CustomerPaymentSourceUpdate extends ResourceUpdate{customer?:CustomerRel;payment_source?:AdyenPaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|StripePaymentRel|WireTransferRel;}declare class CustomerPaymentSources extends ApiResource{static readonly TYPE:'customer_payment_sources';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPaymentSource>>;create(resource:CustomerPaymentSourceCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;update(resource:CustomerPaymentSourceUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer(customerPaymentSourceId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;isCustomerPaymentSource(resource:any):resource is CustomerPaymentSource;relationship(id:string|ResourceId|null):CustomerPaymentSourceRel;type():string;}export default CustomerPaymentSources;export{CustomerPaymentSource,CustomerPaymentSourceCreate,CustomerPaymentSourceUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as u}from"../resource";class t extends u{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create({...e,type:t.TYPE},s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update({...e,type:t.TYPE},s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}async customer(e,s,r){return this.resources.fetch({type:"customers"},`customer_payment_sources/${e}/customer`,s,r)}isCustomerPaymentSource(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="customer_payment_sources";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';declare type CustomerSubscriptionRel=ResourceRel&{type:typeof CustomerSubscriptions.TYPE;};interface CustomerSubscription extends Resource{customer_email?:string;customer?:Customer;}interface CustomerSubscriptionCreate extends ResourceCreate{customer_email:string;}declare type CustomerSubscriptionUpdate=ResourceUpdate;declare class CustomerSubscriptions extends ApiResource{static readonly TYPE:'customer_subscriptions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerSubscription>>;create(resource:CustomerSubscriptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerSubscription>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerSubscription>;update(resource:CustomerSubscriptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerSubscription>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer(customerSubscriptionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;isCustomerSubscription(resource:any):resource is CustomerSubscription;relationship(id:string|ResourceId|null):CustomerSubscriptionRel;type():string;}export default CustomerSubscriptions;export{CustomerSubscription,CustomerSubscriptionCreate,CustomerSubscriptionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create({...e,type:t.TYPE},s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update({...e,type:t.TYPE},s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}async customer(e,s,r){return this.resources.fetch({type:"customers"},`customer_subscriptions/${e}/customer`,s,r)}isCustomerSubscription(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="customer_subscriptions";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{CustomerGroup}from'./customer_groups';import{CustomerAddress}from'./customer_addresses';import{CustomerPaymentSource}from'./customer_payment_sources';import{CustomerSubscription}from'./customer_subscriptions';import{Order}from'./orders';import{OrderSubscription}from'./order_subscriptions';import{Return}from'./returns';import{Attachment}from'./attachments';declare type CustomerRel=ResourceRel&{type:typeof Customers.TYPE;};declare type CustomerGroupRel=ResourceRel&{type:'customer_groups';};interface Customer extends Resource{email?:string;status?:string;has_password?:boolean;customer_group?:CustomerGroup;customer_addresses?:CustomerAddress[];customer_payment_sources?:CustomerPaymentSource[];customer_subscriptions?:CustomerSubscription[];orders?:Order[];order_subscriptions?:OrderSubscription[];returns?:Return[];attachments?:Attachment[];}interface CustomerCreate extends ResourceCreate{email:string;password?:string;customer_group?:CustomerGroupRel;}interface CustomerUpdate extends ResourceUpdate{email?:string;password?:string;customer_group?:CustomerGroupRel;}declare class Customers extends ApiResource{static readonly TYPE:'customers';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Customer>>;create(resource:CustomerCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;update(resource:CustomerUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer_group(customerId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerGroup>;customer_addresses(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerAddress>>;customer_payment_sources(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPaymentSource>>;customer_subscriptions(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerSubscription>>;orders(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;order_subscriptions(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;returns(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Return>>;attachments(customerId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isCustomer(resource:any):resource is Customer;relationship(id:string|ResourceId|null):CustomerRel;type():string;}export default Customers;export{Customer,CustomerCreate,CustomerUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as c}from"../resource";class t extends c{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async create(e,s,r){return this.resources.create({...e,type:t.TYPE},s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update({...e,type:t.TYPE},s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}async customer_group(e,s,r){return this.resources.fetch({type:"customer_groups"},`customers/${e}/customer_group`,s,r)}async customer_addresses(e,s,r){return this.resources.fetch({type:"customer_addresses"},`customers/${e}/customer_addresses`,s,r)}async customer_payment_sources(e,s,r){return this.resources.fetch({type:"customer_payment_sources"},`customers/${e}/customer_payment_sources`,s,r)}async customer_subscriptions(e,s,r){return this.resources.fetch({type:"customer_subscriptions"},`customers/${e}/customer_subscriptions`,s,r)}async orders(e,s,r){return this.resources.fetch({type:"orders"},`customers/${e}/orders`,s,r)}async order_subscriptions(e,s,r){return this.resources.fetch({type:"order_subscriptions"},`customers/${e}/order_subscriptions`,s,r)}async returns(e,s,r){return this.resources.fetch({type:"returns"},`customers/${e}/returns`,s,r)}async attachments(e,s,r){return this.resources.fetch({type:"attachments"},`customers/${e}/attachments`,s,r)}isCustomer(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="customers";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{StockLocation}from'./stock_locations';import{ShippingMethod}from'./shipping_methods';import{Attachment}from'./attachments';declare type DeliveryLeadTimeRel=ResourceRel&{type:typeof DeliveryLeadTimes.TYPE;};declare type StockLocationRel=ResourceRel&{type:'stock_locations';};declare type ShippingMethodRel=ResourceRel&{type:'shipping_methods';};interface DeliveryLeadTime extends Resource{min_hours?:number;max_hours?:number;min_days?:number;max_days?:number;stock_location?:StockLocation;shipping_method?:ShippingMethod;attachments?:Attachment[];}interface DeliveryLeadTimeCreate extends ResourceCreate{min_hours:number;max_hours:number;stock_location:StockLocationRel;shipping_method:ShippingMethodRel;}interface DeliveryLeadTimeUpdate extends ResourceUpdate{min_hours?:number;max_hours?:number;stock_location?:StockLocationRel;shipping_method?:ShippingMethodRel;}declare class DeliveryLeadTimes extends ApiResource{static readonly TYPE:'delivery_lead_times';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<DeliveryLeadTime>>;create(resource:DeliveryLeadTimeCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;update(resource:DeliveryLeadTimeUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;delete(id:string,options?:ResourcesConfig):Promise<void>;stock_location(deliveryLeadTimeId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;shipping_method(deliveryLeadTimeId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingMethod>;attachments(deliveryLeadTimeId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isDeliveryLeadTime(resource:any):resource is DeliveryLeadTime;relationship(id:string|ResourceId|null):DeliveryLeadTimeRel;type():string;}export default DeliveryLeadTimes;export{DeliveryLeadTime,DeliveryLeadTimeCreate,DeliveryLeadTimeUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class s extends i{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async stock_location(e,t,r){return this.resources.fetch({type:"stock_locations"},`delivery_lead_times/${e}/stock_location`,t,r)}async shipping_method(e,t,r){return this.resources.fetch({type:"shipping_methods"},`delivery_lead_times/${e}/shipping_method`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`delivery_lead_times/${e}/attachments`,t,r)}isDeliveryLeadTime(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="delivery_lead_times";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Webhook}from'./webhooks';declare type EventCallbackRel=ResourceRel&{type:typeof EventCallbacks.TYPE;};interface EventCallback extends Resource{callback_url?:string;payload?:object;response_code?:string;response_message?:string;webhook?:Webhook;}declare class EventCallbacks extends ApiResource{static readonly TYPE:'event_callbacks';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<EventCallback>>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<EventCallback>;webhook(eventCallbackId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Webhook>;isEventCallback(resource:any):resource is EventCallback;relationship(id:string|ResourceId|null):EventCallbackRel;type():string;}export default EventCallbacks;export{EventCallback};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class t extends i{async list(e,s){return this.resources.list({type:t.TYPE},e,s)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async webhook(e,s,r){return this.resources.fetch({type:"webhooks"},`event_callbacks/${e}/webhook`,s,r)}isEventCallback(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="event_callbacks";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{PaymentMethod}from'./payment_methods';import{ExternalPayment}from'./external_payments';declare type ExternalGatewayRel=ResourceRel&{type:typeof ExternalGateways.TYPE;};interface ExternalGateway extends Resource{name?:string;shared_secret?:string;authorize_url?:string;capture_url?:string;void_url?:string;refund_url?:string;token_url?:string;payment_methods?:PaymentMethod[];external_payments?:ExternalPayment[];}interface ExternalGatewayCreate extends ResourceCreate{name:string;authorize_url?:string;capture_url?:string;void_url?:string;refund_url?:string;token_url?:string;}interface ExternalGatewayUpdate extends ResourceUpdate{name?:string;authorize_url?:string;capture_url?:string;void_url?:string;refund_url?:string;token_url?:string;}declare class ExternalGateways extends ApiResource{static readonly TYPE:'external_gateways';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ExternalGateway>>;create(resource:ExternalGatewayCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalGateway>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalGateway>;update(resource:ExternalGatewayUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalGateway>;delete(id:string,options?:ResourcesConfig):Promise<void>;payment_methods(externalGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;external_payments(externalGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ExternalPayment>>;isExternalGateway(resource:any):resource is ExternalGateway;relationship(id:string|ResourceId|null):ExternalGatewayRel;type():string;}export default ExternalGateways;export{ExternalGateway,ExternalGatewayCreate,ExternalGatewayUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class r extends s{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,a){return this.resources.create({...e,type:r.TYPE},t,a)}async retrieve(e,t,a){return this.resources.retrieve({type:r.TYPE,id:e},t,a)}async update(e,t,a){return this.resources.update({...e,type:r.TYPE},t,a)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async payment_methods(e,t,a){return this.resources.fetch({type:"payment_methods"},`external_gateways/${e}/payment_methods`,t,a)}async external_payments(e,t,a){return this.resources.fetch({type:"external_payments"},`external_gateways/${e}/external_payments`,t,a)}isExternalGateway(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="external_gateways";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Order}from'./orders';import{PaymentGateway}from'./payment_gateways';import{CustomerPaymentSource}from'./customer_payment_sources';declare type ExternalPaymentRel=ResourceRel&{type:typeof ExternalPayments.TYPE;};declare type OrderRel=ResourceRel&{type:'orders';};interface ExternalPayment extends Resource{payment_source_token?:string;options?:object;order?:Order;payment_gateway?:PaymentGateway;wallet?:CustomerPaymentSource;}interface ExternalPaymentCreate extends ResourceCreate{payment_source_token:string;options?:object;order:OrderRel;}interface ExternalPaymentUpdate extends ResourceUpdate{options?:object;order?:OrderRel;}declare class ExternalPayments extends ApiResource{static readonly TYPE:'external_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ExternalPayment>>;create(resource:ExternalPaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalPayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalPayment>;update(resource:ExternalPaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalPayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(externalPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(externalPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;wallet(externalPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;isExternalPayment(resource:any):resource is ExternalPayment;relationship(id:string|ResourceId|null):ExternalPaymentRel;type():string;}export default ExternalPayments;export{ExternalPayment,ExternalPaymentCreate,ExternalPaymentUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as a}from"../resource";class r extends a{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async order(e,t,s){return this.resources.fetch({type:"orders"},`external_payments/${e}/order`,t,s)}async payment_gateway(e,t,s){return this.resources.fetch({type:"payment_gateways"},`external_payments/${e}/payment_gateway`,t,s)}async wallet(e,t,s){return this.resources.fetch({type:"customer_payment_sources"},`external_payments/${e}/wallet`,t,s)}isExternalPayment(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="external_payments";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{PromotionRule}from'./promotion_rules';import{OrderAmountPromotionRule}from'./order_amount_promotion_rules';import{SkuListPromotionRule}from'./sku_list_promotion_rules';import{CouponCodesPromotionRule}from'./coupon_codes_promotion_rules';import{Attachment}from'./attachments';declare type ExternalPromotionRel=ResourceRel&{type:typeof ExternalPromotions.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type PromotionRuleRel=ResourceRel&{type:'promotion_rules';};declare type OrderAmountPromotionRuleRel=ResourceRel&{type:'order_amount_promotion_rules';};declare type SkuListPromotionRuleRel=ResourceRel&{type:'sku_list_promotion_rules';};declare type CouponCodesPromotionRuleRel=ResourceRel&{type:'coupon_codes_promotion_rules';};interface ExternalPromotion extends Resource{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;total_usage_count?:number;active?:boolean;promotion_url?:string;market?:Market;promotion_rules?:PromotionRule[];order_amount_promotion_rule?:OrderAmountPromotionRule;sku_list_promotion_rule?:SkuListPromotionRule;coupon_codes_promotion_rule?:CouponCodesPromotionRule;attachments?:Attachment[];}interface ExternalPromotionCreate extends ResourceCreate{name:string;currency_code?:string;starts_at:string;expires_at:string;total_usage_limit:number;promotion_url:string;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;}interface ExternalPromotionUpdate extends ResourceUpdate{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;promotion_url?:string;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;}declare class ExternalPromotions extends ApiResource{static readonly TYPE:'external_promotions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ExternalPromotion>>;create(resource:ExternalPromotionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalPromotion>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalPromotion>;update(resource:ExternalPromotionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalPromotion>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(externalPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;order_amount_promotion_rule(externalPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;sku_list_promotion_rule(externalPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuListPromotionRule>;coupon_codes_promotion_rule(externalPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;attachments(externalPromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isExternalPromotion(resource:any):resource is ExternalPromotion;relationship(id:string|ResourceId|null):ExternalPromotionRel;type():string;}export default ExternalPromotions;export{ExternalPromotion,ExternalPromotionCreate,ExternalPromotionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class o extends s{async list(e,t){return this.resources.list({type:o.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:o.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:o.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:o.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:o.TYPE,id:e},t)}async market(e,t,r){return this.resources.fetch({type:"markets"},`external_promotions/${e}/market`,t,r)}async order_amount_promotion_rule(e,t,r){return this.resources.fetch({type:"order_amount_promotion_rules"},`external_promotions/${e}/order_amount_promotion_rule`,t,r)}async sku_list_promotion_rule(e,t,r){return this.resources.fetch({type:"sku_list_promotion_rules"},`external_promotions/${e}/sku_list_promotion_rule`,t,r)}async coupon_codes_promotion_rule(e,t,r){return this.resources.fetch({type:"coupon_codes_promotion_rules"},`external_promotions/${e}/coupon_codes_promotion_rule`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`external_promotions/${e}/attachments`,t,r)}isExternalPromotion(e){return e.type&&e.type===o.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:o.TYPE}:{id:e.id,type:o.TYPE}}type(){return o.TYPE}}o.TYPE="external_promotions";export default o;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{TaxCategory}from'./tax_categories';import{Market}from'./markets';import{Attachment}from'./attachments';declare type ExternalTaxCalculatorRel=ResourceRel&{type:typeof ExternalTaxCalculators.TYPE;};declare type TaxCategoryRel=ResourceRel&{type:'tax_categories';};interface ExternalTaxCalculator extends Resource{name?:string;tax_calculator_url?:string;tax_categories?:TaxCategory[];markets?:Market[];attachments?:Attachment[];}interface ExternalTaxCalculatorCreate extends ResourceCreate{name:string;tax_calculator_url:string;tax_categories?:TaxCategoryRel[];}interface ExternalTaxCalculatorUpdate extends ResourceUpdate{name?:string;tax_calculator_url?:string;tax_categories?:TaxCategoryRel[];}declare class ExternalTaxCalculators extends ApiResource{static readonly TYPE:'external_tax_calculators';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ExternalTaxCalculator>>;create(resource:ExternalTaxCalculatorCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalTaxCalculator>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalTaxCalculator>;update(resource:ExternalTaxCalculatorUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ExternalTaxCalculator>;delete(id:string,options?:ResourcesConfig):Promise<void>;tax_categories(externalTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<TaxCategory>>;markets(externalTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Market>>;attachments(externalTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isExternalTaxCalculator(resource:any):resource is ExternalTaxCalculator;relationship(id:string|ResourceId|null):ExternalTaxCalculatorRel;type():string;}export default ExternalTaxCalculators;export{ExternalTaxCalculator,ExternalTaxCalculatorCreate,ExternalTaxCalculatorUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as a}from"../resource";class r extends a{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async tax_categories(e,t,s){return this.resources.fetch({type:"tax_categories"},`external_tax_calculators/${e}/tax_categories`,t,s)}async markets(e,t,s){return this.resources.fetch({type:"markets"},`external_tax_calculators/${e}/markets`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`external_tax_calculators/${e}/attachments`,t,s)}isExternalTaxCalculator(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="external_tax_calculators";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{PromotionRule}from'./promotion_rules';import{OrderAmountPromotionRule}from'./order_amount_promotion_rules';import{SkuListPromotionRule}from'./sku_list_promotion_rules';import{CouponCodesPromotionRule}from'./coupon_codes_promotion_rules';import{Attachment}from'./attachments';declare type FixedAmountPromotionRel=ResourceRel&{type:typeof FixedAmountPromotions.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type PromotionRuleRel=ResourceRel&{type:'promotion_rules';};declare type OrderAmountPromotionRuleRel=ResourceRel&{type:'order_amount_promotion_rules';};declare type SkuListPromotionRuleRel=ResourceRel&{type:'sku_list_promotion_rules';};declare type CouponCodesPromotionRuleRel=ResourceRel&{type:'coupon_codes_promotion_rules';};interface FixedAmountPromotion extends Resource{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;total_usage_count?:number;active?:boolean;fixed_amount_cents?:number;fixed_amount_float?:number;formatted_fixed_amount?:string;market?:Market;promotion_rules?:PromotionRule[];order_amount_promotion_rule?:OrderAmountPromotionRule;sku_list_promotion_rule?:SkuListPromotionRule;coupon_codes_promotion_rule?:CouponCodesPromotionRule;attachments?:Attachment[];}interface FixedAmountPromotionCreate extends ResourceCreate{name:string;currency_code?:string;starts_at:string;expires_at:string;total_usage_limit:number;fixed_amount_cents:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;}interface FixedAmountPromotionUpdate extends ResourceUpdate{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;fixed_amount_cents?:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;}declare class FixedAmountPromotions extends ApiResource{static readonly TYPE:'fixed_amount_promotions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<FixedAmountPromotion>>;create(resource:FixedAmountPromotionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FixedAmountPromotion>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FixedAmountPromotion>;update(resource:FixedAmountPromotionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FixedAmountPromotion>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(fixedAmountPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;order_amount_promotion_rule(fixedAmountPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;sku_list_promotion_rule(fixedAmountPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuListPromotionRule>;coupon_codes_promotion_rule(fixedAmountPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;attachments(fixedAmountPromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isFixedAmountPromotion(resource:any):resource is FixedAmountPromotion;relationship(id:string|ResourceId|null):FixedAmountPromotionRel;type():string;}export default FixedAmountPromotions;export{FixedAmountPromotion,FixedAmountPromotionCreate,FixedAmountPromotionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class o extends s{async list(e,t){return this.resources.list({type:o.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:o.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:o.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:o.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:o.TYPE,id:e},t)}async market(e,t,r){return this.resources.fetch({type:"markets"},`fixed_amount_promotions/${e}/market`,t,r)}async order_amount_promotion_rule(e,t,r){return this.resources.fetch({type:"order_amount_promotion_rules"},`fixed_amount_promotions/${e}/order_amount_promotion_rule`,t,r)}async sku_list_promotion_rule(e,t,r){return this.resources.fetch({type:"sku_list_promotion_rules"},`fixed_amount_promotions/${e}/sku_list_promotion_rule`,t,r)}async coupon_codes_promotion_rule(e,t,r){return this.resources.fetch({type:"coupon_codes_promotion_rules"},`fixed_amount_promotions/${e}/coupon_codes_promotion_rule`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`fixed_amount_promotions/${e}/attachments`,t,r)}isFixedAmountPromotion(e){return e.type&&e.type===o.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:o.TYPE}:{id:e.id,type:o.TYPE}}type(){return o.TYPE}}o.TYPE="fixed_amount_promotions";export default o;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{PromotionRule}from'./promotion_rules';import{OrderAmountPromotionRule}from'./order_amount_promotion_rules';import{SkuListPromotionRule}from'./sku_list_promotion_rules';import{CouponCodesPromotionRule}from'./coupon_codes_promotion_rules';import{Attachment}from'./attachments';import{SkuList}from'./sku_lists';import{Sku}from'./skus';declare type FixedPricePromotionRel=ResourceRel&{type:typeof FixedPricePromotions.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type PromotionRuleRel=ResourceRel&{type:'promotion_rules';};declare type OrderAmountPromotionRuleRel=ResourceRel&{type:'order_amount_promotion_rules';};declare type SkuListPromotionRuleRel=ResourceRel&{type:'sku_list_promotion_rules';};declare type CouponCodesPromotionRuleRel=ResourceRel&{type:'coupon_codes_promotion_rules';};declare type SkuListRel=ResourceRel&{type:'sku_lists';};interface FixedPricePromotion extends Resource{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;total_usage_count?:number;active?:boolean;fixed_amount_cents?:number;fixed_amount_float?:number;formatted_fixed_amount?:string;market?:Market;promotion_rules?:PromotionRule[];order_amount_promotion_rule?:OrderAmountPromotionRule;sku_list_promotion_rule?:SkuListPromotionRule;coupon_codes_promotion_rule?:CouponCodesPromotionRule;attachments?:Attachment[];sku_list?:SkuList;skus?:Sku[];}interface FixedPricePromotionCreate extends ResourceCreate{name:string;currency_code?:string;starts_at:string;expires_at:string;total_usage_limit:number;fixed_amount_cents:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;sku_list:SkuListRel;}interface FixedPricePromotionUpdate extends ResourceUpdate{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;fixed_amount_cents?:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;sku_list?:SkuListRel;}declare class FixedPricePromotions extends ApiResource{static readonly TYPE:'fixed_price_promotions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<FixedPricePromotion>>;create(resource:FixedPricePromotionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FixedPricePromotion>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FixedPricePromotion>;update(resource:FixedPricePromotionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FixedPricePromotion>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(fixedPricePromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;order_amount_promotion_rule(fixedPricePromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;sku_list_promotion_rule(fixedPricePromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuListPromotionRule>;coupon_codes_promotion_rule(fixedPricePromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;attachments(fixedPricePromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;sku_list(fixedPricePromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuList>;skus(fixedPricePromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Sku>>;isFixedPricePromotion(resource:any):resource is FixedPricePromotion;relationship(id:string|ResourceId|null):FixedPricePromotionRel;type():string;}export default FixedPricePromotions;export{FixedPricePromotion,FixedPricePromotionCreate,FixedPricePromotionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class o extends s{async list(e,r){return this.resources.list({type:o.TYPE},e,r)}async create(e,r,t){return this.resources.create({...e,type:o.TYPE},r,t)}async retrieve(e,r,t){return this.resources.retrieve({type:o.TYPE,id:e},r,t)}async update(e,r,t){return this.resources.update({...e,type:o.TYPE},r,t)}async delete(e,r){await this.resources.delete({type:o.TYPE,id:e},r)}async market(e,r,t){return this.resources.fetch({type:"markets"},`fixed_price_promotions/${e}/market`,r,t)}async order_amount_promotion_rule(e,r,t){return this.resources.fetch({type:"order_amount_promotion_rules"},`fixed_price_promotions/${e}/order_amount_promotion_rule`,r,t)}async sku_list_promotion_rule(e,r,t){return this.resources.fetch({type:"sku_list_promotion_rules"},`fixed_price_promotions/${e}/sku_list_promotion_rule`,r,t)}async coupon_codes_promotion_rule(e,r,t){return this.resources.fetch({type:"coupon_codes_promotion_rules"},`fixed_price_promotions/${e}/coupon_codes_promotion_rule`,r,t)}async attachments(e,r,t){return this.resources.fetch({type:"attachments"},`fixed_price_promotions/${e}/attachments`,r,t)}async sku_list(e,r,t){return this.resources.fetch({type:"sku_lists"},`fixed_price_promotions/${e}/sku_list`,r,t)}async skus(e,r,t){return this.resources.fetch({type:"skus"},`fixed_price_promotions/${e}/skus`,r,t)}isFixedPricePromotion(e){return e.type&&e.type===o.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:o.TYPE}:{id:e.id,type:o.TYPE}}type(){return o.TYPE}}o.TYPE="fixed_price_promotions";export default o;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{PromotionRule}from'./promotion_rules';import{OrderAmountPromotionRule}from'./order_amount_promotion_rules';import{SkuListPromotionRule}from'./sku_list_promotion_rules';import{CouponCodesPromotionRule}from'./coupon_codes_promotion_rules';import{Attachment}from'./attachments';import{SkuList}from'./sku_lists';import{Sku}from'./skus';declare type FreeGiftPromotionRel=ResourceRel&{type:typeof FreeGiftPromotions.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type PromotionRuleRel=ResourceRel&{type:'promotion_rules';};declare type OrderAmountPromotionRuleRel=ResourceRel&{type:'order_amount_promotion_rules';};declare type SkuListPromotionRuleRel=ResourceRel&{type:'sku_list_promotion_rules';};declare type CouponCodesPromotionRuleRel=ResourceRel&{type:'coupon_codes_promotion_rules';};declare type SkuListRel=ResourceRel&{type:'sku_lists';};interface FreeGiftPromotion extends Resource{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;total_usage_count?:number;active?:boolean;max_quantity?:number;market?:Market;promotion_rules?:PromotionRule[];order_amount_promotion_rule?:OrderAmountPromotionRule;sku_list_promotion_rule?:SkuListPromotionRule;coupon_codes_promotion_rule?:CouponCodesPromotionRule;attachments?:Attachment[];sku_list?:SkuList;skus?:Sku[];}interface FreeGiftPromotionCreate extends ResourceCreate{name:string;currency_code?:string;starts_at:string;expires_at:string;total_usage_limit:number;max_quantity?:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;sku_list:SkuListRel;}interface FreeGiftPromotionUpdate extends ResourceUpdate{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;max_quantity?:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;sku_list?:SkuListRel;}declare class FreeGiftPromotions extends ApiResource{static readonly TYPE:'free_gift_promotions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<FreeGiftPromotion>>;create(resource:FreeGiftPromotionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FreeGiftPromotion>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FreeGiftPromotion>;update(resource:FreeGiftPromotionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FreeGiftPromotion>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(freeGiftPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;order_amount_promotion_rule(freeGiftPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;sku_list_promotion_rule(freeGiftPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuListPromotionRule>;coupon_codes_promotion_rule(freeGiftPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;attachments(freeGiftPromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;sku_list(freeGiftPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuList>;skus(freeGiftPromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Sku>>;isFreeGiftPromotion(resource:any):resource is FreeGiftPromotion;relationship(id:string|ResourceId|null):FreeGiftPromotionRel;type():string;}export default FreeGiftPromotions;export{FreeGiftPromotion,FreeGiftPromotionCreate,FreeGiftPromotionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class o extends s{async list(e,t){return this.resources.list({type:o.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:o.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:o.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:o.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:o.TYPE,id:e},t)}async market(e,t,r){return this.resources.fetch({type:"markets"},`free_gift_promotions/${e}/market`,t,r)}async order_amount_promotion_rule(e,t,r){return this.resources.fetch({type:"order_amount_promotion_rules"},`free_gift_promotions/${e}/order_amount_promotion_rule`,t,r)}async sku_list_promotion_rule(e,t,r){return this.resources.fetch({type:"sku_list_promotion_rules"},`free_gift_promotions/${e}/sku_list_promotion_rule`,t,r)}async coupon_codes_promotion_rule(e,t,r){return this.resources.fetch({type:"coupon_codes_promotion_rules"},`free_gift_promotions/${e}/coupon_codes_promotion_rule`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`free_gift_promotions/${e}/attachments`,t,r)}async sku_list(e,t,r){return this.resources.fetch({type:"sku_lists"},`free_gift_promotions/${e}/sku_list`,t,r)}async skus(e,t,r){return this.resources.fetch({type:"skus"},`free_gift_promotions/${e}/skus`,t,r)}isFreeGiftPromotion(e){return e.type&&e.type===o.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:o.TYPE}:{id:e.id,type:o.TYPE}}type(){return o.TYPE}}o.TYPE="free_gift_promotions";export default o;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{PromotionRule}from'./promotion_rules';import{OrderAmountPromotionRule}from'./order_amount_promotion_rules';import{SkuListPromotionRule}from'./sku_list_promotion_rules';import{CouponCodesPromotionRule}from'./coupon_codes_promotion_rules';import{Attachment}from'./attachments';declare type FreeShippingPromotionRel=ResourceRel&{type:typeof FreeShippingPromotions.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type PromotionRuleRel=ResourceRel&{type:'promotion_rules';};declare type OrderAmountPromotionRuleRel=ResourceRel&{type:'order_amount_promotion_rules';};declare type SkuListPromotionRuleRel=ResourceRel&{type:'sku_list_promotion_rules';};declare type CouponCodesPromotionRuleRel=ResourceRel&{type:'coupon_codes_promotion_rules';};interface FreeShippingPromotion extends Resource{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;total_usage_count?:number;active?:boolean;market?:Market;promotion_rules?:PromotionRule[];order_amount_promotion_rule?:OrderAmountPromotionRule;sku_list_promotion_rule?:SkuListPromotionRule;coupon_codes_promotion_rule?:CouponCodesPromotionRule;attachments?:Attachment[];}interface FreeShippingPromotionCreate extends ResourceCreate{name:string;currency_code?:string;starts_at:string;expires_at:string;total_usage_limit:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;}interface FreeShippingPromotionUpdate extends ResourceUpdate{name?:string;currency_code?:string;starts_at?:string;expires_at?:string;total_usage_limit?:number;market?:MarketRel;promotion_rules?:PromotionRuleRel[];order_amount_promotion_rule?:OrderAmountPromotionRuleRel;sku_list_promotion_rule?:SkuListPromotionRuleRel;coupon_codes_promotion_rule?:CouponCodesPromotionRuleRel;}declare class FreeShippingPromotions extends ApiResource{static readonly TYPE:'free_shipping_promotions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<FreeShippingPromotion>>;create(resource:FreeShippingPromotionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FreeShippingPromotion>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FreeShippingPromotion>;update(resource:FreeShippingPromotionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<FreeShippingPromotion>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(freeShippingPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;order_amount_promotion_rule(freeShippingPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;sku_list_promotion_rule(freeShippingPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuListPromotionRule>;coupon_codes_promotion_rule(freeShippingPromotionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CouponCodesPromotionRule>;attachments(freeShippingPromotionId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isFreeShippingPromotion(resource:any):resource is FreeShippingPromotion;relationship(id:string|ResourceId|null):FreeShippingPromotionRel;type():string;}export default FreeShippingPromotions;export{FreeShippingPromotion,FreeShippingPromotionCreate,FreeShippingPromotionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class o extends s{async list(e,r){return this.resources.list({type:o.TYPE},e,r)}async create(e,r,t){return this.resources.create({...e,type:o.TYPE},r,t)}async retrieve(e,r,t){return this.resources.retrieve({type:o.TYPE,id:e},r,t)}async update(e,r,t){return this.resources.update({...e,type:o.TYPE},r,t)}async delete(e,r){await this.resources.delete({type:o.TYPE,id:e},r)}async market(e,r,t){return this.resources.fetch({type:"markets"},`free_shipping_promotions/${e}/market`,r,t)}async order_amount_promotion_rule(e,r,t){return this.resources.fetch({type:"order_amount_promotion_rules"},`free_shipping_promotions/${e}/order_amount_promotion_rule`,r,t)}async sku_list_promotion_rule(e,r,t){return this.resources.fetch({type:"sku_list_promotion_rules"},`free_shipping_promotions/${e}/sku_list_promotion_rule`,r,t)}async coupon_codes_promotion_rule(e,r,t){return this.resources.fetch({type:"coupon_codes_promotion_rules"},`free_shipping_promotions/${e}/coupon_codes_promotion_rule`,r,t)}async attachments(e,r,t){return this.resources.fetch({type:"attachments"},`free_shipping_promotions/${e}/attachments`,r,t)}isFreeShippingPromotion(e){return e.type&&e.type===o.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:o.TYPE}:{id:e.id,type:o.TYPE}}type(){return o.TYPE}}o.TYPE="free_shipping_promotions";export default o;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Address}from'./addresses';import{Attachment}from'./attachments';declare type GeocoderRel=ResourceRel&{type:typeof Geocoders.TYPE;};interface Geocoder extends Resource{name?:string;addresses?:Address[];attachments?:Attachment[];}declare class Geocoders extends ApiResource{static readonly TYPE:'geocoders';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Geocoder>>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Geocoder>;addresses(geocoderId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Address>>;attachments(geocoderId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isGeocoder(resource:any):resource is Geocoder;relationship(id:string|ResourceId|null):GeocoderRel;type():string;}export default Geocoders;export{Geocoder};
@@ -0,0 +1 @@
1
+ import{ApiResource as c}from"../resource";class s extends c{async list(e,r){return this.resources.list({type:s.TYPE},e,r)}async retrieve(e,r,t){return this.resources.retrieve({type:s.TYPE,id:e},r,t)}async addresses(e,r,t){return this.resources.fetch({type:"addresses"},`geocoders/${e}/addresses`,r,t)}async attachments(e,r,t){return this.resources.fetch({type:"attachments"},`geocoders/${e}/attachments`,r,t)}isGeocoder(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="geocoders";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Customer}from'./customers';import{Attachment}from'./attachments';declare type GiftCardRecipientRel=ResourceRel&{type:typeof GiftCardRecipients.TYPE;};declare type CustomerRel=ResourceRel&{type:'customers';};interface GiftCardRecipient extends Resource{email?:string;first_name?:string;last_name?:string;customer?:Customer;attachments?:Attachment[];}interface GiftCardRecipientCreate extends ResourceCreate{email:string;first_name?:string;last_name?:string;customer?:CustomerRel;}interface GiftCardRecipientUpdate extends ResourceUpdate{email?:string;first_name?:string;last_name?:string;customer?:CustomerRel;}declare class GiftCardRecipients extends ApiResource{static readonly TYPE:'gift_card_recipients';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GiftCardRecipient>>;create(resource:GiftCardRecipientCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;update(resource:GiftCardRecipientUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;delete(id:string,options?:ResourcesConfig):Promise<void>;customer(giftCardRecipientId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;attachments(giftCardRecipientId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isGiftCardRecipient(resource:any):resource is GiftCardRecipient;relationship(id:string|ResourceId|null):GiftCardRecipientRel;type():string;}export default GiftCardRecipients;export{GiftCardRecipient,GiftCardRecipientCreate,GiftCardRecipientUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class s extends i{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async customer(e,t,r){return this.resources.fetch({type:"customers"},`gift_card_recipients/${e}/customer`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`gift_card_recipients/${e}/attachments`,t,r)}isGiftCardRecipient(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="gift_card_recipients";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{GiftCardRecipient}from'./gift_card_recipients';import{Attachment}from'./attachments';declare type GiftCardRel=ResourceRel&{type:typeof GiftCards.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type GiftCardRecipientRel=ResourceRel&{type:'gift_card_recipients';};interface GiftCard extends Resource{status?:string;code?:string;currency_code?:string;initial_balance_cents?:number;initial_balance_float?:number;formatted_initial_balance?:string;balance_cents?:number;balance_float?:number;formatted_balance?:string;balance_max_cents?:string;balance_max_float?:number;formatted_balance_max?:string;balance_log?:object[];single_use?:boolean;rechargeable?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:Market;gift_card_recipient?:GiftCardRecipient;attachments?:Attachment[];}interface GiftCardCreate extends ResourceCreate{code?:string;currency_code?:string;balance_cents:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;}interface GiftCardUpdate extends ResourceUpdate{currency_code?:string;balance_cents?:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;_purchase?:boolean;_activate?:boolean;_deactivate?:boolean;_balance_change_cents?:number;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;}declare class GiftCards extends ApiResource{static readonly TYPE:'gift_cards';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GiftCard>>;create(resource:GiftCardCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;update(resource:GiftCardUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(giftCardId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;gift_card_recipient(giftCardId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;attachments(giftCardId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isGiftCard(resource:any):resource is GiftCard;relationship(id:string|ResourceId|null):GiftCardRel;type():string;}export default GiftCards;export{GiftCard,GiftCardCreate,GiftCardUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class r extends i{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async market(e,t,s){return this.resources.fetch({type:"markets"},`gift_cards/${e}/market`,t,s)}async gift_card_recipient(e,t,s){return this.resources.fetch({type:"gift_card_recipients"},`gift_cards/${e}/gift_card_recipient`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`gift_cards/${e}/attachments`,t,s)}isGiftCard(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="gift_cards";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Address}from'./addresses';import{Attachment}from'./attachments';declare type GoogleGeocoderRel=ResourceRel&{type:typeof GoogleGeocoders.TYPE;};interface GoogleGeocoder extends Resource{name?:string;addresses?:Address[];attachments?:Attachment[];}interface GoogleGeocoderCreate extends ResourceCreate{name:string;api_key:string;}interface GoogleGeocoderUpdate extends ResourceUpdate{name?:string;api_key?:string;}declare class GoogleGeocoders extends ApiResource{static readonly TYPE:'google_geocoders';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GoogleGeocoder>>;create(resource:GoogleGeocoderCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GoogleGeocoder>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GoogleGeocoder>;update(resource:GoogleGeocoderUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GoogleGeocoder>;delete(id:string,options?:ResourcesConfig):Promise<void>;addresses(googleGeocoderId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Address>>;attachments(googleGeocoderId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isGoogleGeocoder(resource:any):resource is GoogleGeocoder;relationship(id:string|ResourceId|null):GoogleGeocoderRel;type():string;}export default GoogleGeocoders;export{GoogleGeocoder,GoogleGeocoderCreate,GoogleGeocoderUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as o}from"../resource";class r extends o{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async addresses(e,t,s){return this.resources.fetch({type:"addresses"},`google_geocoders/${e}/addresses`,t,s)}async attachments(e,t,s){return this.resources.fetch({type:"attachments"},`google_geocoders/${e}/attachments`,t,s)}isGoogleGeocoder(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="google_geocoders";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';declare type ImportRel=ResourceRel&{type:typeof Imports.TYPE;};interface Import extends Resource{resource_type?:string;parent_resource_id?:string;status?:string;started_at?:string;completed_at?:string;interrupted_at?:string;inputs?:object[];inputs_size?:number;errors_count?:number;warnings_count?:number;destroyed_count?:number;processed_count?:number;errors_log?:object;warnings_log?:object;cleanup_records?:boolean;}interface ImportCreate extends ResourceCreate{resource_type:string;parent_resource_id?:string;inputs:object[];cleanup_records?:boolean;}declare class Imports extends ApiResource{static readonly TYPE:'imports';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Import>>;create(resource:ImportCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Import>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Import>;delete(id:string,options?:ResourcesConfig):Promise<void>;isImport(resource:any):resource is Import;relationship(id:string|ResourceId|null):ImportRel;type():string;}export default Imports;export{Import,ImportCreate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class r extends i{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}isImport(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="imports";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Market}from'./markets';import{Customer}from'./customers';import{Sku}from'./skus';declare type InStockSubscriptionRel=ResourceRel&{type:typeof InStockSubscriptions.TYPE;};declare type MarketRel=ResourceRel&{type:'markets';};declare type CustomerRel=ResourceRel&{type:'customers';};declare type SkuRel=ResourceRel&{type:'skus';};interface InStockSubscription extends Resource{status?:string;customer_email?:string;sku_code?:string;stock_threshold?:number;market?:Market;customer?:Customer;sku?:Sku;}interface InStockSubscriptionCreate extends ResourceCreate{customer_email?:string;sku_code?:string;stock_threshold?:number;market:MarketRel;customer:CustomerRel;sku:SkuRel;}interface InStockSubscriptionUpdate extends ResourceUpdate{sku_code?:string;stock_threshold?:number;_activate?:boolean;_deactivate?:boolean;market?:MarketRel;customer?:CustomerRel;sku?:SkuRel;}declare class InStockSubscriptions extends ApiResource{static readonly TYPE:'in_stock_subscriptions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<InStockSubscription>>;create(resource:InStockSubscriptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InStockSubscription>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InStockSubscription>;update(resource:InStockSubscriptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InStockSubscription>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(inStockSubscriptionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;customer(inStockSubscriptionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;sku(inStockSubscriptionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Sku>;isInStockSubscription(resource:any):resource is InStockSubscription;relationship(id:string|ResourceId|null):InStockSubscriptionRel;type():string;}export default InStockSubscriptions;export{InStockSubscription,InStockSubscriptionCreate,InStockSubscriptionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class s extends i{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async market(e,t,r){return this.resources.fetch({type:"markets"},`in_stock_subscriptions/${e}/market`,t,r)}async customer(e,t,r){return this.resources.fetch({type:"customers"},`in_stock_subscriptions/${e}/customer`,t,r)}async sku(e,t,r){return this.resources.fetch({type:"skus"},`in_stock_subscriptions/${e}/sku`,t,r)}isInStockSubscription(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="in_stock_subscriptions";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{InventoryStockLocation}from'./inventory_stock_locations';import{InventoryReturnLocation}from'./inventory_return_locations';import{Attachment}from'./attachments';declare type InventoryModelRel=ResourceRel&{type:typeof InventoryModels.TYPE;};interface InventoryModel extends Resource{name?:string;strategy?:string;stock_locations_cutoff?:number;inventory_stock_locations?:InventoryStockLocation[];inventory_return_locations?:InventoryReturnLocation[];attachments?:Attachment[];}interface InventoryModelCreate extends ResourceCreate{name:string;strategy:string;stock_locations_cutoff?:number;}interface InventoryModelUpdate extends ResourceUpdate{name?:string;strategy?:string;stock_locations_cutoff?:number;}declare class InventoryModels extends ApiResource{static readonly TYPE:'inventory_models';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<InventoryModel>>;create(resource:InventoryModelCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryModel>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryModel>;update(resource:InventoryModelUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryModel>;delete(id:string,options?:ResourcesConfig):Promise<void>;inventory_stock_locations(inventoryModelId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<InventoryStockLocation>>;inventory_return_locations(inventoryModelId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<InventoryReturnLocation>>;attachments(inventoryModelId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isInventoryModel(resource:any):resource is InventoryModel;relationship(id:string|ResourceId|null):InventoryModelRel;type():string;}export default InventoryModels;export{InventoryModel,InventoryModelCreate,InventoryModelUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as n}from"../resource";class s extends n{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async inventory_stock_locations(e,t,r){return this.resources.fetch({type:"inventory_stock_locations"},`inventory_models/${e}/inventory_stock_locations`,t,r)}async inventory_return_locations(e,t,r){return this.resources.fetch({type:"inventory_return_locations"},`inventory_models/${e}/inventory_return_locations`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`inventory_models/${e}/attachments`,t,r)}isInventoryModel(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="inventory_models";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{StockLocation}from'./stock_locations';import{InventoryModel}from'./inventory_models';declare type InventoryReturnLocationRel=ResourceRel&{type:typeof InventoryReturnLocations.TYPE;};declare type StockLocationRel=ResourceRel&{type:'stock_locations';};declare type InventoryModelRel=ResourceRel&{type:'inventory_models';};interface InventoryReturnLocation extends Resource{priority?:number;stock_location?:StockLocation;inventory_model?:InventoryModel;}interface InventoryReturnLocationCreate extends ResourceCreate{priority:number;stock_location:StockLocationRel;inventory_model:InventoryModelRel;}interface InventoryReturnLocationUpdate extends ResourceUpdate{priority?:number;stock_location?:StockLocationRel;inventory_model?:InventoryModelRel;}declare class InventoryReturnLocations extends ApiResource{static readonly TYPE:'inventory_return_locations';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<InventoryReturnLocation>>;create(resource:InventoryReturnLocationCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryReturnLocation>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryReturnLocation>;update(resource:InventoryReturnLocationUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryReturnLocation>;delete(id:string,options?:ResourcesConfig):Promise<void>;stock_location(inventoryReturnLocationId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;inventory_model(inventoryReturnLocationId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryModel>;isInventoryReturnLocation(resource:any):resource is InventoryReturnLocation;relationship(id:string|ResourceId|null):InventoryReturnLocationRel;type():string;}export default InventoryReturnLocations;export{InventoryReturnLocation,InventoryReturnLocationCreate,InventoryReturnLocationUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as n}from"../resource";class r extends n{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async stock_location(e,t,s){return this.resources.fetch({type:"stock_locations"},`inventory_return_locations/${e}/stock_location`,t,s)}async inventory_model(e,t,s){return this.resources.fetch({type:"inventory_models"},`inventory_return_locations/${e}/inventory_model`,t,s)}isInventoryReturnLocation(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="inventory_return_locations";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{StockLocation}from'./stock_locations';import{InventoryModel}from'./inventory_models';declare type InventoryStockLocationRel=ResourceRel&{type:typeof InventoryStockLocations.TYPE;};declare type StockLocationRel=ResourceRel&{type:'stock_locations';};declare type InventoryModelRel=ResourceRel&{type:'inventory_models';};interface InventoryStockLocation extends Resource{priority?:number;on_hold?:boolean;stock_location?:StockLocation;inventory_model?:InventoryModel;}interface InventoryStockLocationCreate extends ResourceCreate{priority:number;on_hold?:boolean;stock_location:StockLocationRel;inventory_model:InventoryModelRel;}interface InventoryStockLocationUpdate extends ResourceUpdate{priority?:number;on_hold?:boolean;stock_location?:StockLocationRel;inventory_model?:InventoryModelRel;}declare class InventoryStockLocations extends ApiResource{static readonly TYPE:'inventory_stock_locations';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<InventoryStockLocation>>;create(resource:InventoryStockLocationCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;update(resource:InventoryStockLocationUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;delete(id:string,options?:ResourcesConfig):Promise<void>;stock_location(inventoryStockLocationId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;inventory_model(inventoryStockLocationId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryModel>;isInventoryStockLocation(resource:any):resource is InventoryStockLocation;relationship(id:string|ResourceId|null):InventoryStockLocationRel;type():string;}export default InventoryStockLocations;export{InventoryStockLocation,InventoryStockLocationCreate,InventoryStockLocationUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as r}from"../resource";class s extends r{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,o){return this.resources.create({...e,type:s.TYPE},t,o)}async retrieve(e,t,o){return this.resources.retrieve({type:s.TYPE,id:e},t,o)}async update(e,t,o){return this.resources.update({...e,type:s.TYPE},t,o)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async stock_location(e,t,o){return this.resources.fetch({type:"stock_locations"},`inventory_stock_locations/${e}/stock_location`,t,o)}async inventory_model(e,t,o){return this.resources.fetch({type:"inventory_models"},`inventory_stock_locations/${e}/inventory_model`,t,o)}isInventoryStockLocation(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="inventory_stock_locations";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{PaymentMethod}from'./payment_methods';import{KlarnaPayment}from'./klarna_payments';declare type KlarnaGatewayRel=ResourceRel&{type:typeof KlarnaGateways.TYPE;};declare type KlarnaPaymentRel=ResourceRel&{type:'klarna_payments';};interface KlarnaGateway extends Resource{name?:string;payment_methods?:PaymentMethod[];klarna_payments?:KlarnaPayment[];}interface KlarnaGatewayCreate extends ResourceCreate{name:string;country_code:string;api_key:string;api_secret:string;klarna_payments?:KlarnaPaymentRel[];}interface KlarnaGatewayUpdate extends ResourceUpdate{name?:string;country_code?:string;api_key?:string;api_secret?:string;klarna_payments?:KlarnaPaymentRel[];}declare class KlarnaGateways extends ApiResource{static readonly TYPE:'klarna_gateways';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<KlarnaGateway>>;create(resource:KlarnaGatewayCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<KlarnaGateway>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<KlarnaGateway>;update(resource:KlarnaGatewayUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<KlarnaGateway>;delete(id:string,options?:ResourcesConfig):Promise<void>;payment_methods(klarnaGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;klarna_payments(klarnaGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<KlarnaPayment>>;isKlarnaGateway(resource:any):resource is KlarnaGateway;relationship(id:string|ResourceId|null):KlarnaGatewayRel;type():string;}export default KlarnaGateways;export{KlarnaGateway,KlarnaGatewayCreate,KlarnaGatewayUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as r}from"../resource";class s extends r{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,a){return this.resources.create({...e,type:s.TYPE},t,a)}async retrieve(e,t,a){return this.resources.retrieve({type:s.TYPE,id:e},t,a)}async update(e,t,a){return this.resources.update({...e,type:s.TYPE},t,a)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async payment_methods(e,t,a){return this.resources.fetch({type:"payment_methods"},`klarna_gateways/${e}/payment_methods`,t,a)}async klarna_payments(e,t,a){return this.resources.fetch({type:"klarna_payments"},`klarna_gateways/${e}/klarna_payments`,t,a)}isKlarnaGateway(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="klarna_gateways";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Order}from'./orders';import{PaymentGateway}from'./payment_gateways';declare type KlarnaPaymentRel=ResourceRel&{type:typeof KlarnaPayments.TYPE;};declare type OrderRel=ResourceRel&{type:'orders';};interface KlarnaPayment extends Resource{session_id?:string;client_token?:string;payment_methods?:object[];auth_token?:string;order?:Order;payment_gateway?:PaymentGateway;}interface KlarnaPaymentCreate extends ResourceCreate{order:OrderRel;}interface KlarnaPaymentUpdate extends ResourceUpdate{auth_token?:string;_update?:boolean;order?:OrderRel;}declare class KlarnaPayments extends ApiResource{static readonly TYPE:'klarna_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<KlarnaPayment>>;create(resource:KlarnaPaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<KlarnaPayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<KlarnaPayment>;update(resource:KlarnaPaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<KlarnaPayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(klarnaPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(klarnaPaymentId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;isKlarnaPayment(resource:any):resource is KlarnaPayment;relationship(id:string|ResourceId|null):KlarnaPaymentRel;type():string;}export default KlarnaPayments;export{KlarnaPayment,KlarnaPaymentCreate,KlarnaPaymentUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as a}from"../resource";class r extends a{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}async order(e,t,s){return this.resources.fetch({type:"orders"},`klarna_payments/${e}/order`,t,s)}async payment_gateway(e,t,s){return this.resources.fetch({type:"payment_gateways"},`klarna_payments/${e}/payment_gateway`,t,s)}isKlarnaPayment(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="klarna_payments";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{LineItem}from'./line_items';import{SkuOption}from'./sku_options';declare type LineItemOptionRel=ResourceRel&{type:typeof LineItemOptions.TYPE;};declare type LineItemRel=ResourceRel&{type:'line_items';};declare type SkuOptionRel=ResourceRel&{type:'sku_options';};interface LineItemOption extends Resource{name?:string;quantity?:number;currency_code?:string;unit_amount_cents?:number;unit_amount_float?:number;formatted_unit_amount?:string;total_amount_cents?:number;total_amount_float?:number;formatted_total_amount?:string;delay_hours?:number;delay_days?:number;options?:object;line_item?:LineItem;sku_option?:SkuOption;}interface LineItemOptionCreate extends ResourceCreate{name?:string;quantity:number;options:object;line_item:LineItemRel;sku_option:SkuOptionRel;}interface LineItemOptionUpdate extends ResourceUpdate{name?:string;quantity?:number;options?:object;sku_option?:SkuOptionRel;}declare class LineItemOptions extends ApiResource{static readonly TYPE:'line_item_options';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItemOption>>;create(resource:LineItemOptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItemOption>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItemOption>;update(resource:LineItemOptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItemOption>;delete(id:string,options?:ResourcesConfig):Promise<void>;line_item(lineItemOptionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;sku_option(lineItemOptionId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SkuOption>;isLineItemOption(resource:any):resource is LineItemOption;relationship(id:string|ResourceId|null):LineItemOptionRel;type():string;}export default LineItemOptions;export{LineItemOption,LineItemOptionCreate,LineItemOptionUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as r}from"../resource";class s extends r{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,i){return this.resources.create({...e,type:s.TYPE},t,i)}async retrieve(e,t,i){return this.resources.retrieve({type:s.TYPE,id:e},t,i)}async update(e,t,i){return this.resources.update({...e,type:s.TYPE},t,i)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async line_item(e,t,i){return this.resources.fetch({type:"line_items"},`line_item_options/${e}/line_item`,t,i)}async sku_option(e,t,i){return this.resources.fetch({type:"sku_options"},`line_item_options/${e}/sku_option`,t,i)}isLineItemOption(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="line_item_options";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Order}from'./orders';import{Adjustment}from'./adjustments';import{Bundle}from'./bundles';import{ExternalPromotion}from'./external_promotions';import{FixedAmountPromotion}from'./fixed_amount_promotions';import{FreeShippingPromotion}from'./free_shipping_promotions';import{GiftCard}from'./gift_cards';import{PaymentMethod}from'./payment_methods';import{PercentageDiscountPromotion}from'./percentage_discount_promotions';import{Shipment}from'./shipments';import{Sku}from'./skus';import{LineItemOption}from'./line_item_options';import{StockLineItem}from'./stock_line_items';import{StockTransfer}from'./stock_transfers';declare type LineItemRel=ResourceRel&{type:typeof LineItems.TYPE;};declare type OrderRel=ResourceRel&{type:'orders';};declare type AdjustmentRel=ResourceRel&{type:'adjustments';};declare type BundleRel=ResourceRel&{type:'bundles';};declare type ExternalPromotionRel=ResourceRel&{type:'external_promotions';};declare type FixedAmountPromotionRel=ResourceRel&{type:'fixed_amount_promotions';};declare type FreeShippingPromotionRel=ResourceRel&{type:'free_shipping_promotions';};declare type GiftCardRel=ResourceRel&{type:'gift_cards';};declare type PaymentMethodRel=ResourceRel&{type:'payment_methods';};declare type PercentageDiscountPromotionRel=ResourceRel&{type:'percentage_discount_promotions';};declare type ShipmentRel=ResourceRel&{type:'shipments';};declare type SkuRel=ResourceRel&{type:'skus';};interface LineItem extends Resource{sku_code?:string;bundle_code?:string;quantity?:number;currency_code?:string;unit_amount_cents?:number;unit_amount_float?:number;formatted_unit_amount?:string;options_amount_cents?:number;options_amount_float?:number;formatted_options_amount?:string;discount_cents?:number;discount_float?:number;formatted_discount?:string;total_amount_cents?:number;total_amount_float?:number;formatted_total_amount?:string;tax_amount_cents?:number;tax_amount_float?:number;formatted_tax_amount?:string;name?:string;image_url?:string;discount_breakdown?:object;tax_rate?:number;tax_breakdown?:object;item_type?:string;order?:Order;item?:Adjustment|Bundle|ExternalPromotion|FixedAmountPromotion|FreeShippingPromotion|GiftCard|PaymentMethod|PercentageDiscountPromotion|Shipment|Sku;line_item_options?:LineItemOption[];shipment_line_items?:object[];stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];}interface LineItemCreate extends ResourceCreate{sku_code?:string;bundle_code?:string;quantity:number;_external_price?:boolean;_update_quantity?:boolean;unit_amount_cents?:number;name?:string;image_url?:string;item_type?:string;order:OrderRel;item?:AdjustmentRel|BundleRel|ExternalPromotionRel|FixedAmountPromotionRel|FreeShippingPromotionRel|GiftCardRel|PaymentMethodRel|PercentageDiscountPromotionRel|ShipmentRel|SkuRel;}interface LineItemUpdate extends ResourceUpdate{sku_code?:string;bundle_code?:string;quantity?:number;name?:string;image_url?:string;}declare class LineItems extends ApiResource{static readonly TYPE:'line_items';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;create(resource:LineItemCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;update(resource:LineItemUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(lineItemId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;line_item_options(lineItemId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItemOption>>;stock_line_items(lineItemId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(lineItemId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;isLineItem(resource:any):resource is LineItem;relationship(id:string|ResourceId|null):LineItemRel;type():string;}export default LineItems;export{LineItem,LineItemCreate,LineItemUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class s extends i{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async order(e,t,r){return this.resources.fetch({type:"orders"},`line_items/${e}/order`,t,r)}async line_item_options(e,t,r){return this.resources.fetch({type:"line_item_options"},`line_items/${e}/line_item_options`,t,r)}async stock_line_items(e,t,r){return this.resources.fetch({type:"stock_line_items"},`line_items/${e}/stock_line_items`,t,r)}async stock_transfers(e,t,r){return this.resources.fetch({type:"stock_transfers"},`line_items/${e}/stock_transfers`,t,r)}isLineItem(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="line_items";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{PaymentMethod}from'./payment_methods';declare type ManualGatewayRel=ResourceRel&{type:typeof ManualGateways.TYPE;};interface ManualGateway extends Resource{name?:string;require_capture?:boolean;payment_methods?:PaymentMethod[];}interface ManualGatewayCreate extends ResourceCreate{name:string;require_capture?:boolean;}interface ManualGatewayUpdate extends ResourceUpdate{name?:string;require_capture?:boolean;}declare class ManualGateways extends ApiResource{static readonly TYPE:'manual_gateways';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ManualGateway>>;create(resource:ManualGatewayCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ManualGateway>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ManualGateway>;update(resource:ManualGatewayUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ManualGateway>;delete(id:string,options?:ResourcesConfig):Promise<void>;payment_methods(manualGatewayId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;isManualGateway(resource:any):resource is ManualGateway;relationship(id:string|ResourceId|null):ManualGatewayRel;type():string;}export default ManualGateways;export{ManualGateway,ManualGatewayCreate,ManualGatewayUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as a}from"../resource";class t extends a{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create({...e,type:t.TYPE},r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update({...e,type:t.TYPE},r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}async payment_methods(e,r,s){return this.resources.fetch({type:"payment_methods"},`manual_gateways/${e}/payment_methods`,r,s)}isManualGateway(e){return e.type&&e.type===t.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="manual_gateways";export default t;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{TaxCategory}from'./tax_categories';import{Market}from'./markets';import{Attachment}from'./attachments';import{TaxRule}from'./tax_rules';declare type ManualTaxCalculatorRel=ResourceRel&{type:typeof ManualTaxCalculators.TYPE;};declare type TaxCategoryRel=ResourceRel&{type:'tax_categories';};declare type TaxRuleRel=ResourceRel&{type:'tax_rules';};interface ManualTaxCalculator extends Resource{name?:string;tax_categories?:TaxCategory[];markets?:Market[];attachments?:Attachment[];tax_rules?:TaxRule[];}interface ManualTaxCalculatorCreate extends ResourceCreate{name:string;tax_categories?:TaxCategoryRel[];tax_rules?:TaxRuleRel[];}interface ManualTaxCalculatorUpdate extends ResourceUpdate{name?:string;tax_categories?:TaxCategoryRel[];tax_rules?:TaxRuleRel[];}declare class ManualTaxCalculators extends ApiResource{static readonly TYPE:'manual_tax_calculators';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ManualTaxCalculator>>;create(resource:ManualTaxCalculatorCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ManualTaxCalculator>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ManualTaxCalculator>;update(resource:ManualTaxCalculatorUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ManualTaxCalculator>;delete(id:string,options?:ResourcesConfig):Promise<void>;tax_categories(manualTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<TaxCategory>>;markets(manualTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Market>>;attachments(manualTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;tax_rules(manualTaxCalculatorId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<TaxRule>>;isManualTaxCalculator(resource:any):resource is ManualTaxCalculator;relationship(id:string|ResourceId|null):ManualTaxCalculatorRel;type():string;}export default ManualTaxCalculators;export{ManualTaxCalculator,ManualTaxCalculatorCreate,ManualTaxCalculatorUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as s}from"../resource";class r extends s{async list(t,e){return this.resources.list({type:r.TYPE},t,e)}async create(t,e,a){return this.resources.create({...t,type:r.TYPE},e,a)}async retrieve(t,e,a){return this.resources.retrieve({type:r.TYPE,id:t},e,a)}async update(t,e,a){return this.resources.update({...t,type:r.TYPE},e,a)}async delete(t,e){await this.resources.delete({type:r.TYPE,id:t},e)}async tax_categories(t,e,a){return this.resources.fetch({type:"tax_categories"},`manual_tax_calculators/${t}/tax_categories`,e,a)}async markets(t,e,a){return this.resources.fetch({type:"markets"},`manual_tax_calculators/${t}/markets`,e,a)}async attachments(t,e,a){return this.resources.fetch({type:"attachments"},`manual_tax_calculators/${t}/attachments`,e,a)}async tax_rules(t,e,a){return this.resources.fetch({type:"tax_rules"},`manual_tax_calculators/${t}/tax_rules`,e,a)}isManualTaxCalculator(t){return t.type&&t.type===r.TYPE}relationship(t){return t===null||typeof t=="string"?{id:t,type:r.TYPE}:{id:t.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="manual_tax_calculators";export default r;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Merchant}from'./merchants';import{PriceList}from'./price_lists';import{InventoryModel}from'./inventory_models';import{TaxCalculator}from'./tax_calculators';import{CustomerGroup}from'./customer_groups';import{Attachment}from'./attachments';declare type MarketRel=ResourceRel&{type:typeof Markets.TYPE;};declare type MerchantRel=ResourceRel&{type:'merchants';};declare type PriceListRel=ResourceRel&{type:'price_lists';};declare type InventoryModelRel=ResourceRel&{type:'inventory_models';};declare type TaxCalculatorRel=ResourceRel&{type:'tax_calculators';};declare type CustomerGroupRel=ResourceRel&{type:'customer_groups';};interface Market extends Resource{number?:number;name?:string;facebook_pixel_id?:string;checkout_url?:string;external_prices_url?:string;private?:boolean;merchant?:Merchant;price_list?:PriceList;inventory_model?:InventoryModel;tax_calculator?:TaxCalculator;customer_group?:CustomerGroup;attachments?:Attachment[];}interface MarketCreate extends ResourceCreate{name:string;facebook_pixel_id?:string;checkout_url?:string;external_prices_url?:string;merchant:MerchantRel;price_list:PriceListRel;inventory_model:InventoryModelRel;tax_calculator?:TaxCalculatorRel;customer_group?:CustomerGroupRel;}interface MarketUpdate extends ResourceUpdate{name?:string;facebook_pixel_id?:string;checkout_url?:string;external_prices_url?:string;merchant?:MerchantRel;price_list?:PriceListRel;inventory_model?:InventoryModelRel;tax_calculator?:TaxCalculatorRel;customer_group?:CustomerGroupRel;}declare class Markets extends ApiResource{static readonly TYPE:'markets';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Market>>;create(resource:MarketCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;update(resource:MarketUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;delete(id:string,options?:ResourcesConfig):Promise<void>;merchant(marketId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Merchant>;price_list(marketId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PriceList>;inventory_model(marketId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryModel>;tax_calculator(marketId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<TaxCalculator>;customer_group(marketId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerGroup>;attachments(marketId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isMarket(resource:any):resource is Market;relationship(id:string|ResourceId|null):MarketRel;type():string;}export default Markets;export{Market,MarketCreate,MarketUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as c}from"../resource";class s extends c{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async merchant(e,t,r){return this.resources.fetch({type:"merchants"},`markets/${e}/merchant`,t,r)}async price_list(e,t,r){return this.resources.fetch({type:"price_lists"},`markets/${e}/price_list`,t,r)}async inventory_model(e,t,r){return this.resources.fetch({type:"inventory_models"},`markets/${e}/inventory_model`,t,r)}async tax_calculator(e,t,r){return this.resources.fetch({type:"tax_calculators"},`markets/${e}/tax_calculator`,t,r)}async customer_group(e,t,r){return this.resources.fetch({type:"customer_groups"},`markets/${e}/customer_group`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`markets/${e}/attachments`,t,r)}isMarket(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="markets";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{Address}from'./addresses';import{Attachment}from'./attachments';declare type MerchantRel=ResourceRel&{type:typeof Merchants.TYPE;};declare type AddressRel=ResourceRel&{type:'addresses';};interface Merchant extends Resource{name?:string;address?:Address;attachments?:Attachment[];}interface MerchantCreate extends ResourceCreate{name:string;address:AddressRel;}interface MerchantUpdate extends ResourceUpdate{name?:string;address?:AddressRel;}declare class Merchants extends ApiResource{static readonly TYPE:'merchants';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Merchant>>;create(resource:MerchantCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Merchant>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Merchant>;update(resource:MerchantUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Merchant>;delete(id:string,options?:ResourcesConfig):Promise<void>;address(merchantId:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;attachments(merchantId:string,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;isMerchant(resource:any):resource is Merchant;relationship(id:string|ResourceId|null):MerchantRel;type():string;}export default Merchants;export{Merchant,MerchantCreate,MerchantUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as a}from"../resource";class s extends a{async list(e,t){return this.resources.list({type:s.TYPE},e,t)}async create(e,t,r){return this.resources.create({...e,type:s.TYPE},t,r)}async retrieve(e,t,r){return this.resources.retrieve({type:s.TYPE,id:e},t,r)}async update(e,t,r){return this.resources.update({...e,type:s.TYPE},t,r)}async delete(e,t){await this.resources.delete({type:s.TYPE,id:e},t)}async address(e,t,r){return this.resources.fetch({type:"addresses"},`merchants/${e}/address`,t,r)}async attachments(e,t,r){return this.resources.fetch({type:"attachments"},`merchants/${e}/attachments`,t,r)}isMerchant(e){return e.type&&e.type===s.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="merchants";export default s;
@@ -0,0 +1 @@
1
+ import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import{QueryParamsList,QueryParamsRetrieve}from'../query';import{PercentageDiscountPromotion}from'./percentage_discount_promotions';import{FreeShippingPromotion}from'./free_shipping_promotions';import{FixedAmountPromotion}from'./fixed_amount_promotions';import{FreeGiftPromotion}from'./free_gift_promotions';import{FixedPricePromotion}from'./fixed_price_promotions';import{ExternalPromotion}from'./external_promotions';declare type OrderAmountPromotionRuleRel=ResourceRel&{type:typeof OrderAmountPromotionRules.TYPE;};declare type PercentageDiscountPromotionRel=ResourceRel&{type:'percentage_discount_promotions';};declare type FreeShippingPromotionRel=ResourceRel&{type:'free_shipping_promotions';};declare type FixedAmountPromotionRel=ResourceRel&{type:'fixed_amount_promotions';};declare type FreeGiftPromotionRel=ResourceRel&{type:'free_gift_promotions';};declare type FixedPricePromotionRel=ResourceRel&{type:'fixed_price_promotions';};declare type ExternalPromotionRel=ResourceRel&{type:'external_promotions';};interface OrderAmountPromotionRule extends Resource{order_amount_cents?:number;order_amount_float?:number;formatted_order_amount?:string;promotion?:PercentageDiscountPromotion|FreeShippingPromotion|FixedAmountPromotion|FreeGiftPromotion|FixedPricePromotion|ExternalPromotion;}interface OrderAmountPromotionRuleCreate extends ResourceCreate{order_amount_cents?:number;promotion:PercentageDiscountPromotionRel|FreeShippingPromotionRel|FixedAmountPromotionRel|FreeGiftPromotionRel|FixedPricePromotionRel|ExternalPromotionRel;}interface OrderAmountPromotionRuleUpdate extends ResourceUpdate{order_amount_cents?:number;promotion?:PercentageDiscountPromotionRel|FreeShippingPromotionRel|FixedAmountPromotionRel|FreeGiftPromotionRel|FixedPricePromotionRel|ExternalPromotionRel;}declare class OrderAmountPromotionRules extends ApiResource{static readonly TYPE:'order_amount_promotion_rules';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderAmountPromotionRule>>;create(resource:OrderAmountPromotionRuleCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;update(resource:OrderAmountPromotionRuleUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderAmountPromotionRule>;delete(id:string,options?:ResourcesConfig):Promise<void>;isOrderAmountPromotionRule(resource:any):resource is OrderAmountPromotionRule;relationship(id:string|ResourceId|null):OrderAmountPromotionRuleRel;type():string;}export default OrderAmountPromotionRules;export{OrderAmountPromotionRule,OrderAmountPromotionRuleCreate,OrderAmountPromotionRuleUpdate};
@@ -0,0 +1 @@
1
+ import{ApiResource as i}from"../resource";class r extends i{async list(e,t){return this.resources.list({type:r.TYPE},e,t)}async create(e,t,s){return this.resources.create({...e,type:r.TYPE},t,s)}async retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}async update(e,t,s){return this.resources.update({...e,type:r.TYPE},t,s)}async delete(e,t){await this.resources.delete({type:r.TYPE,id:e},t)}isOrderAmountPromotionRule(e){return e.type&&e.type===r.TYPE}relationship(e){return e===null||typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="order_amount_promotion_rules";export default r;