@commercelayer/sdk 1.0.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/LICENSE +21 -0
- package/README.md +283 -0
- package/lib/cjs/api.d.ts +101 -0
- package/lib/cjs/api.js +1 -0
- package/lib/cjs/client.d.ts +26 -0
- package/lib/cjs/client.js +1 -0
- package/lib/cjs/commercelayer.d.ts +120 -0
- package/lib/cjs/commercelayer.js +1 -0
- package/lib/cjs/common.d.ts +4 -0
- package/lib/cjs/common.js +1 -0
- package/lib/cjs/config.d.ts +11 -0
- package/lib/cjs/config.js +1 -0
- package/lib/cjs/debug.d.ts +3 -0
- package/lib/cjs/debug.js +1 -0
- package/lib/cjs/error.d.ts +26 -0
- package/lib/cjs/error.js +1 -0
- package/lib/cjs/index.d.ts +7 -0
- package/lib/cjs/index.js +1 -0
- package/lib/cjs/interceptor.d.ts +19 -0
- package/lib/cjs/interceptor.js +1 -0
- package/lib/cjs/jsonapi.d.ts +5 -0
- package/lib/cjs/jsonapi.js +1 -0
- package/lib/cjs/model.d.ts +99 -0
- package/lib/cjs/model.js +1 -0
- package/lib/cjs/query.d.ts +23 -0
- package/lib/cjs/query.js +1 -0
- package/lib/cjs/resource.d.ts +71 -0
- package/lib/cjs/resource.js +1 -0
- package/lib/cjs/resources/addresses.d.ts +87 -0
- package/lib/cjs/resources/addresses.js +1 -0
- package/lib/cjs/resources/adjustments.d.ts +35 -0
- package/lib/cjs/resources/adjustments.js +1 -0
- package/lib/cjs/resources/adyen_gateways.d.ts +45 -0
- package/lib/cjs/resources/adyen_gateways.js +1 -0
- package/lib/cjs/resources/adyen_payments.d.ts +42 -0
- package/lib/cjs/resources/adyen_payments.js +1 -0
- package/lib/cjs/resources/application.d.ts +21 -0
- package/lib/cjs/resources/application.js +1 -0
- package/lib/cjs/resources/attachments.d.ts +156 -0
- package/lib/cjs/resources/attachments.js +1 -0
- package/lib/cjs/resources/authorizations.d.ts +54 -0
- package/lib/cjs/resources/authorizations.js +1 -0
- package/lib/cjs/resources/avalara_accounts.d.ts +49 -0
- package/lib/cjs/resources/avalara_accounts.js +1 -0
- package/lib/cjs/resources/billing_info_validation_rules.d.ts +31 -0
- package/lib/cjs/resources/billing_info_validation_rules.js +1 -0
- package/lib/cjs/resources/bing_geocoders.d.ts +33 -0
- package/lib/cjs/resources/bing_geocoders.js +1 -0
- package/lib/cjs/resources/braintree_gateways.d.ts +54 -0
- package/lib/cjs/resources/braintree_gateways.js +1 -0
- package/lib/cjs/resources/braintree_payments.d.ts +45 -0
- package/lib/cjs/resources/braintree_payments.js +1 -0
- package/lib/cjs/resources/bundles.d.ts +65 -0
- package/lib/cjs/resources/bundles.js +1 -0
- package/lib/cjs/resources/captures.d.ts +45 -0
- package/lib/cjs/resources/captures.js +1 -0
- package/lib/cjs/resources/carrier_accounts.d.ts +24 -0
- package/lib/cjs/resources/carrier_accounts.js +1 -0
- package/lib/cjs/resources/checkout_com_gateways.d.ts +43 -0
- package/lib/cjs/resources/checkout_com_gateways.js +1 -0
- package/lib/cjs/resources/checkout_com_payments.d.ts +48 -0
- package/lib/cjs/resources/checkout_com_payments.js +1 -0
- package/lib/cjs/resources/coupon_codes_promotion_rules.d.ts +58 -0
- package/lib/cjs/resources/coupon_codes_promotion_rules.js +1 -0
- package/lib/cjs/resources/coupon_recipients.d.ts +42 -0
- package/lib/cjs/resources/coupon_recipients.js +1 -0
- package/lib/cjs/resources/coupons.d.ts +44 -0
- package/lib/cjs/resources/coupons.js +1 -0
- package/lib/cjs/resources/customer_addresses.d.ts +39 -0
- package/lib/cjs/resources/customer_addresses.js +1 -0
- package/lib/cjs/resources/customer_groups.d.ts +33 -0
- package/lib/cjs/resources/customer_groups.js +1 -0
- package/lib/cjs/resources/customer_password_resets.d.ts +32 -0
- package/lib/cjs/resources/customer_password_resets.js +1 -0
- package/lib/cjs/resources/customer_payment_sources.d.ts +65 -0
- package/lib/cjs/resources/customer_payment_sources.js +1 -0
- package/lib/cjs/resources/customer_subscriptions.d.ts +27 -0
- package/lib/cjs/resources/customer_subscriptions.js +1 -0
- package/lib/cjs/resources/customers.d.ts +52 -0
- package/lib/cjs/resources/customers.js +1 -0
- package/lib/cjs/resources/delivery_lead_times.d.ts +48 -0
- package/lib/cjs/resources/delivery_lead_times.js +1 -0
- package/lib/cjs/resources/event_callbacks.d.ts +23 -0
- package/lib/cjs/resources/event_callbacks.js +1 -0
- package/lib/cjs/resources/external_gateways.d.ts +44 -0
- package/lib/cjs/resources/external_gateways.js +1 -0
- package/lib/cjs/resources/external_payments.d.ts +38 -0
- package/lib/cjs/resources/external_payments.js +1 -0
- package/lib/cjs/resources/external_promotions.d.ts +78 -0
- package/lib/cjs/resources/external_promotions.js +1 -0
- package/lib/cjs/resources/external_tax_calculators.d.ts +41 -0
- package/lib/cjs/resources/external_tax_calculators.js +1 -0
- package/lib/cjs/resources/fixed_amount_promotions.d.ts +80 -0
- package/lib/cjs/resources/fixed_amount_promotions.js +1 -0
- package/lib/cjs/resources/fixed_price_promotions.d.ts +89 -0
- package/lib/cjs/resources/fixed_price_promotions.js +1 -0
- package/lib/cjs/resources/free_gift_promotions.d.ts +87 -0
- package/lib/cjs/resources/free_gift_promotions.js +1 -0
- package/lib/cjs/resources/free_shipping_promotions.d.ts +75 -0
- package/lib/cjs/resources/free_shipping_promotions.js +1 -0
- package/lib/cjs/resources/geocoders.d.ts +22 -0
- package/lib/cjs/resources/geocoders.js +1 -0
- package/lib/cjs/resources/gift_card_recipients.d.ts +42 -0
- package/lib/cjs/resources/gift_card_recipients.js +1 -0
- package/lib/cjs/resources/gift_cards.d.ts +79 -0
- package/lib/cjs/resources/gift_cards.js +1 -0
- package/lib/cjs/resources/google_geocoders.d.ts +33 -0
- package/lib/cjs/resources/google_geocoders.js +1 -0
- package/lib/cjs/resources/imports.d.ts +40 -0
- package/lib/cjs/resources/imports.js +1 -0
- package/lib/cjs/resources/in_stock_subscriptions.d.ts +56 -0
- package/lib/cjs/resources/in_stock_subscriptions.js +1 -0
- package/lib/cjs/resources/inventory_models.d.ts +39 -0
- package/lib/cjs/resources/inventory_models.js +1 -0
- package/lib/cjs/resources/inventory_return_locations.d.ts +41 -0
- package/lib/cjs/resources/inventory_return_locations.js +1 -0
- package/lib/cjs/resources/inventory_stock_locations.d.ts +44 -0
- package/lib/cjs/resources/inventory_stock_locations.js +1 -0
- package/lib/cjs/resources/line_item_options.d.ts +55 -0
- package/lib/cjs/resources/line_item_options.js +1 -0
- package/lib/cjs/resources/line_items.d.ts +121 -0
- package/lib/cjs/resources/line_items.js +1 -0
- package/lib/cjs/resources/manual_gateways.d.ts +32 -0
- package/lib/cjs/resources/manual_gateways.js +1 -0
- package/lib/cjs/resources/manual_tax_calculators.d.ts +45 -0
- package/lib/cjs/resources/manual_tax_calculators.js +1 -0
- package/lib/cjs/resources/markets.d.ts +75 -0
- package/lib/cjs/resources/markets.js +1 -0
- package/lib/cjs/resources/merchants.d.ts +36 -0
- package/lib/cjs/resources/merchants.js +1 -0
- package/lib/cjs/resources/order_amount_promotion_rules.d.ts +56 -0
- package/lib/cjs/resources/order_amount_promotion_rules.js +1 -0
- package/lib/cjs/resources/order_copies.d.ts +42 -0
- package/lib/cjs/resources/order_copies.js +1 -0
- package/lib/cjs/resources/order_subscriptions.d.ts +62 -0
- package/lib/cjs/resources/order_subscriptions.js +1 -0
- package/lib/cjs/resources/order_validation_rules.d.ts +19 -0
- package/lib/cjs/resources/order_validation_rules.js +1 -0
- package/lib/cjs/resources/orders.d.ts +251 -0
- package/lib/cjs/resources/orders.js +1 -0
- package/lib/cjs/resources/organization.d.ts +32 -0
- package/lib/cjs/resources/organization.js +1 -0
- package/lib/cjs/resources/packages.d.ts +53 -0
- package/lib/cjs/resources/packages.js +1 -0
- package/lib/cjs/resources/parcel_line_items.d.ts +47 -0
- package/lib/cjs/resources/parcel_line_items.js +1 -0
- package/lib/cjs/resources/parcels.d.ts +104 -0
- package/lib/cjs/resources/parcels.js +1 -0
- package/lib/cjs/resources/payment_gateways.d.ts +20 -0
- package/lib/cjs/resources/payment_gateways.js +1 -0
- package/lib/cjs/resources/payment_methods.d.ts +53 -0
- package/lib/cjs/resources/payment_methods.js +1 -0
- package/lib/cjs/resources/paypal_gateways.d.ts +37 -0
- package/lib/cjs/resources/paypal_gateways.js +1 -0
- package/lib/cjs/resources/paypal_payments.d.ts +45 -0
- package/lib/cjs/resources/paypal_payments.js +1 -0
- package/lib/cjs/resources/percentage_discount_promotions.d.ts +87 -0
- package/lib/cjs/resources/percentage_discount_promotions.js +1 -0
- package/lib/cjs/resources/price_lists.d.ts +37 -0
- package/lib/cjs/resources/price_lists.js +1 -0
- package/lib/cjs/resources/prices.d.ts +54 -0
- package/lib/cjs/resources/prices.js +1 -0
- package/lib/cjs/resources/promotion_rules.d.ts +24 -0
- package/lib/cjs/resources/promotion_rules.js +1 -0
- package/lib/cjs/resources/promotions.d.ts +35 -0
- package/lib/cjs/resources/promotions.js +1 -0
- package/lib/cjs/resources/refunds.d.ts +32 -0
- package/lib/cjs/resources/refunds.js +1 -0
- package/lib/cjs/resources/return_line_items.d.ts +47 -0
- package/lib/cjs/resources/return_line_items.js +1 -0
- package/lib/cjs/resources/returns.d.ts +65 -0
- package/lib/cjs/resources/returns.js +1 -0
- package/lib/cjs/resources/shipments.d.ts +76 -0
- package/lib/cjs/resources/shipments.js +1 -0
- package/lib/cjs/resources/shipping_categories.d.ts +31 -0
- package/lib/cjs/resources/shipping_categories.js +1 -0
- package/lib/cjs/resources/shipping_methods.d.ts +67 -0
- package/lib/cjs/resources/shipping_methods.js +1 -0
- package/lib/cjs/resources/shipping_zones.d.ts +47 -0
- package/lib/cjs/resources/shipping_zones.js +1 -0
- package/lib/cjs/resources/sku_list_items.d.ts +45 -0
- package/lib/cjs/resources/sku_list_items.js +1 -0
- package/lib/cjs/resources/sku_list_promotion_rules.d.ts +66 -0
- package/lib/cjs/resources/sku_list_promotion_rules.js +1 -0
- package/lib/cjs/resources/sku_lists.d.ts +46 -0
- package/lib/cjs/resources/sku_lists.js +1 -0
- package/lib/cjs/resources/sku_options.d.ts +51 -0
- package/lib/cjs/resources/sku_options.js +1 -0
- package/lib/cjs/resources/skus.d.ts +72 -0
- package/lib/cjs/resources/skus.js +1 -0
- package/lib/cjs/resources/stock_items.d.ts +46 -0
- package/lib/cjs/resources/stock_items.js +1 -0
- package/lib/cjs/resources/stock_line_items.d.ts +26 -0
- package/lib/cjs/resources/stock_line_items.js +1 -0
- package/lib/cjs/resources/stock_locations.d.ts +51 -0
- package/lib/cjs/resources/stock_locations.js +1 -0
- package/lib/cjs/resources/stock_transfers.d.ts +66 -0
- package/lib/cjs/resources/stock_transfers.js +1 -0
- package/lib/cjs/resources/stripe_gateways.d.ts +36 -0
- package/lib/cjs/resources/stripe_gateways.js +1 -0
- package/lib/cjs/resources/stripe_payments.d.ts +40 -0
- package/lib/cjs/resources/stripe_payments.js +1 -0
- package/lib/cjs/resources/tax_calculators.d.ts +24 -0
- package/lib/cjs/resources/tax_calculators.js +1 -0
- package/lib/cjs/resources/tax_categories.d.ts +57 -0
- package/lib/cjs/resources/tax_categories.js +1 -0
- package/lib/cjs/resources/tax_rules.d.ts +68 -0
- package/lib/cjs/resources/tax_rules.js +1 -0
- package/lib/cjs/resources/taxjar_accounts.d.ts +40 -0
- package/lib/cjs/resources/taxjar_accounts.js +1 -0
- package/lib/cjs/resources/transactions.d.ts +30 -0
- package/lib/cjs/resources/transactions.js +1 -0
- package/lib/cjs/resources/voids.d.ts +32 -0
- package/lib/cjs/resources/voids.js +1 -0
- package/lib/cjs/resources/webhooks.d.ts +41 -0
- package/lib/cjs/resources/webhooks.js +1 -0
- package/lib/cjs/resources/wire_transfers.d.ts +31 -0
- package/lib/cjs/resources/wire_transfers.js +1 -0
- package/lib/cjs/static.d.ts +6 -0
- package/lib/cjs/static.js +1 -0
- package/lib/cjs/util.d.ts +3 -0
- package/lib/cjs/util.js +1 -0
- package/lib/esm/api.d.ts +101 -0
- package/lib/esm/api.js +1 -0
- package/lib/esm/client.d.ts +26 -0
- package/lib/esm/client.js +1 -0
- package/lib/esm/commercelayer.d.ts +120 -0
- package/lib/esm/commercelayer.js +1 -0
- package/lib/esm/common.d.ts +4 -0
- package/lib/esm/common.js +1 -0
- package/lib/esm/config.d.ts +11 -0
- package/lib/esm/config.js +1 -0
- package/lib/esm/debug.d.ts +3 -0
- package/lib/esm/debug.js +1 -0
- package/lib/esm/error.d.ts +26 -0
- package/lib/esm/error.js +1 -0
- package/lib/esm/index.d.ts +7 -0
- package/lib/esm/index.js +1 -0
- package/lib/esm/interceptor.d.ts +19 -0
- package/lib/esm/interceptor.js +1 -0
- package/lib/esm/jsonapi.d.ts +5 -0
- package/lib/esm/jsonapi.js +1 -0
- package/lib/esm/model.d.ts +99 -0
- package/lib/esm/model.js +1 -0
- package/lib/esm/query.d.ts +23 -0
- package/lib/esm/query.js +1 -0
- package/lib/esm/resource.d.ts +71 -0
- package/lib/esm/resource.js +1 -0
- package/lib/esm/resources/addresses.d.ts +87 -0
- package/lib/esm/resources/addresses.js +1 -0
- package/lib/esm/resources/adjustments.d.ts +35 -0
- package/lib/esm/resources/adjustments.js +1 -0
- package/lib/esm/resources/adyen_gateways.d.ts +45 -0
- package/lib/esm/resources/adyen_gateways.js +1 -0
- package/lib/esm/resources/adyen_payments.d.ts +42 -0
- package/lib/esm/resources/adyen_payments.js +1 -0
- package/lib/esm/resources/application.d.ts +21 -0
- package/lib/esm/resources/application.js +1 -0
- package/lib/esm/resources/attachments.d.ts +156 -0
- package/lib/esm/resources/attachments.js +1 -0
- package/lib/esm/resources/authorizations.d.ts +54 -0
- package/lib/esm/resources/authorizations.js +1 -0
- package/lib/esm/resources/avalara_accounts.d.ts +49 -0
- package/lib/esm/resources/avalara_accounts.js +1 -0
- package/lib/esm/resources/billing_info_validation_rules.d.ts +31 -0
- package/lib/esm/resources/billing_info_validation_rules.js +1 -0
- package/lib/esm/resources/bing_geocoders.d.ts +33 -0
- package/lib/esm/resources/bing_geocoders.js +1 -0
- package/lib/esm/resources/braintree_gateways.d.ts +54 -0
- package/lib/esm/resources/braintree_gateways.js +1 -0
- package/lib/esm/resources/braintree_payments.d.ts +45 -0
- package/lib/esm/resources/braintree_payments.js +1 -0
- package/lib/esm/resources/bundles.d.ts +65 -0
- package/lib/esm/resources/bundles.js +1 -0
- package/lib/esm/resources/captures.d.ts +45 -0
- package/lib/esm/resources/captures.js +1 -0
- package/lib/esm/resources/carrier_accounts.d.ts +24 -0
- package/lib/esm/resources/carrier_accounts.js +1 -0
- package/lib/esm/resources/checkout_com_gateways.d.ts +43 -0
- package/lib/esm/resources/checkout_com_gateways.js +1 -0
- package/lib/esm/resources/checkout_com_payments.d.ts +48 -0
- package/lib/esm/resources/checkout_com_payments.js +1 -0
- package/lib/esm/resources/coupon_codes_promotion_rules.d.ts +58 -0
- package/lib/esm/resources/coupon_codes_promotion_rules.js +1 -0
- package/lib/esm/resources/coupon_recipients.d.ts +42 -0
- package/lib/esm/resources/coupon_recipients.js +1 -0
- package/lib/esm/resources/coupons.d.ts +44 -0
- package/lib/esm/resources/coupons.js +1 -0
- package/lib/esm/resources/customer_addresses.d.ts +39 -0
- package/lib/esm/resources/customer_addresses.js +1 -0
- package/lib/esm/resources/customer_groups.d.ts +33 -0
- package/lib/esm/resources/customer_groups.js +1 -0
- package/lib/esm/resources/customer_password_resets.d.ts +32 -0
- package/lib/esm/resources/customer_password_resets.js +1 -0
- package/lib/esm/resources/customer_payment_sources.d.ts +65 -0
- package/lib/esm/resources/customer_payment_sources.js +1 -0
- package/lib/esm/resources/customer_subscriptions.d.ts +27 -0
- package/lib/esm/resources/customer_subscriptions.js +1 -0
- package/lib/esm/resources/customers.d.ts +52 -0
- package/lib/esm/resources/customers.js +1 -0
- package/lib/esm/resources/delivery_lead_times.d.ts +48 -0
- package/lib/esm/resources/delivery_lead_times.js +1 -0
- package/lib/esm/resources/event_callbacks.d.ts +23 -0
- package/lib/esm/resources/event_callbacks.js +1 -0
- package/lib/esm/resources/external_gateways.d.ts +44 -0
- package/lib/esm/resources/external_gateways.js +1 -0
- package/lib/esm/resources/external_payments.d.ts +38 -0
- package/lib/esm/resources/external_payments.js +1 -0
- package/lib/esm/resources/external_promotions.d.ts +78 -0
- package/lib/esm/resources/external_promotions.js +1 -0
- package/lib/esm/resources/external_tax_calculators.d.ts +41 -0
- package/lib/esm/resources/external_tax_calculators.js +1 -0
- package/lib/esm/resources/fixed_amount_promotions.d.ts +80 -0
- package/lib/esm/resources/fixed_amount_promotions.js +1 -0
- package/lib/esm/resources/fixed_price_promotions.d.ts +89 -0
- package/lib/esm/resources/fixed_price_promotions.js +1 -0
- package/lib/esm/resources/free_gift_promotions.d.ts +87 -0
- package/lib/esm/resources/free_gift_promotions.js +1 -0
- package/lib/esm/resources/free_shipping_promotions.d.ts +75 -0
- package/lib/esm/resources/free_shipping_promotions.js +1 -0
- package/lib/esm/resources/geocoders.d.ts +22 -0
- package/lib/esm/resources/geocoders.js +1 -0
- package/lib/esm/resources/gift_card_recipients.d.ts +42 -0
- package/lib/esm/resources/gift_card_recipients.js +1 -0
- package/lib/esm/resources/gift_cards.d.ts +79 -0
- package/lib/esm/resources/gift_cards.js +1 -0
- package/lib/esm/resources/google_geocoders.d.ts +33 -0
- package/lib/esm/resources/google_geocoders.js +1 -0
- package/lib/esm/resources/imports.d.ts +40 -0
- package/lib/esm/resources/imports.js +1 -0
- package/lib/esm/resources/in_stock_subscriptions.d.ts +56 -0
- package/lib/esm/resources/in_stock_subscriptions.js +1 -0
- package/lib/esm/resources/inventory_models.d.ts +39 -0
- package/lib/esm/resources/inventory_models.js +1 -0
- package/lib/esm/resources/inventory_return_locations.d.ts +41 -0
- package/lib/esm/resources/inventory_return_locations.js +1 -0
- package/lib/esm/resources/inventory_stock_locations.d.ts +44 -0
- package/lib/esm/resources/inventory_stock_locations.js +1 -0
- package/lib/esm/resources/line_item_options.d.ts +55 -0
- package/lib/esm/resources/line_item_options.js +1 -0
- package/lib/esm/resources/line_items.d.ts +121 -0
- package/lib/esm/resources/line_items.js +1 -0
- package/lib/esm/resources/manual_gateways.d.ts +32 -0
- package/lib/esm/resources/manual_gateways.js +1 -0
- package/lib/esm/resources/manual_tax_calculators.d.ts +45 -0
- package/lib/esm/resources/manual_tax_calculators.js +1 -0
- package/lib/esm/resources/markets.d.ts +75 -0
- package/lib/esm/resources/markets.js +1 -0
- package/lib/esm/resources/merchants.d.ts +36 -0
- package/lib/esm/resources/merchants.js +1 -0
- package/lib/esm/resources/order_amount_promotion_rules.d.ts +56 -0
- package/lib/esm/resources/order_amount_promotion_rules.js +1 -0
- package/lib/esm/resources/order_copies.d.ts +42 -0
- package/lib/esm/resources/order_copies.js +1 -0
- package/lib/esm/resources/order_subscriptions.d.ts +62 -0
- package/lib/esm/resources/order_subscriptions.js +1 -0
- package/lib/esm/resources/order_validation_rules.d.ts +19 -0
- package/lib/esm/resources/order_validation_rules.js +1 -0
- package/lib/esm/resources/orders.d.ts +251 -0
- package/lib/esm/resources/orders.js +1 -0
- package/lib/esm/resources/organization.d.ts +32 -0
- package/lib/esm/resources/organization.js +1 -0
- package/lib/esm/resources/packages.d.ts +53 -0
- package/lib/esm/resources/packages.js +1 -0
- package/lib/esm/resources/parcel_line_items.d.ts +47 -0
- package/lib/esm/resources/parcel_line_items.js +1 -0
- package/lib/esm/resources/parcels.d.ts +104 -0
- package/lib/esm/resources/parcels.js +1 -0
- package/lib/esm/resources/payment_gateways.d.ts +20 -0
- package/lib/esm/resources/payment_gateways.js +1 -0
- package/lib/esm/resources/payment_methods.d.ts +53 -0
- package/lib/esm/resources/payment_methods.js +1 -0
- package/lib/esm/resources/paypal_gateways.d.ts +37 -0
- package/lib/esm/resources/paypal_gateways.js +1 -0
- package/lib/esm/resources/paypal_payments.d.ts +45 -0
- package/lib/esm/resources/paypal_payments.js +1 -0
- package/lib/esm/resources/percentage_discount_promotions.d.ts +87 -0
- package/lib/esm/resources/percentage_discount_promotions.js +1 -0
- package/lib/esm/resources/price_lists.d.ts +37 -0
- package/lib/esm/resources/price_lists.js +1 -0
- package/lib/esm/resources/prices.d.ts +54 -0
- package/lib/esm/resources/prices.js +1 -0
- package/lib/esm/resources/promotion_rules.d.ts +24 -0
- package/lib/esm/resources/promotion_rules.js +1 -0
- package/lib/esm/resources/promotions.d.ts +35 -0
- package/lib/esm/resources/promotions.js +1 -0
- package/lib/esm/resources/refunds.d.ts +32 -0
- package/lib/esm/resources/refunds.js +1 -0
- package/lib/esm/resources/return_line_items.d.ts +47 -0
- package/lib/esm/resources/return_line_items.js +1 -0
- package/lib/esm/resources/returns.d.ts +65 -0
- package/lib/esm/resources/returns.js +1 -0
- package/lib/esm/resources/shipments.d.ts +76 -0
- package/lib/esm/resources/shipments.js +1 -0
- package/lib/esm/resources/shipping_categories.d.ts +31 -0
- package/lib/esm/resources/shipping_categories.js +1 -0
- package/lib/esm/resources/shipping_methods.d.ts +67 -0
- package/lib/esm/resources/shipping_methods.js +1 -0
- package/lib/esm/resources/shipping_zones.d.ts +47 -0
- package/lib/esm/resources/shipping_zones.js +1 -0
- package/lib/esm/resources/sku_list_items.d.ts +45 -0
- package/lib/esm/resources/sku_list_items.js +1 -0
- package/lib/esm/resources/sku_list_promotion_rules.d.ts +66 -0
- package/lib/esm/resources/sku_list_promotion_rules.js +1 -0
- package/lib/esm/resources/sku_lists.d.ts +46 -0
- package/lib/esm/resources/sku_lists.js +1 -0
- package/lib/esm/resources/sku_options.d.ts +51 -0
- package/lib/esm/resources/sku_options.js +1 -0
- package/lib/esm/resources/skus.d.ts +72 -0
- package/lib/esm/resources/skus.js +1 -0
- package/lib/esm/resources/stock_items.d.ts +46 -0
- package/lib/esm/resources/stock_items.js +1 -0
- package/lib/esm/resources/stock_line_items.d.ts +26 -0
- package/lib/esm/resources/stock_line_items.js +1 -0
- package/lib/esm/resources/stock_locations.d.ts +51 -0
- package/lib/esm/resources/stock_locations.js +1 -0
- package/lib/esm/resources/stock_transfers.d.ts +66 -0
- package/lib/esm/resources/stock_transfers.js +1 -0
- package/lib/esm/resources/stripe_gateways.d.ts +36 -0
- package/lib/esm/resources/stripe_gateways.js +1 -0
- package/lib/esm/resources/stripe_payments.d.ts +40 -0
- package/lib/esm/resources/stripe_payments.js +1 -0
- package/lib/esm/resources/tax_calculators.d.ts +24 -0
- package/lib/esm/resources/tax_calculators.js +1 -0
- package/lib/esm/resources/tax_categories.d.ts +57 -0
- package/lib/esm/resources/tax_categories.js +1 -0
- package/lib/esm/resources/tax_rules.d.ts +68 -0
- package/lib/esm/resources/tax_rules.js +1 -0
- package/lib/esm/resources/taxjar_accounts.d.ts +40 -0
- package/lib/esm/resources/taxjar_accounts.js +1 -0
- package/lib/esm/resources/transactions.d.ts +30 -0
- package/lib/esm/resources/transactions.js +1 -0
- package/lib/esm/resources/voids.d.ts +32 -0
- package/lib/esm/resources/voids.js +1 -0
- package/lib/esm/resources/webhooks.d.ts +41 -0
- package/lib/esm/resources/webhooks.js +1 -0
- package/lib/esm/resources/wire_transfers.d.ts +31 -0
- package/lib/esm/resources/wire_transfers.js +1 -0
- package/lib/esm/static.d.ts +6 -0
- package/lib/esm/static.js +1 -0
- package/lib/esm/util.d.ts +3 -0
- package/lib/esm/util.js +1 -0
- package/lib/tsconfig.esm.tsbuildinfo +1 -0
- package/lib/tsconfig.tsbuildinfo +1 -0
- package/package.json +82 -0
@@ -0,0 +1,62 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { Market } from './markets';
|
4
|
+
import { Order } from './orders';
|
5
|
+
import { Customer } from './customers';
|
6
|
+
import { OrderCopy } from './order_copies';
|
7
|
+
declare type OrderSubscriptionRel = ResourceId & {
|
8
|
+
type: typeof OrderSubscriptions.TYPE;
|
9
|
+
};
|
10
|
+
declare type MarketRel = ResourceId & {
|
11
|
+
type: 'markets';
|
12
|
+
};
|
13
|
+
declare type OrderRel = ResourceId & {
|
14
|
+
type: 'orders';
|
15
|
+
};
|
16
|
+
interface OrderSubscription extends Resource {
|
17
|
+
number?: string;
|
18
|
+
status?: string;
|
19
|
+
frequency?: string;
|
20
|
+
activate_by_source_order?: boolean;
|
21
|
+
customer_email?: string;
|
22
|
+
starts_at?: string;
|
23
|
+
expires_at?: string;
|
24
|
+
next_run_at?: string;
|
25
|
+
occurrencies?: number;
|
26
|
+
errors_count?: number;
|
27
|
+
succeeded_on_last_run?: boolean;
|
28
|
+
options?: object;
|
29
|
+
market?: Market;
|
30
|
+
source_order?: Order;
|
31
|
+
customer?: Customer;
|
32
|
+
order_copies?: OrderCopy[];
|
33
|
+
orders?: Order[];
|
34
|
+
}
|
35
|
+
interface OrderSubscriptionCreate extends ResourceCreate {
|
36
|
+
frequency: string;
|
37
|
+
activate_by_source_order?: boolean;
|
38
|
+
starts_at?: string;
|
39
|
+
expires_at?: string;
|
40
|
+
options?: object;
|
41
|
+
market?: MarketRel;
|
42
|
+
source_order: OrderRel;
|
43
|
+
}
|
44
|
+
interface OrderSubscriptionUpdate extends ResourceUpdate {
|
45
|
+
expires_at?: string;
|
46
|
+
_activate?: boolean;
|
47
|
+
_deactivate?: boolean;
|
48
|
+
_cancel?: boolean;
|
49
|
+
}
|
50
|
+
declare class OrderSubscriptions extends ApiResource {
|
51
|
+
static readonly TYPE: 'order_subscriptions';
|
52
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<OrderSubscription>>;
|
53
|
+
create(resource: OrderSubscriptionCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<OrderSubscription>;
|
54
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<OrderSubscription>;
|
55
|
+
update(resource: OrderSubscriptionUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<OrderSubscription>;
|
56
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
57
|
+
isOrderSubscription(resource: any): resource is OrderSubscription;
|
58
|
+
relationship(id: string | ResourceId): OrderSubscriptionRel;
|
59
|
+
type(): string;
|
60
|
+
}
|
61
|
+
export default OrderSubscriptions;
|
62
|
+
export { OrderSubscription, OrderSubscriptionCreate, OrderSubscriptionUpdate };
|
@@ -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(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}isOrderSubscription(e){return e.type&&e.type===t.TYPE}relationship(e){return typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="order_subscriptions";export default t;
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import { ApiResource, Resource, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { Market } from './markets';
|
4
|
+
declare type OrderValidationRuleRel = ResourceId & {
|
5
|
+
type: typeof OrderValidationRules.TYPE;
|
6
|
+
};
|
7
|
+
interface OrderValidationRule extends Resource {
|
8
|
+
market?: Market;
|
9
|
+
}
|
10
|
+
declare class OrderValidationRules extends ApiResource {
|
11
|
+
static readonly TYPE: 'order_validation_rules';
|
12
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<OrderValidationRule>>;
|
13
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<OrderValidationRule>;
|
14
|
+
isOrderValidationRule(resource: any): resource is OrderValidationRule;
|
15
|
+
relationship(id: string | ResourceId): OrderValidationRuleRel;
|
16
|
+
type(): string;
|
17
|
+
}
|
18
|
+
export default OrderValidationRules;
|
19
|
+
export { OrderValidationRule };
|
@@ -0,0 +1 @@
|
|
1
|
+
import{ApiResource as s}from"../resource";class t extends s{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async retrieve(e,r,i){return this.resources.retrieve({type:t.TYPE,id:e},r,i)}isOrderValidationRule(e){return e.type&&e.type===t.TYPE}relationship(e){return typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="order_validation_rules";export default t;
|
@@ -0,0 +1,251 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { Market } from './markets';
|
4
|
+
import { Customer } from './customers';
|
5
|
+
import { Address } from './addresses';
|
6
|
+
import { PaymentMethod } from './payment_methods';
|
7
|
+
import { CustomerPaymentSource } from './customer_payment_sources';
|
8
|
+
import { AdyenPayment } from './adyen_payments';
|
9
|
+
import { BraintreePayment } from './braintree_payments';
|
10
|
+
import { CheckoutComPayment } from './checkout_com_payments';
|
11
|
+
import { ExternalPayment } from './external_payments';
|
12
|
+
import { PaypalPayment } from './paypal_payments';
|
13
|
+
import { StripePayment } from './stripe_payments';
|
14
|
+
import { WireTransfer } from './wire_transfers';
|
15
|
+
import { LineItem } from './line_items';
|
16
|
+
import { Shipment } from './shipments';
|
17
|
+
import { Authorization } from './authorizations';
|
18
|
+
import { Void } from './voids';
|
19
|
+
import { Capture } from './captures';
|
20
|
+
import { Refund } from './refunds';
|
21
|
+
import { OrderSubscription } from './order_subscriptions';
|
22
|
+
import { OrderCopy } from './order_copies';
|
23
|
+
import { Attachment } from './attachments';
|
24
|
+
declare type OrderRel = ResourceId & {
|
25
|
+
type: typeof Orders.TYPE;
|
26
|
+
};
|
27
|
+
declare type MarketRel = ResourceId & {
|
28
|
+
type: 'markets';
|
29
|
+
};
|
30
|
+
declare type CustomerRel = ResourceId & {
|
31
|
+
type: 'customers';
|
32
|
+
};
|
33
|
+
declare type AddressRel = ResourceId & {
|
34
|
+
type: 'addresses';
|
35
|
+
};
|
36
|
+
declare type PaymentMethodRel = ResourceId & {
|
37
|
+
type: 'payment_methods';
|
38
|
+
};
|
39
|
+
declare type AdyenPaymentRel = ResourceId & {
|
40
|
+
type: 'adyen_payments';
|
41
|
+
};
|
42
|
+
declare type BraintreePaymentRel = ResourceId & {
|
43
|
+
type: 'braintree_payments';
|
44
|
+
};
|
45
|
+
declare type CheckoutComPaymentRel = ResourceId & {
|
46
|
+
type: 'checkout_com_payments';
|
47
|
+
};
|
48
|
+
declare type ExternalPaymentRel = ResourceId & {
|
49
|
+
type: 'external_payments';
|
50
|
+
};
|
51
|
+
declare type PaypalPaymentRel = ResourceId & {
|
52
|
+
type: 'paypal_payments';
|
53
|
+
};
|
54
|
+
declare type StripePaymentRel = ResourceId & {
|
55
|
+
type: 'stripe_payments';
|
56
|
+
};
|
57
|
+
declare type WireTransferRel = ResourceId & {
|
58
|
+
type: 'wire_transfers';
|
59
|
+
};
|
60
|
+
interface Order extends Resource {
|
61
|
+
number?: number;
|
62
|
+
autorefresh?: boolean;
|
63
|
+
status?: string;
|
64
|
+
payment_status?: string;
|
65
|
+
fulfillment_status?: string;
|
66
|
+
guest?: boolean;
|
67
|
+
editable?: boolean;
|
68
|
+
customer_email?: string;
|
69
|
+
language_code?: string;
|
70
|
+
currency_code?: string;
|
71
|
+
tax_included?: boolean;
|
72
|
+
tax_rate?: number;
|
73
|
+
freight_taxable?: boolean;
|
74
|
+
requires_billing_info?: boolean;
|
75
|
+
country_code?: string;
|
76
|
+
shipping_country_code_lock?: string;
|
77
|
+
coupon_code?: string;
|
78
|
+
gift_card_code?: string;
|
79
|
+
gift_card_or_coupon_code?: string;
|
80
|
+
subtotal_amount_cents?: number;
|
81
|
+
subtotal_amount_float?: number;
|
82
|
+
formatted_subtotal_amount?: string;
|
83
|
+
shipping_amount_cents?: number;
|
84
|
+
shipping_amount_float?: number;
|
85
|
+
formatted_shipping_amount?: string;
|
86
|
+
payment_method_amount_cents?: number;
|
87
|
+
payment_method_amount_float?: number;
|
88
|
+
formatted_payment_method_amount?: string;
|
89
|
+
discount_amount_cents?: number;
|
90
|
+
discount_amount_float?: number;
|
91
|
+
formatted_discount_amount?: string;
|
92
|
+
adjustment_amount_cents?: number;
|
93
|
+
adjustment_amount_float?: number;
|
94
|
+
formatted_adjustment_amount?: string;
|
95
|
+
gift_card_amount_cents?: number;
|
96
|
+
gift_card_amount_float?: number;
|
97
|
+
formatted_gift_card_amount?: string;
|
98
|
+
total_tax_amount_cents?: number;
|
99
|
+
total_tax_amount_float?: number;
|
100
|
+
formatted_total_tax_amount?: string;
|
101
|
+
subtotal_tax_amount_cents?: number;
|
102
|
+
subtotal_tax_amount_float?: number;
|
103
|
+
formatted_subtotal_tax_amount?: string;
|
104
|
+
shipping_tax_amount_cents?: number;
|
105
|
+
shipping_tax_amount_float?: number;
|
106
|
+
formatted_shipping_tax_amount?: string;
|
107
|
+
payment_method_tax_amount_cents?: number;
|
108
|
+
payment_method_tax_amount_float?: number;
|
109
|
+
formatted_payment_method_tax_amount?: string;
|
110
|
+
adjustment_tax_amount_cents?: number;
|
111
|
+
adjustment_tax_amount_float?: number;
|
112
|
+
formatted_adjustment_tax_amount?: string;
|
113
|
+
total_amount_cents?: number;
|
114
|
+
total_amount_float?: number;
|
115
|
+
formatted_total_amount?: string;
|
116
|
+
total_taxable_amount_cents?: number;
|
117
|
+
total_taxable_amount_float?: number;
|
118
|
+
formatted_total_taxable_amount?: string;
|
119
|
+
subtotal_taxable_amount_cents?: number;
|
120
|
+
subtotal_taxable_amount_float?: number;
|
121
|
+
formatted_subtotal_taxable_amount?: string;
|
122
|
+
shipping_taxable_amount_cents?: number;
|
123
|
+
shipping_taxable_amount_float?: number;
|
124
|
+
formatted_shipping_taxable_amount?: string;
|
125
|
+
payment_method_taxable_amount_cents?: number;
|
126
|
+
payment_method_taxable_amount_float?: number;
|
127
|
+
formatted_payment_method_taxable_amount?: string;
|
128
|
+
adjustment_taxable_amount_cents?: number;
|
129
|
+
adjustment_taxable_amount_float?: number;
|
130
|
+
formatted_adjustment_taxable_amount?: string;
|
131
|
+
total_amount_with_taxes_cents?: number;
|
132
|
+
total_amount_with_taxes_float?: number;
|
133
|
+
formatted_total_amount_with_taxes?: string;
|
134
|
+
fees_amount_cents?: number;
|
135
|
+
fees_amount_float?: number;
|
136
|
+
formatted_fees_amount?: string;
|
137
|
+
duty_amount_cents?: number;
|
138
|
+
duty_amount_float?: number;
|
139
|
+
formatted_duty_amount?: string;
|
140
|
+
skus_count?: number;
|
141
|
+
line_item_options_count?: number;
|
142
|
+
shipments_count?: number;
|
143
|
+
payment_source_details?: object;
|
144
|
+
token?: string;
|
145
|
+
cart_url?: string;
|
146
|
+
return_url?: string;
|
147
|
+
terms_url?: string;
|
148
|
+
privacy_url?: string;
|
149
|
+
checkout_url?: string;
|
150
|
+
placed_at?: string;
|
151
|
+
approved_at?: string;
|
152
|
+
cancelled_at?: string;
|
153
|
+
payment_updated_at?: string;
|
154
|
+
fulfillment_updated_at?: string;
|
155
|
+
refreshed_at?: string;
|
156
|
+
archived_at?: string;
|
157
|
+
expires_at?: string;
|
158
|
+
market?: Market;
|
159
|
+
customer?: Customer;
|
160
|
+
shipping_address?: Address;
|
161
|
+
billing_address?: Address;
|
162
|
+
available_payment_methods?: PaymentMethod[];
|
163
|
+
available_customer_payment_sources?: CustomerPaymentSource[];
|
164
|
+
payment_method?: PaymentMethod;
|
165
|
+
payment_source?: AdyenPayment | BraintreePayment | CheckoutComPayment | ExternalPayment | PaypalPayment | StripePayment | WireTransfer;
|
166
|
+
line_items?: LineItem[];
|
167
|
+
shipments?: Shipment[];
|
168
|
+
transactions?: (Authorization | Void | Capture | Refund)[];
|
169
|
+
authorizations?: Authorization[];
|
170
|
+
captures?: Capture[];
|
171
|
+
voids?: Void[];
|
172
|
+
refunds?: Refund[];
|
173
|
+
order_subscriptions?: OrderSubscription[];
|
174
|
+
order_copies?: OrderCopy[];
|
175
|
+
attachments?: Attachment[];
|
176
|
+
}
|
177
|
+
interface OrderCreate extends ResourceCreate {
|
178
|
+
autorefresh?: boolean;
|
179
|
+
guest?: boolean;
|
180
|
+
customer_email?: string;
|
181
|
+
customer_password?: string;
|
182
|
+
language_code?: string;
|
183
|
+
shipping_country_code_lock?: string;
|
184
|
+
coupon_code?: string;
|
185
|
+
gift_card_code?: string;
|
186
|
+
gift_card_or_coupon_code?: string;
|
187
|
+
cart_url?: string;
|
188
|
+
return_url?: string;
|
189
|
+
terms_url?: string;
|
190
|
+
privacy_url?: string;
|
191
|
+
market?: MarketRel;
|
192
|
+
customer?: CustomerRel;
|
193
|
+
shipping_address?: AddressRel;
|
194
|
+
billing_address?: AddressRel;
|
195
|
+
payment_method?: PaymentMethodRel;
|
196
|
+
payment_source?: AdyenPaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
197
|
+
}
|
198
|
+
interface OrderUpdate extends ResourceUpdate {
|
199
|
+
autorefresh?: boolean;
|
200
|
+
guest?: boolean;
|
201
|
+
customer_email?: string;
|
202
|
+
customer_password?: string;
|
203
|
+
language_code?: string;
|
204
|
+
shipping_country_code_lock?: string;
|
205
|
+
coupon_code?: string;
|
206
|
+
gift_card_code?: string;
|
207
|
+
gift_card_or_coupon_code?: string;
|
208
|
+
cart_url?: string;
|
209
|
+
return_url?: string;
|
210
|
+
terms_url?: string;
|
211
|
+
privacy_url?: string;
|
212
|
+
_archive?: boolean;
|
213
|
+
_unarchive?: boolean;
|
214
|
+
_place?: boolean;
|
215
|
+
_cancel?: boolean;
|
216
|
+
_approve?: boolean;
|
217
|
+
_approve_and_capture?: boolean;
|
218
|
+
_authorize?: boolean;
|
219
|
+
_authorization_amount_cents?: number;
|
220
|
+
_capture?: boolean;
|
221
|
+
_refund?: boolean;
|
222
|
+
_update_taxes?: boolean;
|
223
|
+
_billing_address_clone_id?: string;
|
224
|
+
_shipping_address_clone_id?: string;
|
225
|
+
_customer_payment_source_id?: string;
|
226
|
+
_shipping_address_same_as_billing?: boolean;
|
227
|
+
_billing_address_same_as_shipping?: boolean;
|
228
|
+
_save_payment_source_to_customer_wallet?: boolean;
|
229
|
+
_save_shipping_address_to_customer_address_book?: boolean;
|
230
|
+
_save_billing_address_to_customer_address_book?: boolean;
|
231
|
+
_refresh?: boolean;
|
232
|
+
market?: MarketRel;
|
233
|
+
customer?: CustomerRel;
|
234
|
+
shipping_address?: AddressRel;
|
235
|
+
billing_address?: AddressRel;
|
236
|
+
payment_method?: PaymentMethodRel;
|
237
|
+
payment_source?: AdyenPaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
238
|
+
}
|
239
|
+
declare class Orders extends ApiResource {
|
240
|
+
static readonly TYPE: 'orders';
|
241
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Order>>;
|
242
|
+
create(resource: OrderCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
|
243
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
|
244
|
+
update(resource: OrderUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
|
245
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
246
|
+
isOrder(resource: any): resource is Order;
|
247
|
+
relationship(id: string | ResourceId): OrderRel;
|
248
|
+
type(): string;
|
249
|
+
}
|
250
|
+
export default Orders;
|
251
|
+
export { Order, OrderCreate, OrderUpdate };
|
@@ -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(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async retrieve(e,s,r){return this.resources.retrieve({type:t.TYPE,id:e},s,r)}async update(e,s,r){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),s,r)}async delete(e,s){await this.resources.delete({type:t.TYPE,id:e},s)}isOrder(e){return e.type&&e.type===t.TYPE}relationship(e){return typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="orders";export default t;
|
@@ -0,0 +1,32 @@
|
|
1
|
+
import { ApiResource, Resource, ResourcesConfig, ResourceId } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsRetrieve } from '../query';
|
3
|
+
declare type OrganizationRel = ResourceId & {
|
4
|
+
type: typeof Organizations.TYPE;
|
5
|
+
};
|
6
|
+
interface Organization extends Resource {
|
7
|
+
name?: string;
|
8
|
+
slug?: string;
|
9
|
+
domain?: string;
|
10
|
+
support_phone?: string;
|
11
|
+
support_email?: string;
|
12
|
+
logo_url?: string;
|
13
|
+
favicon_url?: string;
|
14
|
+
primary_color?: string;
|
15
|
+
contrast_color?: string;
|
16
|
+
gtm_id?: string;
|
17
|
+
gtm_id_test?: string;
|
18
|
+
discount_disabled?: boolean;
|
19
|
+
account_disabled?: boolean;
|
20
|
+
acceptance_disabled?: boolean;
|
21
|
+
max_concurrent_promotions?: number;
|
22
|
+
max_concurrent_imports?: number;
|
23
|
+
}
|
24
|
+
declare class Organizations extends ApiResource {
|
25
|
+
static readonly TYPE: 'organization';
|
26
|
+
retrieve(params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Organization>;
|
27
|
+
isOrganization(resource: any): resource is Organization;
|
28
|
+
relationship(id: string | ResourceId): OrganizationRel;
|
29
|
+
type(): string;
|
30
|
+
}
|
31
|
+
export default Organizations;
|
32
|
+
export { Organization };
|
@@ -0,0 +1 @@
|
|
1
|
+
import{ApiResource as r}from"../resource";class e extends r{async retrieve(t,i){return this.resources.singleton({type:e.TYPE},t,i)}isOrganization(t){return t.type&&t.type===e.TYPE}relationship(t){return typeof t=="string"?{id:t,type:e.TYPE}:{id:t.id,type:e.TYPE}}type(){return e.TYPE}}e.TYPE="organization";export default e;
|
@@ -0,0 +1,53 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { StockLocation } from './stock_locations';
|
4
|
+
import { Parcel } from './parcels';
|
5
|
+
import { Attachment } from './attachments';
|
6
|
+
declare type PackageRel = ResourceId & {
|
7
|
+
type: typeof Packages.TYPE;
|
8
|
+
};
|
9
|
+
declare type StockLocationRel = ResourceId & {
|
10
|
+
type: 'stock_locations';
|
11
|
+
};
|
12
|
+
interface Package extends Resource {
|
13
|
+
name?: string;
|
14
|
+
code?: string;
|
15
|
+
length?: number;
|
16
|
+
width?: number;
|
17
|
+
height?: number;
|
18
|
+
unit_of_length?: string;
|
19
|
+
stock_location?: StockLocation;
|
20
|
+
parcels?: Parcel[];
|
21
|
+
attachments?: Attachment[];
|
22
|
+
}
|
23
|
+
interface PackageCreate extends ResourceCreate {
|
24
|
+
name: string;
|
25
|
+
code?: string;
|
26
|
+
length: number;
|
27
|
+
width: number;
|
28
|
+
height: number;
|
29
|
+
unit_of_length: string;
|
30
|
+
stock_location: StockLocationRel;
|
31
|
+
}
|
32
|
+
interface PackageUpdate extends ResourceUpdate {
|
33
|
+
name?: string;
|
34
|
+
code?: string;
|
35
|
+
length?: number;
|
36
|
+
width?: number;
|
37
|
+
height?: number;
|
38
|
+
unit_of_length?: string;
|
39
|
+
stock_location?: StockLocationRel;
|
40
|
+
}
|
41
|
+
declare class Packages extends ApiResource {
|
42
|
+
static readonly TYPE: 'packages';
|
43
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Package>>;
|
44
|
+
create(resource: PackageCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Package>;
|
45
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Package>;
|
46
|
+
update(resource: PackageUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Package>;
|
47
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
48
|
+
isPackage(resource: any): resource is Package;
|
49
|
+
relationship(id: string | ResourceId): PackageRel;
|
50
|
+
type(): string;
|
51
|
+
}
|
52
|
+
export default Packages;
|
53
|
+
export { Package, PackageCreate, PackageUpdate };
|
@@ -0,0 +1 @@
|
|
1
|
+
import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isPackage(e){return e.type&&e.type===t.TYPE}relationship(e){return typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="packages";export default t;
|
@@ -0,0 +1,47 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { Parcel } from './parcels';
|
4
|
+
import { StockLineItem } from './stock_line_items';
|
5
|
+
declare type ParcelLineItemRel = ResourceId & {
|
6
|
+
type: typeof ParcelLineItems.TYPE;
|
7
|
+
};
|
8
|
+
declare type ParcelRel = ResourceId & {
|
9
|
+
type: 'parcels';
|
10
|
+
};
|
11
|
+
declare type StockLineItemRel = ResourceId & {
|
12
|
+
type: 'stock_line_items';
|
13
|
+
};
|
14
|
+
interface ParcelLineItem extends Resource {
|
15
|
+
sku_code?: string;
|
16
|
+
quantity?: number;
|
17
|
+
parcel?: Parcel;
|
18
|
+
stock_line_item?: StockLineItem;
|
19
|
+
/**
|
20
|
+
* @deprecated This field should not be used as it may be removed in the future without notice
|
21
|
+
*/
|
22
|
+
shipment_line_item?: object;
|
23
|
+
}
|
24
|
+
interface ParcelLineItemCreate extends ResourceCreate {
|
25
|
+
sku_code?: string;
|
26
|
+
quantity: number;
|
27
|
+
parcel: ParcelRel;
|
28
|
+
stock_line_item: StockLineItemRel;
|
29
|
+
/**
|
30
|
+
* @deprecated This field should not be used as it may be removed in the future without notice
|
31
|
+
*/
|
32
|
+
shipment_line_item?: object;
|
33
|
+
}
|
34
|
+
declare type ParcelLineItemUpdate = ResourceUpdate;
|
35
|
+
declare class ParcelLineItems extends ApiResource {
|
36
|
+
static readonly TYPE: 'parcel_line_items';
|
37
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<ParcelLineItem>>;
|
38
|
+
create(resource: ParcelLineItemCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ParcelLineItem>;
|
39
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ParcelLineItem>;
|
40
|
+
update(resource: ParcelLineItemUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ParcelLineItem>;
|
41
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
42
|
+
isParcelLineItem(resource: any): resource is ParcelLineItem;
|
43
|
+
relationship(id: string | ResourceId): ParcelLineItemRel;
|
44
|
+
type(): string;
|
45
|
+
}
|
46
|
+
export default ParcelLineItems;
|
47
|
+
export { ParcelLineItem, ParcelLineItemCreate, ParcelLineItemUpdate };
|
@@ -0,0 +1 @@
|
|
1
|
+
import{ApiResource as i}from"../resource";class s extends i{async list(e,r){return this.resources.list({type:s.TYPE},e,r)}async create(e,r,t){return this.resources.create(Object.assign(Object.assign({},e),{type:s.TYPE}),r,t)}async retrieve(e,r,t){return this.resources.retrieve({type:s.TYPE,id:e},r,t)}async update(e,r,t){return this.resources.update(Object.assign(Object.assign({},e),{type:s.TYPE}),r,t)}async delete(e,r){await this.resources.delete({type:s.TYPE,id:e},r)}isParcelLineItem(e){return e.type&&e.type===s.TYPE}relationship(e){return typeof e=="string"?{id:e,type:s.TYPE}:{id:e.id,type:s.TYPE}}type(){return s.TYPE}}s.TYPE="parcel_line_items";export default s;
|
@@ -0,0 +1,104 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { Shipment } from './shipments';
|
4
|
+
import { Package } from './packages';
|
5
|
+
import { ParcelLineItem } from './parcel_line_items';
|
6
|
+
import { Attachment } from './attachments';
|
7
|
+
declare type ParcelRel = ResourceId & {
|
8
|
+
type: typeof Parcels.TYPE;
|
9
|
+
};
|
10
|
+
declare type ShipmentRel = ResourceId & {
|
11
|
+
type: 'shipments';
|
12
|
+
};
|
13
|
+
declare type PackageRel = ResourceId & {
|
14
|
+
type: 'packages';
|
15
|
+
};
|
16
|
+
interface Parcel extends Resource {
|
17
|
+
number?: string;
|
18
|
+
weight?: number;
|
19
|
+
unit_of_weight?: string;
|
20
|
+
eel_pfc?: string;
|
21
|
+
contents_type?: string;
|
22
|
+
contents_explanation?: string;
|
23
|
+
customs_certify?: boolean;
|
24
|
+
customs_signer?: string;
|
25
|
+
non_delivery_option?: string;
|
26
|
+
restriction_type?: string;
|
27
|
+
restriction_comments?: string;
|
28
|
+
customs_info_required?: boolean;
|
29
|
+
shipping_label_url?: string;
|
30
|
+
shipping_label_file_type?: string;
|
31
|
+
shipping_label_size?: string;
|
32
|
+
shipping_label_resolution?: string;
|
33
|
+
tracking_number?: string;
|
34
|
+
tracking_status?: string;
|
35
|
+
tracking_status_detail?: string;
|
36
|
+
tracking_status_updated_at?: string;
|
37
|
+
tracking_details?: string;
|
38
|
+
carrier_weight_oz?: string;
|
39
|
+
signed_by?: string;
|
40
|
+
incoterm?: string;
|
41
|
+
shipment?: Shipment;
|
42
|
+
package?: Package;
|
43
|
+
parcel_line_items?: ParcelLineItem[];
|
44
|
+
attachments?: Attachment[];
|
45
|
+
}
|
46
|
+
interface ParcelCreate extends ResourceCreate {
|
47
|
+
weight?: number;
|
48
|
+
unit_of_weight?: string;
|
49
|
+
eel_pfc?: string;
|
50
|
+
contents_type?: string;
|
51
|
+
contents_explanation?: string;
|
52
|
+
customs_certify?: boolean;
|
53
|
+
customs_signer?: string;
|
54
|
+
non_delivery_option?: string;
|
55
|
+
restriction_type?: string;
|
56
|
+
restriction_comments?: string;
|
57
|
+
customs_info_required?: boolean;
|
58
|
+
tracking_number?: string;
|
59
|
+
tracking_status?: string;
|
60
|
+
tracking_status_detail?: string;
|
61
|
+
tracking_status_updated_at?: string;
|
62
|
+
tracking_details?: string;
|
63
|
+
carrier_weight_oz?: string;
|
64
|
+
signed_by?: string;
|
65
|
+
incoterm?: string;
|
66
|
+
shipment: ShipmentRel;
|
67
|
+
package: PackageRel;
|
68
|
+
}
|
69
|
+
interface ParcelUpdate extends ResourceUpdate {
|
70
|
+
weight?: number;
|
71
|
+
unit_of_weight?: string;
|
72
|
+
eel_pfc?: string;
|
73
|
+
contents_type?: string;
|
74
|
+
contents_explanation?: string;
|
75
|
+
customs_certify?: boolean;
|
76
|
+
customs_signer?: string;
|
77
|
+
non_delivery_option?: string;
|
78
|
+
restriction_type?: string;
|
79
|
+
restriction_comments?: string;
|
80
|
+
customs_info_required?: boolean;
|
81
|
+
tracking_number?: string;
|
82
|
+
tracking_status?: string;
|
83
|
+
tracking_status_detail?: string;
|
84
|
+
tracking_status_updated_at?: string;
|
85
|
+
tracking_details?: string;
|
86
|
+
carrier_weight_oz?: string;
|
87
|
+
signed_by?: string;
|
88
|
+
incoterm?: string;
|
89
|
+
shipment?: ShipmentRel;
|
90
|
+
package?: PackageRel;
|
91
|
+
}
|
92
|
+
declare class Parcels extends ApiResource {
|
93
|
+
static readonly TYPE: 'parcels';
|
94
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Parcel>>;
|
95
|
+
create(resource: ParcelCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Parcel>;
|
96
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Parcel>;
|
97
|
+
update(resource: ParcelUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Parcel>;
|
98
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
99
|
+
isParcel(resource: any): resource is Parcel;
|
100
|
+
relationship(id: string | ResourceId): ParcelRel;
|
101
|
+
type(): string;
|
102
|
+
}
|
103
|
+
export default Parcels;
|
104
|
+
export { Parcel, ParcelCreate, ParcelUpdate };
|
@@ -0,0 +1 @@
|
|
1
|
+
import{ApiResource as i}from"../resource";class t extends i{async list(e,r){return this.resources.list({type:t.TYPE},e,r)}async create(e,r,s){return this.resources.create(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async retrieve(e,r,s){return this.resources.retrieve({type:t.TYPE,id:e},r,s)}async update(e,r,s){return this.resources.update(Object.assign(Object.assign({},e),{type:t.TYPE}),r,s)}async delete(e,r){await this.resources.delete({type:t.TYPE,id:e},r)}isParcel(e){return e.type&&e.type===t.TYPE}relationship(e){return typeof e=="string"?{id:e,type:t.TYPE}:{id:e.id,type:t.TYPE}}type(){return t.TYPE}}t.TYPE="parcels";export default t;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { ApiResource, Resource, ResourcesConfig, ResourceId, ListResponse } from '../resource';
|
2
|
+
import { /* QueryBuilderRetrieve, QueryBuilderList, */ QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import { PaymentMethod } from './payment_methods';
|
4
|
+
declare type PaymentGatewayRel = ResourceId & {
|
5
|
+
type: typeof PaymentGateways.TYPE;
|
6
|
+
};
|
7
|
+
interface PaymentGateway extends Resource {
|
8
|
+
name?: string;
|
9
|
+
payment_methods?: PaymentMethod[];
|
10
|
+
}
|
11
|
+
declare class PaymentGateways extends ApiResource {
|
12
|
+
static readonly TYPE: 'payment_gateways';
|
13
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentGateway>>;
|
14
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
|
15
|
+
isPaymentGateway(resource: any): resource is PaymentGateway;
|
16
|
+
relationship(id: string | ResourceId): PaymentGatewayRel;
|
17
|
+
type(): string;
|
18
|
+
}
|
19
|
+
export default PaymentGateways;
|
20
|
+
export { PaymentGateway };
|
@@ -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 retrieve(e,t,s){return this.resources.retrieve({type:r.TYPE,id:e},t,s)}isPaymentGateway(e){return e.type&&e.type===r.TYPE}relationship(e){return typeof e=="string"?{id:e,type:r.TYPE}:{id:e.id,type:r.TYPE}}type(){return r.TYPE}}r.TYPE="payment_gateways";export default r;
|