@commercelayer/sdk 5.18.0 → 5.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/lib/cjs/api.d.ts +3 -3
  2. package/lib/cjs/commercelayer.d.ts +2 -2
  3. package/lib/cjs/commercelayer.js +1 -1
  4. package/lib/cjs/model.d.ts +3 -3
  5. package/lib/cjs/resources/inventory_models.d.ts +3 -0
  6. package/lib/cjs/resources/payment_methods.d.ts +3 -3
  7. package/lib/cjs/resources/payment_options.d.ts +2 -2
  8. package/lib/cjs/resources/shipments.d.ts +38 -5
  9. package/lib/cjs/resources/shipments.js +19 -0
  10. package/lib/cjs/resources/stock_line_items.d.ts +37 -7
  11. package/lib/cjs/resources/stock_line_items.js +9 -0
  12. package/lib/cjs/resources/stock_reservations.d.ts +19 -3
  13. package/lib/cjs/resources/stock_reservations.js +12 -0
  14. package/lib/cjs/resources/stock_transfers.d.ts +3 -1
  15. package/lib/cjs/resources/stock_transfers.js +3 -0
  16. package/lib/esm/api.d.ts +3 -3
  17. package/lib/esm/commercelayer.d.ts +2 -2
  18. package/lib/esm/commercelayer.js +1 -1
  19. package/lib/esm/model.d.ts +3 -3
  20. package/lib/esm/resources/inventory_models.d.ts +3 -0
  21. package/lib/esm/resources/payment_methods.d.ts +3 -3
  22. package/lib/esm/resources/payment_options.d.ts +2 -2
  23. package/lib/esm/resources/shipments.d.ts +38 -5
  24. package/lib/esm/resources/shipments.js +19 -0
  25. package/lib/esm/resources/stock_line_items.d.ts +37 -7
  26. package/lib/esm/resources/stock_line_items.js +9 -0
  27. package/lib/esm/resources/stock_reservations.d.ts +19 -3
  28. package/lib/esm/resources/stock_reservations.js +12 -0
  29. package/lib/esm/resources/stock_transfers.d.ts +3 -1
  30. package/lib/esm/resources/stock_transfers.js +3 -0
  31. package/lib/tsconfig.esm.tsbuildinfo +1 -1
  32. package/lib/tsconfig.tsbuildinfo +1 -1
  33. package/package.json +3 -3
package/lib/cjs/api.d.ts CHANGED
@@ -134,15 +134,15 @@ export type ListableResourceType = Exclude<ResourceTypeLock, 'application' | 'or
134
134
  export type ListableResource = Resource & {
135
135
  type: ListableResourceType;
136
136
  };
137
- export type CreatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
137
+ export type CreatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_reservations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
138
138
  export type CreatableResource = Resource & {
139
139
  type: CreatableResourceType;
140
140
  };
141
- export type UpdatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'captures' | 'checkout_com_gateways' | 'checkout_com_payments' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
141
+ export type UpdatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'captures' | 'checkout_com_gateways' | 'checkout_com_payments' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_reservations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
142
142
  export type UpdatableResource = Resource & {
143
143
  type: UpdatableResourceType;
144
144
  };
145
- export type DeletableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
145
+ export type DeletableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_reservations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
146
146
  export type DeletableResource = Resource & {
147
147
  type: DeletableResourceType;
148
148
  };
@@ -2,14 +2,14 @@ import * as api from './api';
2
2
  import type { ApiError } from './error';
3
3
  import type { ErrorInterceptor, InterceptorType, RawResponseReader, RequestInterceptor, ResponseInterceptor } from './interceptor';
4
4
  import { type ResourcesInitConfig } from './resource';
5
- declare const OPEN_API_SCHEMA_VERSION = "4.15.0";
5
+ declare const OPEN_API_SCHEMA_VERSION = "4.16.0";
6
6
  export { OPEN_API_SCHEMA_VERSION };
7
7
  type SdkConfig = {};
8
8
  type CommerceLayerInitConfig = SdkConfig & ResourcesInitConfig;
9
9
  type CommerceLayerConfig = Partial<CommerceLayerInitConfig>;
