How to Add an Item to an Order with a Rule


Adding Conditions
Adding Actions


With Order Desk, you can set up a rule that can add a new item to an order. This guide will walk you through the steps to create this type of rule.

Please note that this rule will not replace one item with another but will instead add an additional item to an order. If you would like to replace one item with another, refer to the Code Replace guide for instructions.

Adding Conditions

Open the Rule Builder by clicking on Rule Builder under Settings in the left sidebar.

In the Rule Builder, under Add New Rule select the dropdown to choose which event will trigger the rule you want to create. For this example, we will choose Order is Imported to create a rule that will add a new item when the order is imported.

Click Continue.

Now that a new rule is being created, you can add conditions and actions. To set up any requirements that must be met for the rule to be used, click Add a Condition.

In our example, we'll apply a condition that states If Item Code is the same as YT-2400, run the rule. This means that we will run this rule if any item code in the order is equal to YT-2400.

YT-2400 is an example item code. For your rule, this needs to be the particular item code necessary to create your condition.

Add more conditions if necessary.

Adding Actions

To add an action, click the Select Action dropdown to add the action you want the rule to do. Because we want the rule to add an item if the previous conditions are met, we will choose Add an Order Item from the list.

Next we are going to add some order JSON in the settings box below the action selected. This sample JSON will work:

{ "name": "XXX", "code": "XXX", "quantity": 1, "price": 2.00 }

Copy the above JSON, or use use the order_item section in our field name list to find the setting you need. This JSON will need to go in the settings box, replacing the XXX's with your product name and code/SKU:

Under Enter Reference Name for This Rule, choose a name for your rule to help you remember what it does. For this example we'll name this rule Add "YT-1300" to Order.

Click Add Rule to save.

Still need help? Contact Us Contact Us