The Set Value Step
This step is used to calculate and set the field’s value.
Step Keys
| Key | Type | Required | Comment |
|---|---|---|---|
type |
String |
Yes |
It is filled out with the setValue constant. |
condition |
Step Conditions |
No |
See the Step Conditions. |
object |
Enum |
Yes |
API name of an object. Available values:
|
resultPrice |
String |
Yes |
The object key to store the calculated price. See the Available Field Formats. |
value |
Formula Value Item |
Yes |
See the Formula Value Item. |
Formula Value Item
| Type | Required | Comment |
|---|---|---|
Number |
Yes |
Hardcoded Number value |
String |
The object key to get a price for calculation. See the Available Field Formats. |
|
Object |
Value calculation formula. See the Set Value Condition Formula. |
Set Value Condition Formula
| Key | Type | Required | Comment | ||
|---|---|---|---|---|---|
operator |
Enum |
Yes |
Calculation operator. Available values:
|
||
items |
Array |
Yes |
See the Formula Value Item. |
Examples
-
Standard Set Value Step: Number
Click to view
{ "type": "setValue", "object": "orders__Delivery__c", "resultPrice": "orders__DeliveryFee__c", "value": 20 } -
Standard Set Value Step: Field
Click to view
{ "type": "setValue", "object": "orders_DeliveryLineItem__c", "resultPrice": "$.unitPrice", "value": "orders__ManualPrice__c" } -
Standard Set Value Step: Flat Formula
Click to view
{ "type": "setValue", "object": "orders_DeliveryLineItem__c", "resultPrice": "$.totalPrice", "value": { "operator": "multi", "items": [ "$.unitPrice", "$.quantity" ] } } -
Standard Set Value Step: Complex Formula
Click to view
{ "type": "setValue", "object": "orders_DeliveryLineItem__c", "resultPrice": "$.totalDiscount", "value": { "operator": "sum", "items": [ { "operator": "multi", "items": [ "$.listPrice", "$.quantity" ] }, " - $.totalPrice" ] } }