10
10
  declare class CommerceLayerClient {
11
11
  #private;
12
- readonly openApiSchemaVersion = "4.15.0";
12
+ readonly openApiSchemaVersion = "4.16.0";
13
13
  addresses: api.Addresses;
14
14
  adjustments: api.Adjustments;
15
15
  adyen_gateways: api.AdyenGateways;
@@ -45,7 +45,7 @@ const resource_1 = __importDefault(require("./resource"));
45
45
  const debug_1 = __importDefault(require("./debug"));
46
46
  const debug = (0, debug_1.default)('commercelayer');
47
47
  // Autogenerated schema version number, do not remove this line
48
- const OPEN_API_SCHEMA_VERSION = '4.15.0';
48
+ const OPEN_API_SCHEMA_VERSION = '4.16.0';
49
49
  exports.OPEN_API_SCHEMA_VERSION = OPEN_API_SCHEMA_VERSION;
50
50
  class CommerceLayerClient {
51
51
  // ##__CL_RESOURCES_DEF_STOP__##
@@ -92,7 +92,7 @@ export type { ReturnLineItem, ReturnLineItemCreate, ReturnLineItemUpdate } from
92
92
  export type { Return, ReturnCreate, ReturnUpdate } from './resources/returns';
93
93
  export type { SatispayGateway, SatispayGatewayCreate, SatispayGatewayUpdate } from './resources/satispay_gateways';
94
94
  export type { SatispayPayment, SatispayPaymentCreate, SatispayPaymentUpdate } from './resources/satispay_payments';
95
- export type { Shipment, ShipmentUpdate } from './resources/shipments';
95
+ export type { Shipment, ShipmentCreate, ShipmentUpdate } from './resources/shipments';
96
96
  export type { ShippingCategory, ShippingCategoryCreate, ShippingCategoryUpdate } from './resources/shipping_categories';
97
97
  export type { ShippingMethodTier } from './resources/shipping_method_tiers';
98
98
  export type { ShippingMethod, ShippingMethodCreate, ShippingMethodUpdate } from './resources/shipping_methods';
@@ -104,9 +104,9 @@ export type { SkuList, SkuListCreate, SkuListUpdate } from './resources/sku_list
104
104
  export type { SkuOption, SkuOptionCreate, SkuOptionUpdate } from './resources/sku_options';
105
105
  export type { Sku, SkuCreate, SkuUpdate } from './resources/skus';
106
106
  export type { StockItem, StockItemCreate, StockItemUpdate } from './resources/stock_items';
107
- export type { StockLineItem } from './resources/stock_line_items';
107
+ export type { StockLineItem, StockLineItemCreate, StockLineItemUpdate } from './resources/stock_line_items';
108
108
  export type { StockLocation, StockLocationCreate, StockLocationUpdate } from './resources/stock_locations';
109
- export type { StockReservation } from './resources/stock_reservations';
109
+ export type { StockReservation, StockReservationCreate, StockReservationUpdate } from './resources/stock_reservations';
110
110
  export type { StockTransfer, StockTransferCreate, StockTransferUpdate } from './resources/stock_transfers';
111
111
  export type { StripeGateway, StripeGatewayCreate, StripeGatewayUpdate } from './resources/stripe_gateways';
112
112
  export type { StripePayment, StripePaymentCreate, StripePaymentUpdate } from './resources/stripe_payments';
@@ -15,6 +15,7 @@ interface InventoryModel extends Resource {
15
15
  strategy?: string | null;
16
16
  stock_locations_cutoff?: number | null;
17
17
  stock_reservation_cutoff?: number | null;
18
+ put_stock_transfers_on_hold?: boolean | null;
18
19
  inventory_stock_locations?: InventoryStockLocation[] | null;
19
20
  inventory_return_locations?: InventoryReturnLocation[] | null;
20
21
  attachments?: Attachment[] | null;
@@ -25,12 +26,14 @@ interface InventoryModelCreate extends ResourceCreate {
25
26
  strategy?: string | null;
26
27
  stock_locations_cutoff?: number | null;
27
28
  stock_reservation_cutoff?: number | null;
29
+ put_stock_transfers_on_hold?: boolean | null;
28
30
  }
29
31
  interface InventoryModelUpdate extends ResourceUpdate {
30
32
  name?: string | null;
31
33
  strategy?: string | null;
32
34
  stock_locations_cutoff?: number | null;
33
35
  stock_reservation_cutoff?: number | null;
36
+ put_stock_transfers_on_hold?: boolean | null;
34
37
  }
35
38
  declare class InventoryModels extends ApiResource<InventoryModel> {
36
39
  static readonly TYPE: InventoryModelType;
@@ -18,7 +18,7 @@ type PaymentGatewayRel = ResourceRel & {
18
18
  interface PaymentMethod extends Resource {
19
19
  readonly type: PaymentMethodType;
20
20
  name?: string | null;
21
- payment_source_type: 'AdyenPayment' | 'AxervePayment' | 'BraintreePayment' | 'CheckoutComPayment' | 'CreditCard' | 'ExternalPayment' | 'KlarnaPayment' | 'PaypalPayment' | 'SatispayPayment' | 'StripePayment' | 'WireTransfer';
21
+ payment_source_type: 'adyen_payments' | 'axerve_payments' | 'braintree_payments' | 'checkout_com_payments' | 'credit_cards' | 'external_payments' | 'klarna_payments' | 'paypal_payments' | 'satispay_payments' | 'stripe_payments' | 'wire_transfers';
22
22
  currency_code?: string | null;
23
23
  moto?: boolean | null;
24
24
  require_capture?: boolean | null;
@@ -36,7 +36,7 @@ interface PaymentMethod extends Resource {
36
36
  versions?: Version[] | null;
37
37
  }
38
38
  interface PaymentMethodCreate extends ResourceCreate {
39
- payment_source_type: 'AdyenPayment' | 'AxervePayment' | 'BraintreePayment' | 'CheckoutComPayment' | 'CreditCard' | 'ExternalPayment' | 'KlarnaPayment' | 'PaypalPayment' | 'SatispayPayment' | 'StripePayment' | 'WireTransfer';
39
+ payment_source_type: 'adyen_payments' | 'axerve_payments' | 'braintree_payments' | 'checkout_com_payments' | 'credit_cards' | 'external_payments' | 'klarna_payments' | 'paypal_payments' | 'satispay_payments' | 'stripe_payments' | 'wire_transfers';
40
40
  currency_code?: string | null;
41
41
  moto?: boolean | null;
42
42
  require_capture?: boolean | null;
@@ -47,7 +47,7 @@ interface PaymentMethodCreate extends ResourceCreate {
47
47
  payment_gateway: PaymentGatewayRel;
48
48
  }
49
49
  interface PaymentMethodUpdate extends ResourceUpdate {
50
- payment_source_type?: 'AdyenPayment' | 'AxervePayment' | 'BraintreePayment' | 'CheckoutComPayment' | 'CreditCard' | 'ExternalPayment' | 'KlarnaPayment' | 'PaypalPayment' | 'SatispayPayment' | 'StripePayment' | 'WireTransfer' | null;
50
+ payment_source_type?: 'adyen_payments' | 'axerve_payments' | 'braintree_payments' | 'checkout_com_payments' | 'credit_cards' | 'external_payments' | 'klarna_payments' | 'paypal_payments' | 'satispay_payments' | 'stripe_payments' | 'wire_transfers' | null;
51
51
  currency_code?: string | null;
52
52
  moto?: boolean | null;
53
53
  require_capture?: boolean | null;
@@ -13,14 +13,14 @@ type OrderRel = ResourceRel & {
13
13
  interface PaymentOption extends Resource {
14
14
  readonly type: PaymentOptionType;
15
15
  name?: string | null;
16
- payment_source_type: 'AdyenPayment' | 'AxervePayment' | 'BraintreePayment' | 'CheckoutComPayment' | 'CreditCard' | 'ExternalPayment' | 'KlarnaPayment' | 'PaypalPayment' | 'SatispayPayment' | 'StripePayment' | 'WireTransfer';
16
+ payment_source_type: 'adyen_payments' | 'axerve_payments' | 'braintree_payments' | 'checkout_com_payments' | 'credit_cards' | 'external_payments' | 'klarna_payments' | 'paypal_payments' | 'satispay_payments' | 'stripe_payments' | 'wire_transfers';
17
17
  data: Record<string, any>;
18
18
  order?: Order | null;
19
19
  attachments?: Attachment[] | null;
20
20
  }
21
21
  interface PaymentOptionCreate extends ResourceCreate {
22
22
  name?: string | null;
23
- payment_source_type: 'AdyenPayment' | 'AxervePayment' | 'BraintreePayment' | 'CheckoutComPayment' | 'CreditCard' | 'ExternalPayment' | 'KlarnaPayment' | 'PaypalPayment' | 'SatispayPayment' | 'StripePayment' | 'WireTransfer';
23
+ payment_source_type: 'adyen_payments' | 'axerve_payments' | 'braintree_payments' | 'checkout_com_payments' | 'credit_cards' | 'external_payments' | 'klarna_payments' | 'paypal_payments' | 'satispay_payments' | 'stripe_payments' | 'wire_transfers';
24
24
  data: Record<string, any>;
25
25
  order: OrderRel;
26
26
  }
@@ -1,10 +1,11 @@
1
1
  import { ApiResource } from '../resource';
2
- import type { Resource, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
2
+ import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
3
3
  import type { QueryParamsRetrieve, QueryParamsList } from '../query';
4
- import type { Order } from './orders';
5
- import type { ShippingCategory } from './shipping_categories';
4
+ import type { Order, OrderType } from './orders';
5
+ import type { ShippingCategory, ShippingCategoryType } from './shipping_categories';
6
+ import type { InventoryStockLocation, InventoryStockLocationType } from './inventory_stock_locations';
6
7
  import type { StockLocation } from './stock_locations';
7
- import type { Address } from './addresses';
8
+ import type { Address, AddressType } from './addresses';
8
9
  import type { ShippingMethod, ShippingMethodType } from './shipping_methods';
9
10
  import type { DeliveryLeadTime } from './delivery_lead_times';
10
11
  import type { StockLineItem } from './stock_line_items';
@@ -18,6 +19,18 @@ type ShipmentType = 'shipments';
18
19
  type ShipmentRel = ResourceRel & {
19
20
  type: ShipmentType;
20
21
  };
22
+ type OrderRel = ResourceRel & {
23
+ type: OrderType;
24
+ };
25
+ type ShippingCategoryRel = ResourceRel & {
26
+ type: ShippingCategoryType;
27
+ };
28
+ type InventoryStockLocationRel = ResourceRel & {
29
+ type: InventoryStockLocationType;
30
+ };
31
+ type AddressRel = ResourceRel & {
32
+ type: AddressType;
33
+ };
21
34
  type ShippingMethodRel = ResourceRel & {
22
35
  type: ShippingMethodType;
23
36
  };
@@ -47,6 +60,7 @@ interface Shipment extends Resource {
47
60
  shipped_at?: string | null;
48
61
  order?: Order | null;
49
62
  shipping_category?: ShippingCategory | null;
63
+ inventory_stock_location?: InventoryStockLocation | null;
50
64
  stock_location?: StockLocation | null;
51
65
  origin_address?: Address | null;
52
66
  shipping_address?: Address | null;
@@ -65,22 +79,38 @@ interface Shipment extends Resource {
65
79
  events?: Event[] | null;
66
80
  versions?: Version[] | null;
67
81
  }
82
+ interface ShipmentCreate extends ResourceCreate {
83
+ order: OrderRel;
84
+ shipping_category?: ShippingCategoryRel | null;
85
+ inventory_stock_location?: InventoryStockLocationRel | null;
86
+ shipping_address?: AddressRel | null;
87
+ shipping_method?: ShippingMethodRel | null;
88
+ }
68
89
  interface ShipmentUpdate extends ResourceUpdate {
69
90
  _on_hold?: boolean | null;
70
91
  _picking?: boolean | null;
71
92
  _packing?: boolean | null;
72
93
  _ready_to_ship?: boolean | null;
73
94
  _ship?: boolean | null;
95
+ _reserve_stock?: boolean | null;
96
+ _release_stock?: boolean | null;
97
+ _decrement_stock?: boolean | null;
74
98
  _get_rates?: boolean | null;
75
99
  selected_rate_id?: string | null;
76
100
  _purchase?: boolean | null;
101
+ shipping_category?: ShippingCategoryRel | null;
102
+ inventory_stock_location?: InventoryStockLocationRel | null;
103
+ shipping_address?: AddressRel | null;
77
104
  shipping_method?: ShippingMethodRel | null;
78
105
  }
79
106
  declare class Shipments extends ApiResource<Shipment> {
80
107
  static readonly TYPE: ShipmentType;
108
+ create(resource: ShipmentCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
81
109
  update(resource: ShipmentUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
110
+ delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
82
111
  order(shipmentId: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
83
112
  shipping_category(shipmentId: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ShippingCategory>;
113
+ inventory_stock_location(shipmentId: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<InventoryStockLocation>;
84
114
  stock_location(shipmentId: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLocation>;
85
115
  origin_address(shipmentId: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Address>;
86
116
  shipping_address(shipmentId: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Address>;
@@ -99,6 +129,9 @@ declare class Shipments extends ApiResource<Shipment> {
99
129
  _packing(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
100
130
  _ready_to_ship(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
101
131
  _ship(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
132
+ _reserve_stock(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
133
+ _release_stock(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
134
+ _decrement_stock(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
102
135
  _get_rates(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
103
136
  _purchase(id: string | Shipment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
104
137
  isShipment(resource: any): resource is Shipment;
@@ -106,4 +139,4 @@ declare class Shipments extends ApiResource<Shipment> {
106
139
  type(): ShipmentType;
107
140
  }
108
141
  export default Shipments;
109
- export type { Shipment, ShipmentUpdate, ShipmentType };
142
+ export type { Shipment, ShipmentCreate, ShipmentUpdate, ShipmentType };
@@ -2,9 +2,15 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const resource_1 = require("../resource");
4
4
  class Shipments extends resource_1.ApiResource {
5
+ async create(resource, params, options) {
6
+ return this.resources.create({ ...resource, type: Shipments.TYPE }, params, options);
7
+ }
5
8
  async update(resource, params, options) {
6
9
  return this.resources.update({ ...resource, type: Shipments.TYPE }, params, options);
7
10
  }
11
+ async delete(id, options) {
12
+ await this.resources.delete((typeof id === 'string') ? { id, type: Shipments.TYPE } : id, options);
13
+ }
8
14
  async order(shipmentId, params, options) {
9
15
  const _shipmentId = shipmentId.id || shipmentId;
10
16
  return this.resources.fetch({ type: 'orders' }, `shipments/${_shipmentId}/order`, params, options);
@@ -13,6 +19,10 @@ class Shipments extends resource_1.ApiResource {
13
19
  const _shipmentId = shipmentId.id || shipmentId;
14
20
  return this.resources.fetch({ type: 'shipping_categories' }, `shipments/${_shipmentId}/shipping_category`, params, options);
15
21
  }
22
+ async inventory_stock_location(shipmentId, params, options) {
23
+ const _shipmentId = shipmentId.id || shipmentId;
24
+ return this.resources.fetch({ type: 'inventory_stock_locations' }, `shipments/${_shipmentId}/inventory_stock_location`, params, options);
25
+ }
16
26
  async stock_location(shipmentId, params, options) {
17
27
  const _shipmentId = shipmentId.id || shipmentId;
18
28
  return this.resources.fetch({ type: 'stock_locations' }, `shipments/${_shipmentId}/stock_location`, params, options);
@@ -80,6 +90,15 @@ class Shipments extends resource_1.ApiResource {
80
90
  async _ship(id, params, options) {
81
91
  return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: Shipments.TYPE, _ship: true }, params, options);
82
92
  }
93
+ async _reserve_stock(id, params, options) {
94
+ return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: Shipments.TYPE, _reserve_stock: true }, params, options);
95
+ }
96
+ async _release_stock(id, params, options) {
97
+ return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: Shipments.TYPE, _release_stock: true }, params, options);
98
+ }
99
+ async _decrement_stock(id, params, options) {
100
+ return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: Shipments.TYPE, _decrement_stock: true }, params, options);
101
+ }
83
102
  async _get_rates(id, params, options) {
84
103
  return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: Shipments.TYPE, _get_rates: true }, params, options);
85
104
  }
@@ -1,19 +1,30 @@
1
1
  import { ApiResource } from '../resource';
2
- import type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
2
+ import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
3
3
  import type { QueryParamsRetrieve, QueryParamsList } from '../query';
4
- import type { Shipment } from './shipments';
5
- import type { LineItem } from './line_items';
6
- import type { StockItem } from './stock_items';
7
- import type { Sku } from './skus';
4
+ import type { Shipment, ShipmentType } from './shipments';
5
+ import type { LineItem, LineItemType } from './line_items';
6
+ import type { StockItem, StockItemType } from './stock_items';
7
+ import type { Sku, SkuType } from './skus';
8
8
  import type { Version } from './versions';
9
9
  type StockLineItemType = 'stock_line_items';
10
10
  type StockLineItemRel = ResourceRel & {
11
11
  type: StockLineItemType;
12
12
  };
13
+ type ShipmentRel = ResourceRel & {
14
+ type: ShipmentType;
15
+ };
16
+ type LineItemRel = ResourceRel & {
17
+ type: LineItemType;
18
+ };
19
+ type StockItemRel = ResourceRel & {
20
+ type: StockItemType;
21
+ };
22
+ type SkuRel = ResourceRel & {
23
+ type: SkuType;
24
+ };
13
25
  interface StockLineItem extends Resource {
14
26
  readonly type: StockLineItemType;
15
27
  sku_code?: string | null;
16
- bundle_code?: string | null;
17
28
  quantity: number;
18
29
  shipment?: Shipment | null;
19
30
  line_item?: LineItem | null;
@@ -21,8 +32,27 @@ interface StockLineItem extends Resource {
21
32
  sku?: Sku | null;
22
33
  versions?: Version[] | null;
23
34
  }
35
+ interface StockLineItemCreate extends ResourceCreate {
36
+ sku_code?: string | null;
37
+ quantity: number;
38
+ shipment?: ShipmentRel | null;
39
+ line_item?: LineItemRel | null;
40
+ stock_item?: StockItemRel | null;
41
+ sku?: SkuRel | null;
42
+ }
43
+ interface StockLineItemUpdate extends ResourceUpdate {
44
+ sku_code?: string | null;
45
+ quantity?: number | null;
46
+ shipment?: ShipmentRel | null;
47
+ line_item?: LineItemRel | null;
48
+ stock_item?: StockItemRel | null;
49
+ sku?: SkuRel | null;
50
+ }
24
51
  declare class StockLineItems extends ApiResource<StockLineItem> {
25
52
  static readonly TYPE: StockLineItemType;
53
+ create(resource: StockLineItemCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLineItem>;
54
+ update(resource: StockLineItemUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockLineItem>;
55
+ delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
26
56
  shipment(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Shipment>;
27
57
  line_item(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
28
58
  stock_item(stockLineItemId: string | StockLineItem, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
@@ -33,4 +63,4 @@ declare class StockLineItems extends ApiResource<StockLineItem> {
33
63
  type(): StockLineItemType;
34
64
  }
35
65
  export default StockLineItems;
36
- export type { StockLineItem, StockLineItemType };
66
+ export type { StockLineItem, StockLineItemCreate, StockLineItemUpdate, StockLineItemType };
@@ -2,6 +2,15 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const resource_1 = require("../resource");
4
4
  class StockLineItems extends resource_1.ApiResource {
5
+ async create(resource, params, options) {
6
+ return this.resources.create({ ...resource, type: StockLineItems.TYPE }, params, options);
7
+ }
8
+ async update(resource, params, options) {
9
+ return this.resources.update({ ...resource, type: StockLineItems.TYPE }, params, options);
10
+ }
11
+ async delete(id, options) {
12
+ await this.resources.delete((typeof id === 'string') ? { id, type: StockLineItems.TYPE } : id, options);
13
+ }
5
14
  async shipment(stockLineItemId, params, options) {
6
15
  const _stockLineItemId = stockLineItemId.id || stockLineItemId;
7
16
  return this.resources.fetch({ type: 'shipments' }, `stock_line_items/${_stockLineItemId}/shipment`, params, options);
@@ -1,15 +1,18 @@
1
1
  import { ApiResource } from '../resource';
2
- import type { Resource, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
2
+ import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
3
3
  import type { QueryParamsRetrieve } from '../query';
4
4
  import type { LineItem } from './line_items';
5
5
  import type { Order } from './orders';
6
- import type { StockItem } from './stock_items';
6
+ import type { StockItem, StockItemType } from './stock_items';
7
7
  import type { ReservedStock } from './reserved_stocks';
8
8
  import type { Sku } from './skus';
9
9
  type StockReservationType = 'stock_reservations';
10
10
  type StockReservationRel = ResourceRel & {
11
11
  type: StockReservationType;
12
12
  };
13
+ type StockItemRel = ResourceRel & {
14
+ type: StockItemType;
15
+ };
13
16
  interface StockReservation extends Resource {
14
17
  readonly type: StockReservationType;
15
18
  status: 'draft' | 'pending';
@@ -21,16 +24,29 @@ interface StockReservation extends Resource {
21
24
  reserved_stock?: ReservedStock | null;
22
25
  sku?: Sku | null;
23
26
  }
27
+ interface StockReservationCreate extends ResourceCreate {
28
+ quantity: number;
29
+ stock_item: StockItemRel;
30
+ }
31
+ interface StockReservationUpdate extends ResourceUpdate {
32
+ quantity?: number | null;
33
+ _pending?: boolean | null;
34
+ stock_item?: StockItemRel | null;
35
+ }
24
36
  declare class StockReservations extends ApiResource<StockReservation> {
25
37
  static readonly TYPE: StockReservationType;
38
+ create(resource: StockReservationCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockReservation>;
39
+ update(resource: StockReservationUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockReservation>;
40
+ delete(id: string | ResourceId, options?: ResourcesConfig): Promise<void>;
26
41
  line_item(stockReservationId: string | StockReservation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<LineItem>;
27
42
  order(stockReservationId: string | StockReservation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
28
43
  stock_item(stockReservationId: string | StockReservation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockItem>;
29
44
  reserved_stock(stockReservationId: string | StockReservation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<ReservedStock>;
30
45
  sku(stockReservationId: string | StockReservation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Sku>;
46
+ _pending(id: string | StockReservation, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockReservation>;
31
47
  isStockReservation(resource: any): resource is StockReservation;
32
48
  relationship(id: string | ResourceId | null): StockReservationRel;
33
49
  type(): StockReservationType;
34
50
  }
35
51
  export default StockReservations;
36
- export type { StockReservation, StockReservationType };
52
+ export type { StockReservation, StockReservationCreate, StockReservationUpdate, StockReservationType };
@@ -2,6 +2,15 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const resource_1 = require("../resource");
4
4
  class StockReservations extends resource_1.ApiResource {
5
+ async create(resource, params, options) {
6
+ return this.resources.create({ ...resource, type: StockReservations.TYPE }, params, options);
7
+ }
8
+ async update(resource, params, options) {
9
+ return this.resources.update({ ...resource, type: StockReservations.TYPE }, params, options);
10
+ }
11
+ async delete(id, options) {
12
+ await this.resources.delete((typeof id === 'string') ? { id, type: StockReservations.TYPE } : id, options);
13
+ }
5
14
  async line_item(stockReservationId, params, options) {
6
15
  const _stockReservationId = stockReservationId.id || stockReservationId;
7
16
  return this.resources.fetch({ type: 'line_items' }, `stock_reservations/${_stockReservationId}/line_item`, params, options);
@@ -22,6 +31,9 @@ class StockReservations extends resource_1.ApiResource {
22
31
  const _stockReservationId = stockReservationId.id || stockReservationId;
23
32
  return this.resources.fetch({ type: 'skus' }, `stock_reservations/${_stockReservationId}/sku`, params, options);
24
33
  }
34
+ async _pending(id, params, options) {
35
+ return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: StockReservations.TYPE, _pending: true }, params, options);
36
+ }
25
37
  isStockReservation(resource) {
26
38
  return resource.type && (resource.type === StockReservations.TYPE);
27
39
  }
@@ -26,7 +26,7 @@ type LineItemRel = ResourceRel & {
26
26
  interface StockTransfer extends Resource {
27
27
  readonly type: StockTransferType;
28
28
  sku_code?: string | null;
29
- status: 'draft' | 'upcoming' | 'picking' | 'in_transit' | 'completed' | 'cancelled';
29
+ status: 'draft' | 'upcoming' | 'on_hold' | 'picking' | 'in_transit' | 'completed' | 'cancelled';
30
30
  quantity: number;
31
31
  completed_at?: string | null;
32
32
  cancelled_at?: string | null;
@@ -50,6 +50,7 @@ interface StockTransferCreate extends ResourceCreate {
50
50
  interface StockTransferUpdate extends ResourceUpdate {
51
51
  sku_code?: string | null;
52
52
  _upcoming?: boolean | null;
53
+ _on_hold?: boolean | null;
53
54
  _picking?: boolean | null;
54
55
  _in_transit?: boolean | null;
55
56
  _complete?: boolean | null;
@@ -71,6 +72,7 @@ declare class StockTransfers extends ApiResource<StockTransfer> {
71
72
  events(stockTransferId: string | StockTransfer, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Event>>;
72
73
  versions(stockTransferId: string | StockTransfer, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<Version>>;
73
74
  _upcoming(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
75
+ _on_hold(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
74
76
  _picking(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
75
77
  _in_transit(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
76
78
  _complete(id: string | StockTransfer, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<StockTransfer>;
@@ -42,6 +42,9 @@ class StockTransfers extends resource_1.ApiResource {
42
42
  async _upcoming(id, params, options) {
43
43
  return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: StockTransfers.TYPE, _upcoming: true }, params, options);
44
44
  }
45
+ async _on_hold(id, params, options) {
46
+ return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: StockTransfers.TYPE, _on_hold: true }, params, options);
47
+ }
45
48
  async _picking(id, params, options) {
46
49
  return this.resources.update({ id: (typeof id === 'string') ? id : id.id, type: StockTransfers.TYPE, _picking: true }, params, options);
47
50
  }
package/lib/esm/api.d.ts CHANGED
@@ -134,15 +134,15 @@ export type ListableResourceType = Exclude<ResourceTypeLock, 'application' | 'or
134
134
  export type ListableResource = Resource & {
135
135
  type: ListableResourceType;
136
136
  };
137
- export type CreatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
137
+ export type CreatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_reservations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
138
138
  export type CreatableResource = Resource & {
139
139
  type: CreatableResourceType;
140
140
  };
141
- export type UpdatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'captures' | 'checkout_com_gateways' | 'checkout_com_payments' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
141
+ export type UpdatableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'captures' | 'checkout_com_gateways' | 'checkout_com_payments' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_reservations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
142
142
  export type UpdatableResource = Resource & {
143
143
  type: UpdatableResourceType;
144
144
  };
145
- export type DeletableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
145
+ export type DeletableResourceType = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'attachments' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'buy_x_pay_y_promotions' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'custom_promotion_rules' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscription_items' | 'order_subscriptions' | 'orders' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_methods' | 'payment_options' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_frequency_tiers' | 'price_lists' | 'price_volume_tiers' | 'prices' | 'recurring_order_copies' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_reservations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'subscription_models' | 'tags' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'webhooks' | 'wire_transfers';
146
146
  export type DeletableResource = Resource & {
147
147
  type: DeletableResourceType;
148
148
  };
@@ -2,14 +2,14 @@ import * as api from './api';
2
2
  import type { ApiError } from './error';
3
3
  import type { ErrorInterceptor, InterceptorType, RawResponseReader, RequestInterceptor, ResponseInterceptor } from './interceptor';
4
4
  import { type ResourcesInitConfig } from './resource';
5
- declare const OPEN_API_SCHEMA_VERSION = "4.15.0";
5
+ declare const OPEN_API_SCHEMA_VERSION = "4.16.0";
6
6
  export { OPEN_API_SCHEMA_VERSION };
7
7
  type SdkConfig = {};
8
8
  type CommerceLayerInitConfig = SdkConfig & ResourcesInitConfig;
9
9
  type CommerceLayerConfig = Partial<CommerceLayerInitConfig>;
10
10
  declare class CommerceLayerClient {
11
11
  #private;
12
- readonly openApiSchemaVersion = "4.15.0";
12
+ readonly openApiSchemaVersion = "4.16.0";
13
13
  addresses: api.Addresses;
14
14
  adjustments: api.Adjustments;
15
15
  adyen_gateways: api.AdyenGateways;
@@ -16,7 +16,7 @@ import ResourceAdapter from './resource';
16
16
  import Debug from './debug';
17
17
  const debug = Debug('commercelayer');
18
18
  // Autogenerated schema version number, do not remove this line
19
- const OPEN_API_SCHEMA_VERSION = '4.15.0';
19
+ const OPEN_API_SCHEMA_VERSION = '4.16.0';
20
20
  export { OPEN_API_SCHEMA_VERSION };
21
21
  class CommerceLayerClient {
22
22
  // ##__CL_RESOURCES_DEF_STOP__##