Adding an Item to an Order with a Rule

IN THIS GUIDE

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.

Step 1 - Add a Condition

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 matchingsku, run the rule. This means that we will run this rule if any item code in the order is equal to matchingsku. 

matchingsku 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.

Step 2 - Add an Action

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": "Product Name", "code": "mysku", "quantity": 1 }

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:

Under Enter Reference Name for This Rule, choose a name for your rule to help you remember what it does. We'll name this one Add "mysku" to Order.

Click Add Rule to save.

To make changes to a rule that you have already created, click the pencil icon to the right of the rule you want to edit.

Still need help? Contact Us Contact Us