8.4.6 Setup Price Rules/Dynamic Pricing (Feature Setting)
Version | 2.119 and up |
|---|---|
Support AdServers | N/A |
Note | The |
Custom Fields as Matching Criteria: Matching Criterion
For additional flexibility within the Price Rules/Dynamic Pricing, you can configure your own custom fields as matching criteria for your price rules. Any number of custom fields or fields from the ADvendio Package can be configured as additional matching criteria.
Open or create a record with the feature setting name: Matching Criterion and Feature Name: Dynamic Pricing
If not existing yet, please create the custom field for both the target object and price rules object and fill in the following field API names in the JSON below to map these fields together. You need to have a good understanding of your data model to set the right combination of custom fields and may need to map new fields for the custom price rule to work. The custom fields you set in this feature setting will affect all records so utilize custom flag fields accordingly to make the price rules work for your custom business logic.
Feature Setting Name: Matching Criterion
Feature Name: Dynamic Pricing
Value: Is for you to configure. Please use the following syntax and don't forget the squared brackets to close in the whole string, and curly brackets for each value, and separate everything with a comma.
[{"operator":"==","field":"API Name of Field from Campaign Item (or related object)","conditionField":"API Name of the Field from Price Rule"}]
Above, in the screenshot, you can see an example of custom matching criteria for the billing category field located on the Ad Price level.
Another example is the combination of multiple fields, such as matching criteria for a custom Start and End Date:
[{"operator":"<=","field":"ADvendio__until_Date__c","conditionField":"Custom_End_Date__c"},{"operator":">=","field":"ADvendio__from_Date__c","conditionField":"Custom_Start_Date__c"}]Please make sure that you use no whitespace or line break in the setting
You can use any field from an object related to Campaign Item, to do the objects need to be connected via Lookup / Master-Detail Field and you need to enter the entire field path.
Any of the following operators can be used: ==, !=, <, >, <=, >=, in, not in. Attention: not all operators can be used for all field combinations, example < will not work when comparing Picklist Fields or Checkboxes. The "in" and "not in" operators are exclusively for multi-select picklist fields.
To reduce errors, make sure the fields you compare are of the same type, and picklists have the same picklist values
Price Rule Custom Matching with Multi-Select Picklists
The in operator supports matching between multi-select picklist fields.
To ensure accurate matching, please use the 'in' operator for multi-picklist instead of '==' in feature setting.
Use the in operator when the price rule should apply only if all values selected on the Price Rule multi-select picklist are also selected on the Campaign Item multi-select picklist. The rule can still apply when the Campaign Item has additional selected values.
Example with a multi-picklist field for Targeting surcharges:
Geo
Inventory
Device
A match occurs when all values from the Price Rule are selected on the Campaign Item's multi-select picklist. This means the Campaign Item may include additional selections and still match, as shown in the table below:
Price Rule value | Campaign Item value | Expected behaviour |
|---|---|---|
Geo | Geo | Matching |
Geo | Geo, Inventory | Matching |
Geo, Inventory | Geo | Not Matching |
Device, Inventory | Inventory | Not Matching
|
Price Rule Custom Matching: Excluding Multi-Select Picklist Values
The not in operator supports exclusion-based price rule matching for multi-select picklist fields.
Use the not in operator when a price rule should not apply if any of the specified values are present on the Campaign Item's multi-select picklist.
When to use "not in"
Use "not in" when your business logic requires a price rule to be excluded or skipped based on certain targeting or attribute values, for example skipping a surcharge when specific targeting options are already selected.
Syntax
Use the following syntax in your Matching Criterion feature setting:
[{"operator":"not in","field":"API Name of Multi-Select Field from Campaign Item","conditionField":"API Name of Multi-Select Field from Price Rule"}]Behavior
When you use the "not in" operator:
The price rule is not applied if any value from the Price Rule multi-select picklist is also present in the Campaign Item multi-select picklist.
The price rule is applied only when none of the Price Rule values appear in the Campaign Item field.
Example with a multi-picklist field for Targeting surcharges:
Geo
Inventory
Device
Price Rule value | Campaign Item value | Expected behaviour |
|---|---|---|
Geo | Geo | Not Matching (rule excluded) |
Geo | Geo, Inventory | Not Matching (rule excluded) |
Geo | Inventory | Matching (rule applied) |
Geo, Inventory | Device | Matching (rule applied) |
Geo, Inventory | Geo | Not Matching (rule excluded) |
No value selected | Geo, Inventory | Matching (rule applied) |
Important Notes
The "not in" operator is exclusively for multi-select picklist fields. Do not use it with other field types.
Make sure the picklist values on both the Price Rule and Campaign Item fields are identical and use the same API values.
As with all feature settings, do not use whitespace or line breaks in the JSON value.