@commercelayer/sdk 5.12.5 → 5.13.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.
- package/lib/cjs/api.d.ts +11 -2
- package/lib/cjs/api.js +4 -1
- package/lib/cjs/commercelayer.d.ts +4 -3
- package/lib/cjs/commercelayer.js +6 -1
- package/lib/cjs/config.js +3 -1
- package/lib/cjs/model.d.ts +1 -0
- package/lib/cjs/resource.d.ts +1 -1
- package/lib/cjs/resource.js +6 -0
- package/lib/cjs/resources/addresses.d.ts +3 -0
- package/lib/cjs/resources/addresses.js +4 -0
- package/lib/cjs/resources/adjustments.d.ts +5 -2
- package/lib/cjs/resources/adjustments.js +4 -0
- package/lib/cjs/resources/adyen_gateways.d.ts +3 -0
- package/lib/cjs/resources/adyen_gateways.js +4 -0
- package/lib/cjs/resources/adyen_payments.d.ts +5 -2
- package/lib/cjs/resources/adyen_payments.js +4 -0
- package/lib/cjs/resources/authorizations.d.ts +3 -0
- package/lib/cjs/resources/authorizations.js +4 -0
- package/lib/cjs/resources/avalara_accounts.d.ts +3 -0
- package/lib/cjs/resources/avalara_accounts.js +4 -0
- package/lib/cjs/resources/axerve_gateways.d.ts +4 -0
- package/lib/cjs/resources/axerve_gateways.js +4 -0
- package/lib/cjs/resources/axerve_payments.d.ts +5 -2
- package/lib/cjs/resources/axerve_payments.js +4 -0
- package/lib/cjs/resources/billing_info_validation_rules.d.ts +3 -0
- package/lib/cjs/resources/billing_info_validation_rules.js +4 -0
- package/lib/cjs/resources/braintree_gateways.d.ts +3 -0
- package/lib/cjs/resources/braintree_gateways.js +4 -0
- package/lib/cjs/resources/braintree_payments.d.ts +5 -2
- package/lib/cjs/resources/braintree_payments.js +4 -0
- package/lib/cjs/resources/bundles.d.ts +3 -0
- package/lib/cjs/resources/bundles.js +4 -0
- package/lib/cjs/resources/captures.d.ts +3 -0
- package/lib/cjs/resources/captures.js +4 -0
- package/lib/cjs/resources/carrier_accounts.d.ts +3 -0
- package/lib/cjs/resources/carrier_accounts.js +4 -0
- package/lib/cjs/resources/checkout_com_gateways.d.ts +3 -0
- package/lib/cjs/resources/checkout_com_gateways.js +4 -0
- package/lib/cjs/resources/checkout_com_payments.d.ts +5 -2
- package/lib/cjs/resources/checkout_com_payments.js +4 -0
- package/lib/cjs/resources/cleanups.d.ts +3 -0
- package/lib/cjs/resources/cleanups.js +4 -0
- package/lib/cjs/resources/coupon_codes_promotion_rules.d.ts +3 -0
- package/lib/cjs/resources/coupon_codes_promotion_rules.js +4 -0
- package/lib/cjs/resources/coupon_recipients.d.ts +3 -0
- package/lib/cjs/resources/coupon_recipients.js +4 -0
- package/lib/cjs/resources/coupons.d.ts +3 -0
- package/lib/cjs/resources/coupons.js +4 -0
- package/lib/cjs/resources/customer_addresses.d.ts +3 -0
- package/lib/cjs/resources/customer_addresses.js +4 -0
- package/lib/cjs/resources/customer_groups.d.ts +3 -0
- package/lib/cjs/resources/customer_groups.js +4 -0
- package/lib/cjs/resources/customer_payment_sources.d.ts +8 -13
- package/lib/cjs/resources/customer_payment_sources.js +4 -0
- package/lib/cjs/resources/customer_subscriptions.d.ts +3 -0
- package/lib/cjs/resources/customer_subscriptions.js +4 -0
- package/lib/cjs/resources/delivery_lead_times.d.ts +3 -0
- package/lib/cjs/resources/delivery_lead_times.js +4 -0
- package/lib/cjs/resources/external_gateways.d.ts +3 -0
- package/lib/cjs/resources/external_gateways.js +4 -0
- package/lib/cjs/resources/external_payments.d.ts +5 -2
- package/lib/cjs/resources/external_payments.js +4 -0
- package/lib/cjs/resources/external_promotions.d.ts +3 -0
- package/lib/cjs/resources/external_promotions.js +4 -0
- package/lib/cjs/resources/external_tax_calculators.d.ts +3 -0
- package/lib/cjs/resources/external_tax_calculators.js +4 -0
- package/lib/cjs/resources/fixed_amount_promotions.d.ts +3 -0
- package/lib/cjs/resources/fixed_amount_promotions.js +4 -0
- package/lib/cjs/resources/fixed_price_promotions.d.ts +3 -0
- package/lib/cjs/resources/fixed_price_promotions.js +4 -0
- package/lib/cjs/resources/free_gift_promotions.d.ts +3 -0
- package/lib/cjs/resources/free_gift_promotions.js +4 -0
- package/lib/cjs/resources/free_shipping_promotions.d.ts +3 -0
- package/lib/cjs/resources/free_shipping_promotions.js +4 -0
- package/lib/cjs/resources/gift_card_recipients.d.ts +3 -0
- package/lib/cjs/resources/gift_card_recipients.js +4 -0
- package/lib/cjs/resources/gift_cards.d.ts +3 -0
- package/lib/cjs/resources/gift_cards.js +4 -0
- package/lib/cjs/resources/in_stock_subscriptions.d.ts +3 -0
- package/lib/cjs/resources/in_stock_subscriptions.js +4 -0
- package/lib/cjs/resources/inventory_models.d.ts +3 -0
- package/lib/cjs/resources/inventory_models.js +4 -0
- package/lib/cjs/resources/inventory_return_locations.d.ts +5 -2
- package/lib/cjs/resources/inventory_return_locations.js +4 -0
- package/lib/cjs/resources/inventory_stock_locations.d.ts +5 -2
- package/lib/cjs/resources/inventory_stock_locations.js +4 -0
- package/lib/cjs/resources/klarna_gateways.d.ts +3 -0
- package/lib/cjs/resources/klarna_gateways.js +4 -0
- package/lib/cjs/resources/klarna_payments.d.ts +5 -2
- package/lib/cjs/resources/klarna_payments.js +4 -0
- package/lib/cjs/resources/manual_gateways.d.ts +3 -0
- package/lib/cjs/resources/manual_gateways.js +4 -0
- package/lib/cjs/resources/manual_tax_calculators.d.ts +3 -0
- package/lib/cjs/resources/manual_tax_calculators.js +4 -0
- package/lib/cjs/resources/markets.d.ts +3 -0
- package/lib/cjs/resources/markets.js +4 -0
- package/lib/cjs/resources/merchants.d.ts +3 -0
- package/lib/cjs/resources/merchants.js +4 -0
- package/lib/cjs/resources/order_amount_promotion_rules.d.ts +5 -2
- package/lib/cjs/resources/order_amount_promotion_rules.js +4 -0
- package/lib/cjs/resources/order_subscription_items.d.ts +3 -0
- package/lib/cjs/resources/order_subscription_items.js +4 -0
- package/lib/cjs/resources/order_subscriptions.d.ts +3 -0
- package/lib/cjs/resources/order_subscriptions.js +4 -0
- package/lib/cjs/resources/order_validation_rules.d.ts +3 -0
- package/lib/cjs/resources/order_validation_rules.js +4 -0
- package/lib/cjs/resources/orders.d.ts +8 -2
- package/lib/cjs/resources/orders.js +4 -0
- package/lib/cjs/resources/packages.d.ts +3 -0
- package/lib/cjs/resources/packages.js +4 -0
- package/lib/cjs/resources/parcel_line_items.d.ts +5 -2
- package/lib/cjs/resources/parcel_line_items.js +4 -0
- package/lib/cjs/resources/parcels.d.ts +3 -0
- package/lib/cjs/resources/parcels.js +4 -0
- package/lib/cjs/resources/payment_gateways.d.ts +3 -0
- package/lib/cjs/resources/payment_gateways.js +4 -0
- package/lib/cjs/resources/payment_methods.d.ts +3 -0
- package/lib/cjs/resources/payment_methods.js +4 -0
- package/lib/cjs/resources/paypal_gateways.d.ts +3 -0
- package/lib/cjs/resources/paypal_gateways.js +4 -0
- package/lib/cjs/resources/paypal_payments.d.ts +5 -2
- package/lib/cjs/resources/paypal_payments.js +4 -0
- package/lib/cjs/resources/percentage_discount_promotions.d.ts +3 -0
- package/lib/cjs/resources/percentage_discount_promotions.js +4 -0
- package/lib/cjs/resources/price_frequency_tiers.d.ts +3 -0
- package/lib/cjs/resources/price_frequency_tiers.js +4 -0
- package/lib/cjs/resources/price_lists.d.ts +3 -0
- package/lib/cjs/resources/price_lists.js +4 -0
- package/lib/cjs/resources/price_tiers.d.ts +3 -0
- package/lib/cjs/resources/price_tiers.js +4 -0
- package/lib/cjs/resources/price_volume_tiers.d.ts +3 -0
- package/lib/cjs/resources/price_volume_tiers.js +4 -0
- package/lib/cjs/resources/prices.d.ts +3 -0
- package/lib/cjs/resources/prices.js +4 -0
- package/lib/cjs/resources/promotion_rules.d.ts +5 -1
- package/lib/cjs/resources/promotion_rules.js +4 -0
- package/lib/cjs/resources/promotions.d.ts +3 -0
- package/lib/cjs/resources/promotions.js +4 -0
- package/lib/cjs/resources/refunds.d.ts +3 -0
- package/lib/cjs/resources/refunds.js +4 -0
- package/lib/cjs/resources/returns.d.ts +3 -0
- package/lib/cjs/resources/returns.js +4 -0
- package/lib/cjs/resources/satispay_gateways.d.ts +3 -0
- package/lib/cjs/resources/satispay_gateways.js +4 -0
- package/lib/cjs/resources/satispay_payments.d.ts +6 -2
- package/lib/cjs/resources/satispay_payments.js +4 -0
- package/lib/cjs/resources/shipments.d.ts +3 -0
- package/lib/cjs/resources/shipments.js +4 -0
- package/lib/cjs/resources/shipping_categories.d.ts +3 -0
- package/lib/cjs/resources/shipping_categories.js +4 -0
- package/lib/cjs/resources/shipping_method_tiers.d.ts +3 -0
- package/lib/cjs/resources/shipping_method_tiers.js +4 -0
- package/lib/cjs/resources/shipping_methods.d.ts +3 -0
- package/lib/cjs/resources/shipping_methods.js +4 -0
- package/lib/cjs/resources/shipping_weight_tiers.d.ts +3 -0
- package/lib/cjs/resources/shipping_weight_tiers.js +4 -0
- package/lib/cjs/resources/shipping_zones.d.ts +3 -0
- package/lib/cjs/resources/shipping_zones.js +4 -0
- package/lib/cjs/resources/sku_list_items.d.ts +5 -2
- package/lib/cjs/resources/sku_list_items.js +4 -0
- package/lib/cjs/resources/sku_list_promotion_rules.d.ts +3 -0
- package/lib/cjs/resources/sku_list_promotion_rules.js +4 -0
- package/lib/cjs/resources/sku_lists.d.ts +3 -0
- package/lib/cjs/resources/sku_lists.js +4 -0
- package/lib/cjs/resources/sku_options.d.ts +3 -0
- package/lib/cjs/resources/sku_options.js +4 -0
- package/lib/cjs/resources/skus.d.ts +3 -0
- package/lib/cjs/resources/skus.js +4 -0
- package/lib/cjs/resources/stock_items.d.ts +3 -0
- package/lib/cjs/resources/stock_items.js +4 -0
- package/lib/cjs/resources/stock_line_items.d.ts +5 -2
- package/lib/cjs/resources/stock_line_items.js +4 -0
- package/lib/cjs/resources/stock_locations.d.ts +3 -0
- package/lib/cjs/resources/stock_locations.js +4 -0
- package/lib/cjs/resources/stock_transfers.d.ts +3 -0
- package/lib/cjs/resources/stock_transfers.js +4 -0
- package/lib/cjs/resources/stripe_gateways.d.ts +3 -0
- package/lib/cjs/resources/stripe_gateways.js +4 -0
- package/lib/cjs/resources/stripe_payments.d.ts +8 -2
- package/lib/cjs/resources/stripe_payments.js +4 -0
- package/lib/cjs/resources/tax_calculators.d.ts +3 -0
- package/lib/cjs/resources/tax_calculators.js +4 -0
- package/lib/cjs/resources/tax_categories.d.ts +3 -0
- package/lib/cjs/resources/tax_categories.js +4 -0
- package/lib/cjs/resources/tax_rules.d.ts +5 -2
- package/lib/cjs/resources/tax_rules.js +4 -0
- package/lib/cjs/resources/taxjar_accounts.d.ts +3 -0
- package/lib/cjs/resources/taxjar_accounts.js +4 -0
- package/lib/cjs/resources/transactions.d.ts +3 -0
- package/lib/cjs/resources/transactions.js +4 -0
- package/lib/cjs/resources/versions.d.ts +22 -0
- package/lib/cjs/resources/versions.js +16 -0
- package/lib/cjs/resources/voids.d.ts +3 -0
- package/lib/cjs/resources/voids.js +4 -0
- package/lib/cjs/resources/webhooks.d.ts +3 -0
- package/lib/cjs/resources/webhooks.js +4 -0
- package/lib/cjs/resources/wire_transfers.d.ts +5 -2
- package/lib/cjs/resources/wire_transfers.js +4 -0
- package/lib/cjs/util.d.ts +1 -1
- package/lib/esm/api.d.ts +11 -2
- package/lib/esm/api.js +2 -0
- package/lib/esm/commercelayer.d.ts +4 -3
- package/lib/esm/commercelayer.js +6 -1
- package/lib/esm/config.js +3 -1
- package/lib/esm/model.d.ts +1 -0
- package/lib/esm/resource.d.ts +1 -1
- package/lib/esm/resource.js +6 -0
- package/lib/esm/resources/addresses.d.ts +3 -0
- package/lib/esm/resources/addresses.js +4 -0
- package/lib/esm/resources/adjustments.d.ts +5 -2
- package/lib/esm/resources/adjustments.js +4 -0
- package/lib/esm/resources/adyen_gateways.d.ts +3 -0
- package/lib/esm/resources/adyen_gateways.js +4 -0
- package/lib/esm/resources/adyen_payments.d.ts +5 -2
- package/lib/esm/resources/adyen_payments.js +4 -0
- package/lib/esm/resources/authorizations.d.ts +3 -0
- package/lib/esm/resources/authorizations.js +4 -0
- package/lib/esm/resources/avalara_accounts.d.ts +3 -0
- package/lib/esm/resources/avalara_accounts.js +4 -0
- package/lib/esm/resources/axerve_gateways.d.ts +4 -0
- package/lib/esm/resources/axerve_gateways.js +4 -0
- package/lib/esm/resources/axerve_payments.d.ts +5 -2
- package/lib/esm/resources/axerve_payments.js +4 -0
- package/lib/esm/resources/billing_info_validation_rules.d.ts +3 -0
- package/lib/esm/resources/billing_info_validation_rules.js +4 -0
- package/lib/esm/resources/braintree_gateways.d.ts +3 -0
- package/lib/esm/resources/braintree_gateways.js +4 -0
- package/lib/esm/resources/braintree_payments.d.ts +5 -2
- package/lib/esm/resources/braintree_payments.js +4 -0
- package/lib/esm/resources/bundles.d.ts +3 -0
- package/lib/esm/resources/bundles.js +4 -0
- package/lib/esm/resources/captures.d.ts +3 -0
- package/lib/esm/resources/captures.js +4 -0
- package/lib/esm/resources/carrier_accounts.d.ts +3 -0
- package/lib/esm/resources/carrier_accounts.js +4 -0
- package/lib/esm/resources/checkout_com_gateways.d.ts +3 -0
- package/lib/esm/resources/checkout_com_gateways.js +4 -0
- package/lib/esm/resources/checkout_com_payments.d.ts +5 -2
- package/lib/esm/resources/checkout_com_payments.js +4 -0
- package/lib/esm/resources/cleanups.d.ts +3 -0
- package/lib/esm/resources/cleanups.js +4 -0
- package/lib/esm/resources/coupon_codes_promotion_rules.d.ts +3 -0
- package/lib/esm/resources/coupon_codes_promotion_rules.js +4 -0
- package/lib/esm/resources/coupon_recipients.d.ts +3 -0
- package/lib/esm/resources/coupon_recipients.js +4 -0
- package/lib/esm/resources/coupons.d.ts +3 -0
- package/lib/esm/resources/coupons.js +4 -0
- package/lib/esm/resources/customer_addresses.d.ts +3 -0
- package/lib/esm/resources/customer_addresses.js +4 -0
- package/lib/esm/resources/customer_groups.d.ts +3 -0
- package/lib/esm/resources/customer_groups.js +4 -0
- package/lib/esm/resources/customer_payment_sources.d.ts +8 -13
- package/lib/esm/resources/customer_payment_sources.js +4 -0
- package/lib/esm/resources/customer_subscriptions.d.ts +3 -0
- package/lib/esm/resources/customer_subscriptions.js +4 -0
- package/lib/esm/resources/delivery_lead_times.d.ts +3 -0
- package/lib/esm/resources/delivery_lead_times.js +4 -0
- package/lib/esm/resources/external_gateways.d.ts +3 -0
- package/lib/esm/resources/external_gateways.js +4 -0
- package/lib/esm/resources/external_payments.d.ts +5 -2
- package/lib/esm/resources/external_payments.js +4 -0
- package/lib/esm/resources/external_promotions.d.ts +3 -0
- package/lib/esm/resources/external_promotions.js +4 -0
- package/lib/esm/resources/external_tax_calculators.d.ts +3 -0
- package/lib/esm/resources/external_tax_calculators.js +4 -0
- package/lib/esm/resources/fixed_amount_promotions.d.ts +3 -0
- package/lib/esm/resources/fixed_amount_promotions.js +4 -0
- package/lib/esm/resources/fixed_price_promotions.d.ts +3 -0
- package/lib/esm/resources/fixed_price_promotions.js +4 -0
- package/lib/esm/resources/free_gift_promotions.d.ts +3 -0
- package/lib/esm/resources/free_gift_promotions.js +4 -0
- package/lib/esm/resources/free_shipping_promotions.d.ts +3 -0
- package/lib/esm/resources/free_shipping_promotions.js +4 -0
- package/lib/esm/resources/gift_card_recipients.d.ts +3 -0
- package/lib/esm/resources/gift_card_recipients.js +4 -0
- package/lib/esm/resources/gift_cards.d.ts +3 -0
- package/lib/esm/resources/gift_cards.js +4 -0
- package/lib/esm/resources/in_stock_subscriptions.d.ts +3 -0
- package/lib/esm/resources/in_stock_subscriptions.js +4 -0
- package/lib/esm/resources/inventory_models.d.ts +3 -0
- package/lib/esm/resources/inventory_models.js +4 -0
- package/lib/esm/resources/inventory_return_locations.d.ts +5 -2
- package/lib/esm/resources/inventory_return_locations.js +4 -0
- package/lib/esm/resources/inventory_stock_locations.d.ts +5 -2
- package/lib/esm/resources/inventory_stock_locations.js +4 -0
- package/lib/esm/resources/klarna_gateways.d.ts +3 -0
- package/lib/esm/resources/klarna_gateways.js +4 -0
- package/lib/esm/resources/klarna_payments.d.ts +5 -2
- package/lib/esm/resources/klarna_payments.js +4 -0
- package/lib/esm/resources/manual_gateways.d.ts +3 -0
- package/lib/esm/resources/manual_gateways.js +4 -0
- package/lib/esm/resources/manual_tax_calculators.d.ts +3 -0
- package/lib/esm/resources/manual_tax_calculators.js +4 -0
- package/lib/esm/resources/markets.d.ts +3 -0
- package/lib/esm/resources/markets.js +4 -0
- package/lib/esm/resources/merchants.d.ts +3 -0
- package/lib/esm/resources/merchants.js +4 -0
- package/lib/esm/resources/order_amount_promotion_rules.d.ts +5 -2
- package/lib/esm/resources/order_amount_promotion_rules.js +4 -0
- package/lib/esm/resources/order_subscription_items.d.ts +3 -0
- package/lib/esm/resources/order_subscription_items.js +4 -0
- package/lib/esm/resources/order_subscriptions.d.ts +3 -0
- package/lib/esm/resources/order_subscriptions.js +4 -0
- package/lib/esm/resources/order_validation_rules.d.ts +3 -0
- package/lib/esm/resources/order_validation_rules.js +4 -0
- package/lib/esm/resources/orders.d.ts +8 -2
- package/lib/esm/resources/orders.js +4 -0
- package/lib/esm/resources/packages.d.ts +3 -0
- package/lib/esm/resources/packages.js +4 -0
- package/lib/esm/resources/parcel_line_items.d.ts +5 -2
- package/lib/esm/resources/parcel_line_items.js +4 -0
- package/lib/esm/resources/parcels.d.ts +3 -0
- package/lib/esm/resources/parcels.js +4 -0
- package/lib/esm/resources/payment_gateways.d.ts +3 -0
- package/lib/esm/resources/payment_gateways.js +4 -0
- package/lib/esm/resources/payment_methods.d.ts +3 -0
- package/lib/esm/resources/payment_methods.js +4 -0
- package/lib/esm/resources/paypal_gateways.d.ts +3 -0
- package/lib/esm/resources/paypal_gateways.js +4 -0
- package/lib/esm/resources/paypal_payments.d.ts +5 -2
- package/lib/esm/resources/paypal_payments.js +4 -0
- package/lib/esm/resources/percentage_discount_promotions.d.ts +3 -0
- package/lib/esm/resources/percentage_discount_promotions.js +4 -0
- package/lib/esm/resources/price_frequency_tiers.d.ts +3 -0
- package/lib/esm/resources/price_frequency_tiers.js +4 -0
- package/lib/esm/resources/price_lists.d.ts +3 -0
- package/lib/esm/resources/price_lists.js +4 -0
- package/lib/esm/resources/price_tiers.d.ts +3 -0
- package/lib/esm/resources/price_tiers.js +4 -0
- package/lib/esm/resources/price_volume_tiers.d.ts +3 -0
- package/lib/esm/resources/price_volume_tiers.js +4 -0
- package/lib/esm/resources/prices.d.ts +3 -0
- package/lib/esm/resources/prices.js +4 -0
- package/lib/esm/resources/promotion_rules.d.ts +5 -1
- package/lib/esm/resources/promotion_rules.js +4 -0
- package/lib/esm/resources/promotions.d.ts +3 -0
- package/lib/esm/resources/promotions.js +4 -0
- package/lib/esm/resources/refunds.d.ts +3 -0
- package/lib/esm/resources/refunds.js +4 -0
- package/lib/esm/resources/returns.d.ts +3 -0
- package/lib/esm/resources/returns.js +4 -0
- package/lib/esm/resources/satispay_gateways.d.ts +3 -0
- package/lib/esm/resources/satispay_gateways.js +4 -0
- package/lib/esm/resources/satispay_payments.d.ts +6 -2
- package/lib/esm/resources/satispay_payments.js +4 -0
- package/lib/esm/resources/shipments.d.ts +3 -0
- package/lib/esm/resources/shipments.js +4 -0
- package/lib/esm/resources/shipping_categories.d.ts +3 -0
- package/lib/esm/resources/shipping_categories.js +4 -0
- package/lib/esm/resources/shipping_method_tiers.d.ts +3 -0
- package/lib/esm/resources/shipping_method_tiers.js +4 -0
- package/lib/esm/resources/shipping_methods.d.ts +3 -0
- package/lib/esm/resources/shipping_methods.js +4 -0
- package/lib/esm/resources/shipping_weight_tiers.d.ts +3 -0
- package/lib/esm/resources/shipping_weight_tiers.js +4 -0
- package/lib/esm/resources/shipping_zones.d.ts +3 -0
- package/lib/esm/resources/shipping_zones.js +4 -0
- package/lib/esm/resources/sku_list_items.d.ts +5 -2
- package/lib/esm/resources/sku_list_items.js +4 -0
- package/lib/esm/resources/sku_list_promotion_rules.d.ts +3 -0
- package/lib/esm/resources/sku_list_promotion_rules.js +4 -0
- package/lib/esm/resources/sku_lists.d.ts +3 -0
- package/lib/esm/resources/sku_lists.js +4 -0
- package/lib/esm/resources/sku_options.d.ts +3 -0
- package/lib/esm/resources/sku_options.js +4 -0
- package/lib/esm/resources/skus.d.ts +3 -0
- package/lib/esm/resources/skus.js +4 -0
- package/lib/esm/resources/stock_items.d.ts +3 -0
- package/lib/esm/resources/stock_items.js +4 -0
- package/lib/esm/resources/stock_line_items.d.ts +5 -2
- package/lib/esm/resources/stock_line_items.js +4 -0
- package/lib/esm/resources/stock_locations.d.ts +3 -0
- package/lib/esm/resources/stock_locations.js +4 -0
- package/lib/esm/resources/stock_transfers.d.ts +3 -0
- package/lib/esm/resources/stock_transfers.js +4 -0
- package/lib/esm/resources/stripe_gateways.d.ts +3 -0
- package/lib/esm/resources/stripe_gateways.js +4 -0
- package/lib/esm/resources/stripe_payments.d.ts +8 -2
- package/lib/esm/resources/stripe_payments.js +4 -0
- package/lib/esm/resources/tax_calculators.d.ts +3 -0
- package/lib/esm/resources/tax_calculators.js +4 -0
- package/lib/esm/resources/tax_categories.d.ts +3 -0
- package/lib/esm/resources/tax_categories.js +4 -0
- package/lib/esm/resources/tax_rules.d.ts +5 -2
- package/lib/esm/resources/tax_rules.js +4 -0
- package/lib/esm/resources/taxjar_accounts.d.ts +3 -0
- package/lib/esm/resources/taxjar_accounts.js +4 -0
- package/lib/esm/resources/transactions.d.ts +3 -0
- package/lib/esm/resources/transactions.js +4 -0
- package/lib/esm/resources/versions.d.ts +22 -0
- package/lib/esm/resources/versions.js +14 -0
- package/lib/esm/resources/voids.d.ts +3 -0
- package/lib/esm/resources/voids.js +4 -0
- package/lib/esm/resources/webhooks.d.ts +3 -0
- package/lib/esm/resources/webhooks.js +4 -0
- package/lib/esm/resources/wire_transfers.d.ts +5 -2
- package/lib/esm/resources/wire_transfers.js +4 -0
- package/lib/esm/util.d.ts +1 -1
- package/lib/tsconfig.esm.tsbuildinfo +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +10 -10
@@ -13,6 +13,7 @@ import type { CarrierAccount } from './carrier_accounts';
|
|
13
13
|
import type { Parcel } from './parcels';
|
14
14
|
import type { Attachment } from './attachments';
|
15
15
|
import type { Event } from './events';
|
16
|
+
import type { Version } from './versions';
|
16
17
|
type ShipmentType = 'shipments';
|
17
18
|
type ShipmentRel = ResourceRel & {
|
18
19
|
type: ShipmentType;
|
@@ -62,6 +63,7 @@ interface Shipment extends Resource {
|
|
62
63
|
parcels?: Parcel[] | null;
|
63
64
|
attachments?: Attachment[] | null;
|
64
65
|
events?: Event[] | null;
|
66
|
+
versions?: Version[] | null;
|
65
67
|
}
|
66
68
|
interface ShipmentUpdate extends ResourceUpdate {
|
67
69
|
_on_hold?: boolean | null;
|
@@ -91,6 +93,7 @@ declare class Shipments extends ApiResource<Shipment> {
|
|
91
93
|
parcels(shipmentId: string | Shipment, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Parcel>>;
|
92
94
|
attachments(shipmentId: string | Shipment, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
93
95
|
events(shipmentId: string | Shipment, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Event>>;
|
96
|
+
versions(shipmentId: string | Shipment, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
94
97
|
_on_hold(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
|
95
98
|
_picking(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
|
96
99
|
_packing(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
|
@@ -59,6 +59,10 @@ class Shipments extends ApiResource {
|
|
59
59
|
const _shipmentId = shipmentId.id || shipmentId;
|
60
60
|
return this.resources.fetch({ type: 'events' }, `shipments/${_shipmentId}/events`, params, options);
|
61
61
|
}
|
62
|
+
async versions(shipmentId, params, options) {
|
63
|
+
const _shipmentId = shipmentId.id || shipmentId;
|
64
|
+
return this.resources.fetch({ type: 'versions' }, `shipments/${_shipmentId}/versions`, params, options);
|
65
|
+
}
|
62
66
|
async _on_hold(id, params, options) {
|
63
67
|
return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: Shipments.TYPE, _on_hold: true }, params, options);
|
64
68
|
}
|
@@ -3,6 +3,7 @@ import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesCon
|
|
3
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { Sku } from './skus';
|
5
5
|
import type { Attachment } from './attachments';
|
6
|
+
import type { Version } from './versions';
|
6
7
|
type ShippingCategoryType = 'shipping_categories';
|
7
8
|
type ShippingCategoryRel = ResourceRel & {
|
8
9
|
type: ShippingCategoryType;
|
@@ -12,6 +13,7 @@ interface ShippingCategory extends Resource {
|
|
12
13
|
name: string;
|
13
14
|
skus?: Sku[] | null;
|
14
15
|
attachments?: Attachment[] | null;
|
16
|
+
versions?: Version[] | null;
|
15
17
|
}
|
16
18
|
interface ShippingCategoryCreate extends ResourceCreate {
|
17
19
|
name: string;
|
@@ -26,6 +28,7 @@ declare class ShippingCategories extends ApiResource<ShippingCategory> {
|
|
26
28
|
delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
|
27
29
|
skus(shippingCategoryId: string | ShippingCategory, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
|
28
30
|
attachments(shippingCategoryId: string | ShippingCategory, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
31
|
+
versions(shippingCategoryId: string | ShippingCategory, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
29
32
|
isShippingCategory(resource: any): resource is ShippingCategory;
|
30
33
|
relationship(id: string | ResourceId | null): ShippingCategoryRel;
|
31
34
|
type(): ShippingCategoryType;
|
@@ -17,6 +17,10 @@ class ShippingCategories extends ApiResource {
|
|
17
17
|
const _shippingCategoryId = shippingCategoryId.id || shippingCategoryId;
|
18
18
|
return this.resources.fetch({ type: 'attachments' }, `shipping_categories/${_shippingCategoryId}/attachments`, params, options);
|
19
19
|
}
|
20
|
+
async versions(shippingCategoryId, params, options) {
|
21
|
+
const _shippingCategoryId = shippingCategoryId.id || shippingCategoryId;
|
22
|
+
return this.resources.fetch({ type: 'versions' }, `shipping_categories/${_shippingCategoryId}/versions`, params, options);
|
23
|
+
}
|
20
24
|
isShippingCategory(resource) {
|
21
25
|
return resource.type && (resource.type === ShippingCategories.TYPE);
|
22
26
|
}
|
@@ -3,6 +3,7 @@ import type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse }
|
|
3
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { ShippingMethod } from './shipping_methods';
|
5
5
|
import type { Attachment } from './attachments';
|
6
|
+
import type { Version } from './versions';
|
6
7
|
type ShippingMethodTierType = 'shipping_method_tiers';
|
7
8
|
type ShippingMethodTierRel = ResourceRel & {
|
8
9
|
type: ShippingMethodTierType;
|
@@ -16,11 +17,13 @@ interface ShippingMethodTier extends Resource {
|
|
16
17
|
formatted_price_amount?: string | null;
|
17
18
|
shipping_method?: ShippingMethod | null;
|
18
19
|
attachments?: Attachment[] | null;
|
20
|
+
versions?: Version[] | null;
|
19
21
|
}
|
20
22
|
declare class ShippingMethodTiers extends ApiResource<ShippingMethodTier> {
|
21
23
|
static readonly TYPE: ShippingMethodTierType;
|
22
24
|
shipping_method(shippingMethodTierId: string | ShippingMethodTier, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingMethod>;
|
23
25
|
attachments(shippingMethodTierId: string | ShippingMethodTier, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
26
|
+
versions(shippingMethodTierId: string | ShippingMethodTier, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
24
27
|
isShippingMethodTier(resource: any): resource is ShippingMethodTier;
|
25
28
|
relationship(id: string | ResourceId | null): ShippingMethodTierRel;
|
26
29
|
type(): ShippingMethodTierType;
|
@@ -8,6 +8,10 @@ class ShippingMethodTiers extends ApiResource {
|
|
8
8
|
const _shippingMethodTierId = shippingMethodTierId.id || shippingMethodTierId;
|
9
9
|
return this.resources.fetch({ type: 'attachments' }, `shipping_method_tiers/${_shippingMethodTierId}/attachments`, params, options);
|
10
10
|
}
|
11
|
+
async versions(shippingMethodTierId, params, options) {
|
12
|
+
const _shippingMethodTierId = shippingMethodTierId.id || shippingMethodTierId;
|
13
|
+
return this.resources.fetch({ type: 'versions' }, `shipping_method_tiers/${_shippingMethodTierId}/versions`, params, options);
|
14
|
+
}
|
11
15
|
isShippingMethodTier(resource) {
|
12
16
|
return resource.type && (resource.type === ShippingMethodTiers.TYPE);
|
13
17
|
}
|
@@ -9,6 +9,7 @@ import type { DeliveryLeadTime } from './delivery_lead_times';
|
|
9
9
|
import type { ShippingMethodTier, ShippingMethodTierType } from './shipping_method_tiers';
|
10
10
|
import type { ShippingWeightTier } from './shipping_weight_tiers';
|
11
11
|
import type { Attachment } from './attachments';
|
12
|
+
import type { Version } from './versions';
|
12
13
|
type ShippingMethodType = 'shipping_methods';
|
13
14
|
type ShippingMethodRel = ResourceRel & {
|
14
15
|
type: ShippingMethodType;
|
@@ -56,6 +57,7 @@ interface ShippingMethod extends Resource {
|
|
56
57
|
shipping_method_tiers?: ShippingMethodTier[] | null;
|
57
58
|
shipping_weight_tiers?: ShippingWeightTier[] | null;
|
58
59
|
attachments?: Attachment[] | null;
|
60
|
+
versions?: Version[] | null;
|
59
61
|
}
|
60
62
|
interface ShippingMethodCreate extends ResourceCreate {
|
61
63
|
name: string;
|
@@ -106,6 +108,7 @@ declare class ShippingMethods extends ApiResource<ShippingMethod> {
|
|
106
108
|
shipping_method_tiers(shippingMethodId: string | ShippingMethod, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<ShippingMethodTier>>;
|
107
109
|
shipping_weight_tiers(shippingMethodId: string | ShippingMethod, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<ShippingWeightTier>>;
|
108
110
|
attachments(shippingMethodId: string | ShippingMethod, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
111
|
+
versions(shippingMethodId: string | ShippingMethod, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
109
112
|
_disable(id: string | ShippingMethod, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingMethod>;
|
110
113
|
_enable(id: string | ShippingMethod, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingMethod>;
|
111
114
|
isShippingMethod(resource: any): resource is ShippingMethod;
|
@@ -41,6 +41,10 @@ class ShippingMethods extends ApiResource {
|
|
41
41
|
const _shippingMethodId = shippingMethodId.id || shippingMethodId;
|
42
42
|
return this.resources.fetch({ type: 'attachments' }, `shipping_methods/${_shippingMethodId}/attachments`, params, options);
|
43
43
|
}
|
44
|
+
async versions(shippingMethodId, params, options) {
|
45
|
+
const _shippingMethodId = shippingMethodId.id || shippingMethodId;
|
46
|
+
return this.resources.fetch({ type: 'versions' }, `shipping_methods/${_shippingMethodId}/versions`, params, options);
|
47
|
+
}
|
44
48
|
async _disable(id, params, options) {
|
45
49
|
return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: ShippingMethods.TYPE, _disable: true }, params, options);
|
46
50
|
}
|
@@ -3,6 +3,7 @@ import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesCon
|
|
3
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { ShippingMethod, ShippingMethodType } from './shipping_methods';
|
5
5
|
import type { Attachment } from './attachments';
|
6
|
+
import type { Version } from './versions';
|
6
7
|
type ShippingWeightTierType = 'shipping_weight_tiers';
|
7
8
|
type ShippingWeightTierRel = ResourceRel & {
|
8
9
|
type: ShippingWeightTierType;
|
@@ -19,6 +20,7 @@ interface ShippingWeightTier extends Resource {
|
|
19
20
|
formatted_price_amount?: string | null;
|
20
21
|
shipping_method?: ShippingMethod | null;
|
21
22
|
attachments?: Attachment[] | null;
|
23
|
+
versions?: Version[] | null;
|
22
24
|
}
|
23
25
|
interface ShippingWeightTierCreate extends ResourceCreate {
|
24
26
|
name: string;
|
@@ -39,6 +41,7 @@ declare class ShippingWeightTiers extends ApiResource<ShippingWeightTier> {
|
|
39
41
|
delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
|
40
42
|
shipping_method(shippingWeightTierId: string | ShippingWeightTier, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingMethod>;
|
41
43
|
attachments(shippingWeightTierId: string | ShippingWeightTier, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
44
|
+
versions(shippingWeightTierId: string | ShippingWeightTier, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
42
45
|
isShippingWeightTier(resource: any): resource is ShippingWeightTier;
|
43
46
|
relationship(id: string | ResourceId | null): ShippingWeightTierRel;
|
44
47
|
type(): ShippingWeightTierType;
|
@@ -17,6 +17,10 @@ class ShippingWeightTiers extends ApiResource {
|
|
17
17
|
const _shippingWeightTierId = shippingWeightTierId.id || shippingWeightTierId;
|
18
18
|
return this.resources.fetch({ type: 'attachments' }, `shipping_weight_tiers/${_shippingWeightTierId}/attachments`, params, options);
|
19
19
|
}
|
20
|
+
async versions(shippingWeightTierId, params, options) {
|
21
|
+
const _shippingWeightTierId = shippingWeightTierId.id || shippingWeightTierId;
|
22
|
+
return this.resources.fetch({ type: 'versions' }, `shipping_weight_tiers/${_shippingWeightTierId}/versions`, params, options);
|
23
|
+
}
|
20
24
|
isShippingWeightTier(resource) {
|
21
25
|
return resource.type && (resource.type === ShippingWeightTiers.TYPE);
|
22
26
|
}
|
@@ -2,6 +2,7 @@ import { ApiResource } from '../resource';
|
|
2
2
|
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
3
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { Attachment } from './attachments';
|
5
|
+
import type { Version } from './versions';
|
5
6
|
type ShippingZoneType = 'shipping_zones';
|
6
7
|
type ShippingZoneRel = ResourceRel & {
|
7
8
|
type: ShippingZoneType;
|
@@ -16,6 +17,7 @@ interface ShippingZone extends Resource {
|
|
16
17
|
zip_code_regex?: string | null;
|
17
18
|
not_zip_code_regex?: string | null;
|
18
19
|
attachments?: Attachment[] | null;
|
20
|
+
versions?: Version[] | null;
|
19
21
|
}
|
20
22
|
interface ShippingZoneCreate extends ResourceCreate {
|
21
23
|
name: string;
|
@@ -41,6 +43,7 @@ declare class ShippingZones extends ApiResource<ShippingZone> {
|
|
41
43
|
update(resource: ShippingZoneUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingZone>;
|
42
44
|
delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
|
43
45
|
attachments(shippingZoneId: string | ShippingZone, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
46
|
+
versions(shippingZoneId: string | ShippingZone, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
44
47
|
isShippingZone(resource: any): resource is ShippingZone;
|
45
48
|
relationship(id: string | ResourceId | null): ShippingZoneRel;
|
46
49
|
type(): ShippingZoneType;
|
@@ -13,6 +13,10 @@ class ShippingZones extends ApiResource {
|
|
13
13
|
const _shippingZoneId = shippingZoneId.id || shippingZoneId;
|
14
14
|
return this.resources.fetch({ type: 'attachments' }, `shipping_zones/${_shippingZoneId}/attachments`, params, options);
|
15
15
|
}
|
16
|
+
async versions(shippingZoneId, params, options) {
|
17
|
+
const _shippingZoneId = shippingZoneId.id || shippingZoneId;
|
18
|
+
return this.resources.fetch({ type: 'versions' }, `shipping_zones/${_shippingZoneId}/versions`, params, options);
|
19
|
+
}
|
16
20
|
isShippingZone(resource) {
|
17
21
|
return resource.type && (resource.type === ShippingZones.TYPE);
|
18
22
|
}
|
@@ -1,8 +1,9 @@
|
|
1
1
|
import { ApiResource } from '../resource';
|
2
|
-
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
3
|
-
import type { QueryParamsRetrieve } from '../query';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
3
|
+
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { SkuList, SkuListType } from './sku_lists';
|
5
5
|
import type { Sku, SkuType } from './skus';
|
6
|
+
import type { Version } from './versions';
|
6
7
|
type SkuListItemType = 'sku_list_items';
|
7
8
|
type SkuListItemRel = ResourceRel & {
|
8
9
|
type: SkuListItemType;
|
@@ -20,6 +21,7 @@ interface SkuListItem extends Resource {
|
|
20
21
|
quantity?: number | null;
|
21
22
|
sku_list?: SkuList | null;
|
22
23
|
sku?: Sku | null;
|
24
|
+
versions?: Version[] | null;
|
23
25
|
}
|
24
26
|
interface SkuListItemCreate extends ResourceCreate {
|
25
27
|
position?: number | null;
|
@@ -40,6 +42,7 @@ declare class SkuListItems extends ApiResource<SkuListItem> {
|
|
40
42
|
delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
|
41
43
|
sku_list(skuListItemId: string | SkuListItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
|
42
44
|
sku(skuListItemId: string | SkuListItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
|
45
|
+
versions(skuListItemId: string | SkuListItem, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
43
46
|
isSkuListItem(resource: any): resource is SkuListItem;
|
44
47
|
relationship(id: string | ResourceId | null): SkuListItemRel;
|
45
48
|
type(): SkuListItemType;
|
@@ -17,6 +17,10 @@ class SkuListItems extends ApiResource {
|
|
17
17
|
const _skuListItemId = skuListItemId.id || skuListItemId;
|
18
18
|
return this.resources.fetch({ type: 'skus' }, `sku_list_items/${_skuListItemId}/sku`, params, options);
|
19
19
|
}
|
20
|
+
async versions(skuListItemId, params, options) {
|
21
|
+
const _skuListItemId = skuListItemId.id || skuListItemId;
|
22
|
+
return this.resources.fetch({ type: 'versions' }, `sku_list_items/${_skuListItemId}/versions`, params, options);
|
23
|
+
}
|
20
24
|
isSkuListItem(resource) {
|
21
25
|
return resource.type && (resource.type === SkuListItems.TYPE);
|
22
26
|
}
|
@@ -7,6 +7,7 @@ import type { FreeGiftPromotion, FreeGiftPromotionType } from './free_gift_promo
|
|
7
7
|
import type { FixedPricePromotion, FixedPricePromotionType } from './fixed_price_promotions';
|
8
8
|
import type { ExternalPromotion, ExternalPromotionType } from './external_promotions';
|
9
9
|
import type { FixedAmountPromotion, FixedAmountPromotionType } from './fixed_amount_promotions';
|
10
|
+
import type { Version } from './versions';
|
10
11
|
import type { SkuList, SkuListType } from './sku_lists';
|
11
12
|
import type { Sku } from './skus';
|
12
13
|
type SkuListPromotionRuleType = 'sku_list_promotion_rules';
|
@@ -39,6 +40,7 @@ interface SkuListPromotionRule extends Resource {
|
|
39
40
|
all_skus?: boolean | null;
|
40
41
|
min_quantity?: number | null;
|
41
42
|
promotion?: PercentageDiscountPromotion | FreeShippingPromotion | FreeGiftPromotion | FixedPricePromotion | ExternalPromotion | FixedAmountPromotion | null;
|
43
|
+
versions?: Version[] | null;
|
42
44
|
sku_list?: SkuList | null;
|
43
45
|
skus?: Sku[] | null;
|
44
46
|
}
|
@@ -59,6 +61,7 @@ declare class SkuListPromotionRules extends ApiResource<SkuListPromotionRule> {
|
|
59
61
|
create(resource: SkuListPromotionRuleCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuListPromotionRule>;
|
60
62
|
update(resource: SkuListPromotionRuleUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuListPromotionRule>;
|
61
63
|
delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
|
64
|
+
versions(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
62
65
|
sku_list(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SkuList>;
|
63
66
|
skus(skuListPromotionRuleId: string | SkuListPromotionRule, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Sku>>;
|
64
67
|
isSkuListPromotionRule(resource: any): resource is SkuListPromotionRule;
|
@@ -9,6 +9,10 @@ class SkuListPromotionRules extends ApiResource {
|
|
9
9
|
async delete(id, options) {
|
10
10
|
await this.resources.delete((typeof id === 'string') ? { id, type: SkuListPromotionRules.TYPE } : id, options);
|
11
11
|
}
|
12
|
+
async versions(skuListPromotionRuleId, params, options) {
|
13
|
+
const _skuListPromotionRuleId = skuListPromotionRuleId.id || skuListPromotionRuleId;
|
14
|
+
return this.resources.fetch({ type: 'versions' }, `sku_list_promotion_rules/${_skuListPromotionRuleId}/versions`, params, options);
|
15
|
+
}
|
12
16
|
async sku_list(skuListPromotionRuleId, params, options) {
|
13
17
|
const _skuListPromotionRuleId = skuListPromotionRuleId.id || skuListPromotionRuleId;
|
14
18
|
return this.resources.fetch({ type: 'sku_lists' }, `sku_list_promotion_rules/${_skuListPromotionRuleId}/sku_list`, params, options);
|
@@ -6,6 +6,7 @@ import type { Sku } from './skus';
|
|
6
6
|
import type { SkuListItem } from './sku_list_items';
|
7
7
|
import type { Bundle } from './bundles';
|
8
8
|
import type { Attachment } from './attachments';
|
9
|
+
import type { Version } from './versions';
|
9
10
|
type SkuListType = 'sku_lists';
|
10
11
|
type SkuListRel = ResourceRel & {
|
11
12
|
type: SkuListType;
|
@@ -26,6 +27,7 @@ interface SkuList extends Resource {
|
|
26
27
|
sku_list_items?: SkuListItem[] | null;
|
27
28
|
bundles?: Bundle[] | null;
|
28
29
|
attachments?: Attachment[] | null;
|
30
|
+
versions?: Version[] | null;
|
29
31
|
}
|
30
32
|
interface SkuListCreate extends ResourceCreate {
|
31
33
|
name: string;
|
@@ -53,6 +55,7 @@ declare class SkuLists extends ApiResource<SkuList> {
|
|
53
55
|
sku_list_items(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SkuListItem>>;
|
54
56
|
bundles(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Bundle>>;
|
55
57
|
attachments(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
58
|
+
versions(skuListId: string | SkuList, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
56
59
|
isSkuList(resource: any): resource is SkuList;
|
57
60
|
relationship(id: string | ResourceId | null): SkuListRel;
|
58
61
|
type(): SkuListType;
|
@@ -29,6 +29,10 @@ class SkuLists extends ApiResource {
|
|
29
29
|
const _skuListId = skuListId.id || skuListId;
|
30
30
|
return this.resources.fetch({ type: 'attachments' }, `sku_lists/${_skuListId}/attachments`, params, options);
|
31
31
|
}
|
32
|
+
async versions(skuListId, params, options) {
|
33
|
+
const _skuListId = skuListId.id || skuListId;
|
34
|
+
return this.resources.fetch({ type: 'versions' }, `sku_lists/${_skuListId}/versions`, params, options);
|
35
|
+
}
|
32
36
|
isSkuList(resource) {
|
33
37
|
return resource.type && (resource.type === SkuLists.TYPE);
|
34
38
|
}
|
@@ -5,6 +5,7 @@ import type { Market, MarketType } from './markets';
|
|
5
5
|
import type { Attachment } from './attachments';
|
6
6
|
import type { Event } from './events';
|
7
7
|
import type { Tag, TagType } from './tags';
|
8
|
+
import type { Version } from './versions';
|
8
9
|
type SkuOptionType = 'sku_options';
|
9
10
|
type SkuOptionRel = ResourceRel & {
|
10
11
|
type: SkuOptionType;
|
@@ -30,6 +31,7 @@ interface SkuOption extends Resource {
|
|
30
31
|
attachments?: Attachment[] | null;
|
31
32
|
events?: Event[] | null;
|
32
33
|
tags?: Tag[] | null;
|
34
|
+
versions?: Version[] | null;
|
33
35
|
}
|
34
36
|
interface SkuOptionCreate extends ResourceCreate {
|
35
37
|
name: string;
|
@@ -60,6 +62,7 @@ declare class SkuOptions extends ApiResource<SkuOption> {
|
|
60
62
|
attachments(skuOptionId: string | SkuOption, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
61
63
|
events(skuOptionId: string | SkuOption, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Event>>;
|
62
64
|
tags(skuOptionId: string | SkuOption, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Tag>>;
|
65
|
+
versions(skuOptionId: string | SkuOption, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
63
66
|
isSkuOption(resource: any): resource is SkuOption;
|
64
67
|
relationship(id: string | ResourceId | null): SkuOptionRel;
|
65
68
|
type(): SkuOptionType;
|
@@ -25,6 +25,10 @@ class SkuOptions extends ApiResource {
|
|
25
25
|
const _skuOptionId = skuOptionId.id || skuOptionId;
|
26
26
|
return this.resources.fetch({ type: 'tags' }, `sku_options/${_skuOptionId}/tags`, params, options);
|
27
27
|
}
|
28
|
+
async versions(skuOptionId, params, options) {
|
29
|
+
const _skuOptionId = skuOptionId.id || skuOptionId;
|
30
|
+
return this.resources.fetch({ type: 'versions' }, `sku_options/${_skuOptionId}/versions`, params, options);
|
31
|
+
}
|
28
32
|
isSkuOption(resource) {
|
29
33
|
return resource.type && (resource.type === SkuOptions.TYPE);
|
30
34
|
}
|
@@ -10,6 +10,7 @@ import type { SkuOption } from './sku_options';
|
|
10
10
|
import type { Attachment } from './attachments';
|
11
11
|
import type { Event } from './events';
|
12
12
|
import type { Tag, TagType } from './tags';
|
13
|
+
import type { Version } from './versions';
|
13
14
|
type SkuType = 'skus';
|
14
15
|
type SkuRel = ResourceRel & {
|
15
16
|
type: SkuType;
|
@@ -42,6 +43,7 @@ interface Sku extends Resource {
|
|
42
43
|
attachments?: Attachment[] | null;
|
43
44
|
events?: Event[] | null;
|
44
45
|
tags?: Tag[] | null;
|
46
|
+
versions?: Version[] | null;
|
45
47
|
}
|
46
48
|
interface SkuCreate extends ResourceCreate {
|
47
49
|
code: string;
|
@@ -85,6 +87,7 @@ declare class Skus extends ApiResource<Sku> {
|
|
85
87
|
attachments(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
86
88
|
events(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Event>>;
|
87
89
|
tags(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Tag>>;
|
90
|
+
versions(skuId: string | Sku, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
88
91
|
isSku(resource: any): resource is Sku;
|
89
92
|
relationship(id: string | ResourceId | null): SkuRel;
|
90
93
|
type(): SkuType;
|
@@ -45,6 +45,10 @@ class Skus extends ApiResource {
|
|
45
45
|
const _skuId = skuId.id || skuId;
|
46
46
|
return this.resources.fetch({ type: 'tags' }, `skus/${_skuId}/tags`, params, options);
|
47
47
|
}
|
48
|
+
async versions(skuId, params, options) {
|
49
|
+
const _skuId = skuId.id || skuId;
|
50
|
+
return this.resources.fetch({ type: 'versions' }, `skus/${_skuId}/versions`, params, options);
|
51
|
+
}
|
48
52
|
isSku(resource) {
|
49
53
|
return resource.type && (resource.type === Skus.TYPE);
|
50
54
|
}
|
@@ -6,6 +6,7 @@ import type { Sku, SkuType } from './skus';
|
|
6
6
|
import type { ReservedStock } from './reserved_stocks';
|
7
7
|
import type { StockReservation } from './stock_reservations';
|
8
8
|
import type { Attachment } from './attachments';
|
9
|
+
import type { Version } from './versions';
|
9
10
|
type StockItemType = 'stock_items';
|
10
11
|
type StockItemRel = ResourceRel & {
|
11
12
|
type: StockItemType;
|
@@ -25,6 +26,7 @@ interface StockItem extends Resource {
|
|
25
26
|
reserved_stock?: ReservedStock | null;
|
26
27
|
stock_reservations?: StockReservation[] | null;
|
27
28
|
attachments?: Attachment[] | null;
|
29
|
+
versions?: Version[] | null;
|
28
30
|
}
|
29
31
|
interface StockItemCreate extends ResourceCreate {
|
30
32
|
sku_code?: string | null;
|
@@ -48,6 +50,7 @@ declare class StockItems extends ApiResource<StockItem> {
|
|
48
50
|
reserved_stock(stockItemId: string | StockItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ReservedStock>;
|
49
51
|
stock_reservations(stockItemId: string | StockItem, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockReservation>>;
|
50
52
|
attachments(stockItemId: string | StockItem, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
53
|
+
versions(stockItemId: string | StockItem, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
51
54
|
isStockItem(resource: any): resource is StockItem;
|
52
55
|
relationship(id: string | ResourceId | null): StockItemRel;
|
53
56
|
type(): StockItemType;
|
@@ -29,6 +29,10 @@ class StockItems extends ApiResource {
|
|
29
29
|
const _stockItemId = stockItemId.id || stockItemId;
|
30
30
|
return this.resources.fetch({ type: 'attachments' }, `stock_items/${_stockItemId}/attachments`, params, options);
|
31
31
|
}
|
32
|
+
async versions(stockItemId, params, options) {
|
33
|
+
const _stockItemId = stockItemId.id || stockItemId;
|
34
|
+
return this.resources.fetch({ type: 'versions' }, `stock_items/${_stockItemId}/versions`, params, options);
|
35
|
+
}
|
32
36
|
isStockItem(resource) {
|
33
37
|
return resource.type && (resource.type === StockItems.TYPE);
|
34
38
|
}
|
@@ -1,10 +1,11 @@
|
|
1
1
|
import { ApiResource } from '../resource';
|
2
|
-
import type { Resource, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
3
|
-
import type { QueryParamsRetrieve } from '../query';
|
2
|
+
import type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
3
|
+
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { Shipment } from './shipments';
|
5
5
|
import type { LineItem } from './line_items';
|
6
6
|
import type { StockItem } from './stock_items';
|
7
7
|
import type { Sku } from './skus';
|
8
|
+
import type { Version } from './versions';
|
8
9
|
type StockLineItemType = 'stock_line_items';
|
9
10
|
type StockLineItemRel = ResourceRel & {
|
10
11
|
type: StockLineItemType;
|
@@ -18,6 +19,7 @@ interface StockLineItem extends Resource {
|
|
18
19
|
line_item?: LineItem | null;
|
19
20
|
stock_item?: StockItem | null;
|
20
21
|
sku?: Sku | null;
|
22
|
+
versions?: Version[] | null;
|
21
23
|
}
|
22
24
|
declare class StockLineItems extends ApiResource<StockLineItem> {
|
23
25
|
static readonly TYPE: StockLineItemType;
|
@@ -25,6 +27,7 @@ declare class StockLineItems extends ApiResource<StockLineItem> {
|
|
25
27
|
line_item(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
|
26
28
|
stock_item(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
|
27
29
|
sku(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
|
30
|
+
versions(stockLineItemId: string | StockLineItem, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
28
31
|
isStockLineItem(resource: any): resource is StockLineItem;
|
29
32
|
relationship(id: string | ResourceId | null): StockLineItemRel;
|
30
33
|
type(): StockLineItemType;
|
@@ -16,6 +16,10 @@ class StockLineItems extends ApiResource {
|
|
16
16
|
const _stockLineItemId = stockLineItemId.id || stockLineItemId;
|
17
17
|
return this.resources.fetch({ type: 'skus' }, `stock_line_items/${_stockLineItemId}/sku`, params, options);
|
18
18
|
}
|
19
|
+
async versions(stockLineItemId, params, options) {
|
20
|
+
const _stockLineItemId = stockLineItemId.id || stockLineItemId;
|
21
|
+
return this.resources.fetch({ type: 'versions' }, `stock_line_items/${_stockLineItemId}/versions`, params, options);
|
22
|
+
}
|
19
23
|
isStockLineItem(resource) {
|
20
24
|
return resource.type && (resource.type === StockLineItems.TYPE);
|
21
25
|
}
|
@@ -7,6 +7,7 @@ import type { InventoryReturnLocation } from './inventory_return_locations';
|
|
7
7
|
import type { StockItem } from './stock_items';
|
8
8
|
import type { StockTransfer } from './stock_transfers';
|
9
9
|
import type { Attachment } from './attachments';
|
10
|
+
import type { Version } from './versions';
|
10
11
|
type StockLocationType = 'stock_locations';
|
11
12
|
type StockLocationRel = ResourceRel & {
|
12
13
|
type: StockLocationType;
|
@@ -26,6 +27,7 @@ interface StockLocation extends Resource {
|
|
26
27
|
stock_items?: StockItem[] | null;
|
27
28
|
stock_transfers?: StockTransfer[] | null;
|
28
29
|
attachments?: Attachment[] | null;
|
30
|
+
versions?: Version[] | null;
|
29
31
|
}
|
30
32
|
interface StockLocationCreate extends ResourceCreate {
|
31
33
|
name: string;
|
@@ -50,6 +52,7 @@ declare class StockLocations extends ApiResource<StockLocation> {
|
|
50
52
|
stock_items(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockItem>>;
|
51
53
|
stock_transfers(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StockTransfer>>;
|
52
54
|
attachments(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Attachment>>;
|
55
|
+
versions(stockLocationId: string | StockLocation, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
53
56
|
isStockLocation(resource: any): resource is StockLocation;
|
54
57
|
relationship(id: string | ResourceId | null): StockLocationRel;
|
55
58
|
type(): StockLocationType;
|
@@ -33,6 +33,10 @@ class StockLocations extends ApiResource {
|
|
33
33
|
const _stockLocationId = stockLocationId.id || stockLocationId;
|
34
34
|
return this.resources.fetch({ type: 'attachments' }, `stock_locations/${_stockLocationId}/attachments`, params, options);
|
35
35
|
}
|
36
|
+
async versions(stockLocationId, params, options) {
|
37
|
+
const _stockLocationId = stockLocationId.id || stockLocationId;
|
38
|
+
return this.resources.fetch({ type: 'versions' }, `stock_locations/${_stockLocationId}/versions`, params, options);
|
39
|
+
}
|
36
40
|
isStockLocation(resource) {
|
37
41
|
return resource.type && (resource.type === StockLocations.TYPE);
|
38
42
|
}
|
@@ -6,6 +6,7 @@ import type { StockLocation, StockLocationType } from './stock_locations';
|
|
6
6
|
import type { Shipment, ShipmentType } from './shipments';
|
7
7
|
import type { LineItem, LineItemType } from './line_items';
|
8
8
|
import type { Event } from './events';
|
9
|
+
import type { Version } from './versions';
|
9
10
|
type StockTransferType = 'stock_transfers';
|
10
11
|
type StockTransferRel = ResourceRel & {
|
11
12
|
type: StockTransferType;
|
@@ -35,6 +36,7 @@ interface StockTransfer extends Resource {
|
|
35
36
|
shipment?: Shipment | null;
|
36
37
|
line_item?: LineItem | null;
|
37
38
|
events?: Event[] | null;
|
39
|
+
versions?: Version[] | null;
|
38
40
|
}
|
39
41
|
interface StockTransferCreate extends ResourceCreate {
|
40
42
|
sku_code?: string | null;
|
@@ -67,6 +69,7 @@ declare class StockTransfers extends ApiResource<StockTransfer> {
|
|
67
69
|
shipment(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
|
68
70
|
line_item(stockTransferId: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
|
69
71
|
events(stockTransferId: string | StockTransfer, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Event>>;
|
72
|
+
versions(stockTransferId: string | StockTransfer, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
70
73
|
_upcoming(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
|
71
74
|
_picking(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
|
72
75
|
_in_transit(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
|
@@ -33,6 +33,10 @@ class StockTransfers extends ApiResource {
|
|
33
33
|
const _stockTransferId = stockTransferId.id || stockTransferId;
|
34
34
|
return this.resources.fetch({ type: 'events' }, `stock_transfers/${_stockTransferId}/events`, params, options);
|
35
35
|
}
|
36
|
+
async versions(stockTransferId, params, options) {
|
37
|
+
const _stockTransferId = stockTransferId.id || stockTransferId;
|
38
|
+
return this.resources.fetch({ type: 'versions' }, `stock_transfers/${_stockTransferId}/versions`, params, options);
|
39
|
+
}
|
36
40
|
async _upcoming(id, params, options) {
|
37
41
|
return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: StockTransfers.TYPE, _upcoming: true }, params, options);
|
38
42
|
}
|
@@ -2,6 +2,7 @@ import { ApiResource } from '../resource';
|
|
2
2
|
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
3
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
4
4
|
import type { PaymentMethod } from './payment_methods';
|
5
|
+
import type { Version } from './versions';
|
5
6
|
import type { StripePayment } from './stripe_payments';
|
6
7
|
type StripeGatewayType = 'stripe_gateways';
|
7
8
|
type StripeGatewayRel = ResourceRel & {
|
@@ -15,6 +16,7 @@ interface StripeGateway extends Resource {
|
|
15
16
|
webhook_endpoint_secret?: string | null;
|
16
17
|
webhook_endpoint_url?: string | null;
|
17
18
|
payment_methods?: PaymentMethod[] | null;
|
19
|
+
versions?: Version[] | null;
|
18
20
|
stripe_payments?: StripePayment[] | null;
|
19
21
|
}
|
20
22
|
interface StripeGatewayCreate extends ResourceCreate {
|
@@ -33,6 +35,7 @@ declare class StripeGateways extends ApiResource<StripeGateway> {
|
|
33
35
|
update(resource: StripeGatewayUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StripeGateway>;
|
34
36
|
delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
|
35
37
|
payment_methods(stripeGatewayId: string | StripeGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
|
38
|
+
versions(stripeGatewayId: string | StripeGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
|
36
39
|
stripe_payments(stripeGatewayId: string | StripeGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<StripePayment>>;
|
37
40
|
isStripeGateway(resource: any): resource is StripeGateway;
|
38
41
|
relationship(id: string | ResourceId | null): StripeGatewayRel;
|
@@ -13,6 +13,10 @@ class StripeGateways extends ApiResource {
|
|
13
13
|
const _stripeGatewayId = stripeGatewayId.id || stripeGatewayId;
|
14
14
|
return this.resources.fetch({ type: 'payment_methods' }, `stripe_gateways/${_stripeGatewayId}/payment_methods`, params, options);
|
15
15
|
}
|
16
|
+
async versions(stripeGatewayId, params, options) {
|
17
|
+
const _stripeGatewayId = stripeGatewayId.id || stripeGatewayId;
|
18
|
+
return this.resources.fetch({ type: 'versions' }, `stripe_gateways/${_stripeGatewayId}/versions`, params, options);
|
19
|
+
}
|
16
20
|
async stripe_payments(stripeGatewayId, params, options) {
|
17
21
|
const _stripeGatewayId = stripeGatewayId.id || stripeGatewayId;
|
18
22
|
return this.resources.fetch({ type: 'stripe_payments' }, `stripe_gateways/${_stripeGatewayId}/stripe_payments`, params, options);
|