@commercelayer/cli-plugin-triggers 3.13.1 → 3.15.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/README.md +653 -5
- package/lib/base.d.ts +1 -0
- package/lib/base.js +5 -0
- package/lib/commands/adyen_payment/details.js +1 -2
- package/lib/commands/authorization/capture.js +1 -2
- package/lib/commands/authorization/capture_amount_cents.js +1 -2
- package/lib/commands/authorization/void.js +1 -2
- package/lib/commands/axerve_payment/update.js +1 -2
- package/lib/commands/bundle/compute_compare_at_amount.js +1 -2
- package/lib/commands/bundle/compute_price_amount.js +1 -2
- package/lib/commands/buy_x_pay_y_promotion/disable.d.ts +9 -0
- package/lib/commands/buy_x_pay_y_promotion/disable.js +20 -0
- package/lib/commands/buy_x_pay_y_promotion/enable.d.ts +9 -0
- package/lib/commands/buy_x_pay_y_promotion/enable.js +20 -0
- package/lib/commands/buy_x_pay_y_promotion/index.d.ts +9 -0
- package/lib/commands/buy_x_pay_y_promotion/index.js +38 -0
- package/lib/commands/capture/refund.js +1 -2
- package/lib/commands/capture/refund_amount_cents.js +1 -2
- package/lib/commands/checkout_com_payment/details.js +1 -2
- package/lib/commands/checkout_com_payment/refresh.js +1 -2
- package/lib/commands/customer_password_reset/reset_password_token.js +1 -2
- package/lib/commands/external_promotion/disable.d.ts +9 -0
- package/lib/commands/external_promotion/disable.js +20 -0
- package/lib/commands/external_promotion/enable.d.ts +9 -0
- package/lib/commands/external_promotion/enable.js +20 -0
- package/lib/commands/external_promotion/index.d.ts +9 -0
- package/lib/commands/external_promotion/index.js +38 -0
- package/lib/commands/fixed_amount_promotion/disable.d.ts +9 -0
- package/lib/commands/fixed_amount_promotion/disable.js +20 -0
- package/lib/commands/fixed_amount_promotion/enable.d.ts +9 -0
- package/lib/commands/fixed_amount_promotion/enable.js +20 -0
- package/lib/commands/fixed_amount_promotion/index.d.ts +9 -0
- package/lib/commands/fixed_amount_promotion/index.js +38 -0
- package/lib/commands/fixed_price_promotion/disable.d.ts +9 -0
- package/lib/commands/fixed_price_promotion/disable.js +20 -0
- package/lib/commands/fixed_price_promotion/enable.d.ts +9 -0
- package/lib/commands/fixed_price_promotion/enable.js +20 -0
- package/lib/commands/fixed_price_promotion/index.d.ts +9 -0
- package/lib/commands/fixed_price_promotion/index.js +38 -0
- package/lib/commands/free_gift_promotion/disable.d.ts +9 -0
- package/lib/commands/free_gift_promotion/disable.js +20 -0
- package/lib/commands/free_gift_promotion/enable.d.ts +9 -0
- package/lib/commands/free_gift_promotion/enable.js +20 -0
- package/lib/commands/free_gift_promotion/index.d.ts +9 -0
- package/lib/commands/free_gift_promotion/index.js +38 -0
- package/lib/commands/free_shipping_promotion/disable.d.ts +9 -0
- package/lib/commands/free_shipping_promotion/disable.js +20 -0
- package/lib/commands/free_shipping_promotion/enable.d.ts +9 -0
- package/lib/commands/free_shipping_promotion/enable.js +20 -0
- package/lib/commands/free_shipping_promotion/index.d.ts +9 -0
- package/lib/commands/free_shipping_promotion/index.js +38 -0
- package/lib/commands/gift_card/activate.js +1 -2
- package/lib/commands/gift_card/balance_change_cents.js +1 -2
- package/lib/commands/gift_card/deactivate.js +1 -2
- package/lib/commands/gift_card/purchase.js +1 -2
- package/lib/commands/in_stock_subscription/activate.js +1 -2
- package/lib/commands/in_stock_subscription/deactivate.js +1 -2
- package/lib/commands/klarna_payment/update.js +1 -2
- package/lib/commands/line_item/external_price.js +1 -2
- package/lib/commands/line_item/reserve_stock.js +1 -2
- package/lib/commands/market/disable.js +1 -2
- package/lib/commands/market/enable.js +1 -2
- package/lib/commands/order/approve.js +1 -2
- package/lib/commands/order/approve_and_capture.js +1 -2
- package/lib/commands/order/archive.js +1 -2
- package/lib/commands/order/authorization_amount_cents.js +1 -2
- package/lib/commands/order/authorize.js +1 -2
- package/lib/commands/order/billing_address_clone_id.js +1 -2
- package/lib/commands/order/billing_address_same_as_shipping.js +1 -2
- package/lib/commands/order/cancel.js +1 -2
- package/lib/commands/order/capture.js +1 -2
- package/lib/commands/order/commit_invoice.js +1 -2
- package/lib/commands/order/create_subscriptions.js +1 -2
- package/lib/commands/order/customer_payment_source_id.js +1 -2
- package/lib/commands/order/nullify_payment_source.js +1 -2
- package/lib/commands/order/place.js +1 -2
- package/lib/commands/order/refresh.js +1 -2
- package/lib/commands/order/refund.js +1 -2
- package/lib/commands/order/refund_invoice.js +1 -2
- package/lib/commands/order/save_billing_address_to_customer_address_book.js +1 -2
- package/lib/commands/order/save_payment_source_to_customer_wallet.js +1 -2
- package/lib/commands/order/save_shipping_address_to_customer_address_book.js +1 -2
- package/lib/commands/order/shipping_address_clone_id.js +1 -2
- package/lib/commands/order/shipping_address_same_as_billing.js +1 -2
- package/lib/commands/order/start_editing.js +1 -2
- package/lib/commands/order/stop_editing.js +1 -2
- package/lib/commands/order/unarchive.js +1 -2
- package/lib/commands/order/update_taxes.js +1 -2
- package/lib/commands/order/validate.js +1 -2
- package/lib/commands/order_subscription/activate.js +1 -2
- package/lib/commands/order_subscription/cancel.js +1 -2
- package/lib/commands/order_subscription/deactivate.js +1 -2
- package/lib/commands/payment_method/disable.js +1 -2
- package/lib/commands/payment_method/enable.js +1 -2
- package/lib/commands/percentage_discount_promotion/disable.d.ts +9 -0
- package/lib/commands/percentage_discount_promotion/disable.js +20 -0
- package/lib/commands/percentage_discount_promotion/enable.d.ts +9 -0
- package/lib/commands/percentage_discount_promotion/enable.js +20 -0
- package/lib/commands/percentage_discount_promotion/index.d.ts +9 -0
- package/lib/commands/percentage_discount_promotion/index.js +38 -0
- package/lib/commands/return/approve.js +1 -2
- package/lib/commands/return/archive.js +1 -2
- package/lib/commands/return/cancel.js +1 -2
- package/lib/commands/return/receive.js +1 -2
- package/lib/commands/return/reject.js +1 -2
- package/lib/commands/return/request.js +1 -2
- package/lib/commands/return/restock.js +1 -2
- package/lib/commands/return/ship.js +1 -2
- package/lib/commands/return/unarchive.js +1 -2
- package/lib/commands/return_line_item/restock.js +1 -2
- package/lib/commands/satispay_payment/refresh.js +1 -2
- package/lib/commands/shipment/decrement_stock.d.ts +9 -0
- package/lib/commands/shipment/decrement_stock.js +20 -0
- package/lib/commands/shipment/get_rates.js +1 -2
- package/lib/commands/shipment/on_hold.js +1 -2
- package/lib/commands/shipment/packing.js +1 -2
- package/lib/commands/shipment/picking.js +1 -2
- package/lib/commands/shipment/purchase.js +1 -2
- package/lib/commands/shipment/ready_to_ship.js +1 -2
- package/lib/commands/shipment/release_stock.d.ts +9 -0
- package/lib/commands/shipment/release_stock.js +20 -0
- package/lib/commands/shipment/reserve_stock.d.ts +9 -0
- package/lib/commands/shipment/reserve_stock.js +20 -0
- package/lib/commands/shipment/ship.js +1 -2
- package/lib/commands/shipment/upcoming.d.ts +9 -0
- package/lib/commands/shipment/upcoming.js +20 -0
- package/lib/commands/shipping_method/disable.js +1 -2
- package/lib/commands/shipping_method/enable.js +1 -2
- package/lib/commands/stock_reservation/index.d.ts +9 -0
- package/lib/commands/stock_reservation/index.js +38 -0
- package/lib/commands/stock_reservation/pending.d.ts +9 -0
- package/lib/commands/stock_reservation/pending.js +20 -0
- package/lib/commands/stock_transfer/cancel.js +1 -2
- package/lib/commands/stock_transfer/complete.js +1 -2
- package/lib/commands/stock_transfer/in_transit.js +1 -2
- package/lib/commands/stock_transfer/on_hold.d.ts +9 -0
- package/lib/commands/stock_transfer/on_hold.js +20 -0
- package/lib/commands/stock_transfer/picking.js +1 -2
- package/lib/commands/stock_transfer/upcoming.js +1 -2
- package/lib/commands/stripe_payment/refresh.js +1 -2
- package/lib/commands/stripe_payment/update.js +1 -2
- package/lib/commands/webhook/reset_circuit.js +1 -2
- package/lib/exec.d.ts +3 -2
- package/lib/exec.js +7 -4
- package/lib/triggers/buy_x_pay_y_promotions.d.ts +3 -0
- package/lib/triggers/buy_x_pay_y_promotions.js +15 -0
- package/lib/triggers/external_promotions.d.ts +3 -0
- package/lib/triggers/external_promotions.js +15 -0
- package/lib/triggers/fixed_amount_promotions.d.ts +3 -0
- package/lib/triggers/fixed_amount_promotions.js +15 -0
- package/lib/triggers/fixed_price_promotions.d.ts +3 -0
- package/lib/triggers/fixed_price_promotions.js +15 -0
- package/lib/triggers/free_gift_promotions.d.ts +3 -0
- package/lib/triggers/free_gift_promotions.js +15 -0
- package/lib/triggers/free_shipping_promotions.d.ts +3 -0
- package/lib/triggers/free_shipping_promotions.js +15 -0
- package/lib/triggers/line_items.js +1 -1
- package/lib/triggers/orders.js +1 -1
- package/lib/triggers/percentage_discount_promotions.d.ts +3 -0
- package/lib/triggers/percentage_discount_promotions.js +15 -0
- package/lib/triggers/shipments.d.ts +1 -1
- package/lib/triggers/shipments.js +20 -0
- package/lib/triggers/stock_reservations.d.ts +3 -0
- package/lib/triggers/stock_reservations.js +10 -0
- package/lib/triggers/stock_transfers.d.ts +1 -1
- package/lib/triggers/stock_transfers.js +5 -0
- package/oclif.manifest.json +7757 -3720
- package/package.json +17 -17
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.triggers = void 0;
|
|
4
|
+
exports.triggers = {
|
|
5
|
+
disable: {
|
|
6
|
+
action: 'disable',
|
|
7
|
+
trigger: '_disable',
|
|
8
|
+
description: 'Send this attribute if you want to mark the promotion as disabled.',
|
|
9
|
+
},
|
|
10
|
+
enable: {
|
|
11
|
+
action: 'enable',
|
|
12
|
+
trigger: '_enable',
|
|
13
|
+
description: 'Send this attribute if you want to mark the promotion as enabled.',
|
|
14
|
+
},
|
|
15
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.triggers = void 0;
|
|
4
|
+
exports.triggers = {
|
|
5
|
+
disable: {
|
|
6
|
+
action: 'disable',
|
|
7
|
+
trigger: '_disable',
|
|
8
|
+
description: 'Send this attribute if you want to mark the promotion as disabled.',
|
|
9
|
+
},
|
|
10
|
+
enable: {
|
|
11
|
+
action: 'enable',
|
|
12
|
+
trigger: '_enable',
|
|
13
|
+
description: 'Send this attribute if you want to mark the promotion as enabled.',
|
|
14
|
+
},
|
|
15
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.triggers = void 0;
|
|
4
|
+
exports.triggers = {
|
|
5
|
+
disable: {
|
|
6
|
+
action: 'disable',
|
|
7
|
+
trigger: '_disable',
|
|
8
|
+
description: 'Send this attribute if you want to mark the promotion as disabled.',
|
|
9
|
+
},
|
|
10
|
+
enable: {
|
|
11
|
+
action: 'enable',
|
|
12
|
+
trigger: '_enable',
|
|
13
|
+
description: 'Send this attribute if you want to mark the promotion as enabled.',
|
|
14
|
+
},
|
|
15
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.triggers = void 0;
|
|
4
|
+
exports.triggers = {
|
|
5
|
+
disable: {
|
|
6
|
+
action: 'disable',
|
|
7
|
+
trigger: '_disable',
|
|
8
|
+
description: 'Send this attribute if you want to mark the promotion as disabled.',
|
|
9
|
+
},
|
|
10
|
+
enable: {
|
|
11
|
+
action: 'enable',
|
|
12
|
+
trigger: '_enable',
|
|
13
|
+
description: 'Send this attribute if you want to mark the promotion as enabled.',
|
|
14
|
+
},
|
|
15
|
+
};
|
|
@@ -5,7 +5,7 @@ exports.triggers = {
|
|
|
5
5
|
external_price: {
|
|
6
6
|
action: 'external_price',
|
|
7
7
|
trigger: '_external_price',
|
|
8
|
-
description: 'When creating or updating a new line item, set this attribute to \'1\' if you want to inject the unit_amount_cents price from an external source.',
|
|
8
|
+
description: 'When creating or updating a new line item, set this attribute to \'1\' if you want to inject the unit_amount_cents price from an external source. Any successive price computation will be done externally, until the attribute is reset to \'0\'.',
|
|
9
9
|
},
|
|
10
10
|
reserve_stock: {
|
|
11
11
|
action: 'reserve_stock',
|
package/lib/triggers/orders.js
CHANGED
|
@@ -125,7 +125,7 @@ exports.triggers = {
|
|
|
125
125
|
create_subscriptions: {
|
|
126
126
|
action: 'create_subscriptions',
|
|
127
127
|
trigger: '_create_subscriptions',
|
|
128
|
-
description: 'Send this attribute if you want to create order subscriptions from the
|
|
128
|
+
description: 'Send this attribute upon/after placing the order if you want to create order subscriptions from the line items that have a frequency.',
|
|
129
129
|
},
|
|
130
130
|
start_editing: {
|
|
131
131
|
action: 'start_editing',
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.triggers = void 0;
|
|
4
|
+
exports.triggers = {
|
|
5
|
+
disable: {
|
|
6
|
+
action: 'disable',
|
|
7
|
+
trigger: '_disable',
|
|
8
|
+
description: 'Send this attribute if you want to mark the promotion as disabled.',
|
|
9
|
+
},
|
|
10
|
+
enable: {
|
|
11
|
+
action: 'enable',
|
|
12
|
+
trigger: '_enable',
|
|
13
|
+
description: 'Send this attribute if you want to mark the promotion as enabled.',
|
|
14
|
+
},
|
|
15
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { Trigger } from '../common';
|
|
2
2
|
export declare const triggers: Record<string, Trigger>;
|
|
3
|
-
export type ActionType = 'on_hold' | 'picking' | 'packing' | 'ready_to_ship' | 'ship' | 'get_rates' | 'purchase';
|
|
3
|
+
export type ActionType = 'upcoming' | 'on_hold' | 'picking' | 'packing' | 'ready_to_ship' | 'ship' | 'reserve_stock' | 'release_stock' | 'decrement_stock' | 'get_rates' | 'purchase';
|
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.triggers = void 0;
|
|
4
4
|
exports.triggers = {
|
|
5
|
+
upcoming: {
|
|
6
|
+
action: 'upcoming',
|
|
7
|
+
trigger: '_upcoming',
|
|
8
|
+
description: 'Send this attribute if you want to mark this shipment as upcoming.',
|
|
9
|
+
},
|
|
5
10
|
on_hold: {
|
|
6
11
|
action: 'on_hold',
|
|
7
12
|
trigger: '_on_hold',
|
|
@@ -27,6 +32,21 @@ exports.triggers = {
|
|
|
27
32
|
trigger: '_ship',
|
|
28
33
|
description: 'Send this attribute if you want to mark this shipment as shipped.',
|
|
29
34
|
},
|
|
35
|
+
reserve_stock: {
|
|
36
|
+
action: 'reserve_stock',
|
|
37
|
+
trigger: '_reserve_stock',
|
|
38
|
+
description: 'Send this attribute if you want to automatically reserve the stock for each of the associated stock line item. Can be done only when fulfillment is in progress.',
|
|
39
|
+
},
|
|
40
|
+
release_stock: {
|
|
41
|
+
action: 'release_stock',
|
|
42
|
+
trigger: '_release_stock',
|
|
43
|
+
description: 'Send this attribute if you want to automatically release the stock for each of the associated stock line item. Can be done only when fulfillment is in progress.',
|
|
44
|
+
},
|
|
45
|
+
decrement_stock: {
|
|
46
|
+
action: 'decrement_stock',
|
|
47
|
+
trigger: '_decrement_stock',
|
|
48
|
+
description: 'Send this attribute if you want to automatically decrement and release the stock for each of the associated stock line item. Can be done only when fulfillment is in progress.',
|
|
49
|
+
},
|
|
30
50
|
get_rates: {
|
|
31
51
|
action: 'get_rates',
|
|
32
52
|
trigger: '_get_rates',
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.triggers = void 0;
|
|
4
|
+
exports.triggers = {
|
|
5
|
+
pending: {
|
|
6
|
+
action: 'pending',
|
|
7
|
+
trigger: '_pending',
|
|
8
|
+
description: 'Send this attribute if you want to mark this stock reservation as pending.',
|
|
9
|
+
},
|
|
10
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { Trigger } from '../common';
|
|
2
2
|
export declare const triggers: Record<string, Trigger>;
|
|
3
|
-
export type ActionType = 'upcoming' | 'picking' | 'in_transit' | 'complete' | 'cancel';
|
|
3
|
+
export type ActionType = 'upcoming' | 'on_hold' | 'picking' | 'in_transit' | 'complete' | 'cancel';
|
|
@@ -7,6 +7,11 @@ exports.triggers = {
|
|
|
7
7
|
trigger: '_upcoming',
|
|
8
8
|
description: 'Send this attribute if you want to mark this stock transfer as upcoming.',
|
|
9
9
|
},
|
|
10
|
+
on_hold: {
|
|
11
|
+
action: 'on_hold',
|
|
12
|
+
trigger: '_on_hold',
|
|
13
|
+
description: 'Send this attribute if you want to put this stock transfer on hold.',
|
|
14
|
+
},
|
|
10
15
|
picking: {
|
|
11
16
|
action: 'picking',
|
|
12
17
|
trigger: '_picking',
|