-
Notifications
You must be signed in to change notification settings - Fork 0
Rule Engine
Make sure you define a valid schema for your event payload. use the following page to generate draft4 schema
https://www.liquid-technologies.com/online-json-to-schema-converter
NOTE do not include the event parameter make sure the types are correct (integer, string, etc)
Before any rule creation, you must define the merchant schema that is done with the API
With the merchant, schema define you can now create rules.
http://164.68.126.56:5000/index.html#/Rule/FidelityRulexWeb_Api_V1_RuleController_create
-
actions can be a list of
"actions": [{"pay": 1}]where 1 is the number of Tokens to be payed. - condition can be
"condition": {
"Operation": "eq",
"key": "total_items",
"value": "1"
}
Where, Operation can be "eq", "lt", "gt" and "key" any of the parameters on the event root.
After the rule is created you must assign it to the merchant Rule Set
http://164.68.126.56:5000/index.html#/Set/FidelityRulexWeb_Api_V1_SetController_create
only after the rule is on the merchant set then an event can be fire against a rule.