Authorization Rule Example
This example rule advises the authorization system to decline any authorization attempt for an amount greater than $150 at a discount store, department store, variety store, electronic sales store, or music store when the score exceeds 800.
The rule is written in the Decision Ruleset of the
Credit 2.5 Authorization-Posting project.
Rule Narrative
If the transaction type is an authorization and the merchant category code (mcc) is 5310, 5311, 5331, 5732, or 5733, the score is higher than 800, and the transaction amount is greater than $150, set the authorization recommendation to DECLINE the transaction.
Rule Code
In the Free Form Editor, this rule can be written as follows:
if (CRTRAN25.authPostFlag = "A" and ffmFrdCard.Score > 800 and
CRTRAN25.transactionAmount > 150 and (CRTRAN25.mcc = ("5310" or
"5311" or "5331" or "5732" or "5733")))
then SendAuthAdvice(DECLINE);
Components
Conditional statements:
CRTRAN25.authPostFlag = "A"
is a string comparison between the CRTRAN25 transaction object'sauthPostFlag
property value and the string value"A"
.Note: Quotation marks are required for string values.ffmFrdCard.Score > 800
is a numeric comparison between the incoming transaction's fraud score and 800. Numeric values do not need quotation marks.CRTRAN25.transactionAmount > 150
is a numeric comparison between the converted transactionAmount value and 150.(CRTRAN25.mcc = ("5310" or "5311" or "5331" or "5732" or "5733"))
defines string comparisons between the incoming transaction's merchant category code (CRTRAN25.mcc
) and multiple values joined by the "or" operator. Using "or" indicates that any of the values will satisfy the condition.
Action statement:
- The
then portion of the rule can include up to six actions. In this example there is a single action, which calls the
SendAuthAdvice function with the keyword value
DECLINE
.
Data Fields:
CRTRAN25.authPostFlag
is the incoming transaction field that indicates the transaction type. In this example, the field is compared to the value of A. If the incoming transaction matches this value, this condition is met.CRTRAN25.mcc
provides the merchant category code, which is the SIC (Standard Industrial Classification) code for the type of merchant business. In this example, 5310, 5311, 5331, 5732, and 5733 indicate various types of retail stores.CRTRAN25.transactionAmount
stores the transaction amount. In this example the amount of the incoming transaction must exceed $150.ffmFrdCard.score
stores the score value provided by the Falcon Server.
Operators:
- The
and
operator links multiple conditions. When linked, all conditions must be true for the rule to execute. Theor
operator links conditions, only one of which must be true for the rule to execute. Multiple conditional statements are evaluated left to right, top to bottom. Statements enclosed in parenthesis are resolved together. In this case, the first three conditions joined byand
must all evaluate to true, and any one of the expressions joined byor
must evaluate to true, before the rule action will fire.
Function:
- SendAuthAdvice sends a message to the authorization system with the recommended action.