Cybersource
Cybersource Decision Manager utilises machine learning capabilities to detect and prevent fraud whilst reducing payment frictions for the good transactions. The fraud check process occurs after the payment has been processed as the outcome of the payment will form part of the data that the Cybersource Decision Manager uses to determine if an order may be fraudulent. Wpay passes back both the outcome of the payment and the fraud checking process to the user. Possible fraud checking responses may be Accept, Reject, Review, or Unexpected error.
Decision | Reason Code | Description |
---|---|---|
Accept | 100 | No fraud detected. Advice is that payment can proceed. |
Review | 480 | Fraud potential. Payment should be manually reviewed to determine fraud decision. |
Reject | 101 | The request is missing one or more fields. Resend the request with the correct information. |
Reject | 102 | One or more fields in the request contains invalid data. |
Reject | 481 | Fraud likely. Advice is that payment should be voided or refunded. |
Unexpected error | UN99 | Failed to perform fraud check due to unexpected error. |
The user may then determine the desired customer experience and how they wish to proceed with the transaction based on the payment and fraud outcomes i.e. if the outcome is Reject (481) you may wish to cancel the order and refund/void the payment.
Should you require the use of Cybersource Decision Manager, we will need to configure this for you along with any of your merchant-specific rules during the onboarding process. Once successfully set up you can submit a request to make a payment with the fraud payload included to trigger the fraud-checking process.
Fraud Payload
During payments or payment instrument verification where the fraud payload is present you can pass in the fraud payload with the required fields. The fraud payload is passed as a BLOB object and can be passed as both XML or ZIP BASE64 encoded.
Field Definition
Field | Description | Mandatory / Data Type |
---|---|---|
merchantID | Your Cybersource merchant ID which will be provided to you when set up with Cybersource. | Yes String (30) |
merchantReferenceCode | Unique merchant-generated order reference or tracking number for each transaction. Typically this would be the Client Reference you provided as part of the payment transaction. | Yes String (50) |
Bill To - firstName | The first name of the customer paying for the good/service | Yes String (60) |
Bill To - lastName | The last name of the customer paying for the good/service | Yes String (60) |
Bill To - street1 | The street address of the customer paying for the good/service | Yes String (60) |
Bill To - city | The city of the customer paying for the good/service | Yes String (50) |
Bill To - state | The state of the customer paying for the good/service. Use the 2-3 digit ISO state code. | Yes String (3) |
Bill To - postalCode | The postal code of the customer paying for the good/service. | Yes String (10) |
Bill To - country | The country of the customer paying for the good/service. Use the two-character ISO country codes. | Yes String (2) |
Bill To - email | The email of the customer paying for the good/service including the full domain name. | Yes String (255) |
Bill To - ipAddress | The IP address of the customer paying for the good/service reported by your web server using socket information. | No String (45) |
Bill To - dateOfBirth | The date of birth of the customer paying for the good/service. Use the format: YYYYMMDD. | No |
Bill To - customerID | The customer identifier of the customer paying for the good/service. This is typically the same value provided as the shopper ID when identifying the customer. | No |
Ship To - firstName | The first name of the customer receiving for the good/service | No String (60) |
Ship To - lastName | The last name of the customer receiving for the good/service | No String (60) |
Ship To - street1 | The street address of the customer receiving the good/service | No String (60) |
Ship To - city | The city of the customer receiving the good/service | No String (50) |
Ship To - state | The state of the customer receiving the good/service. Use the 2-3 digit ISO state code. | No String (3) |
Ship To - postalCode | The postal code of the customer receiving the good/service. | No String (10) |
Ship To - country | The country of the customer receiving the good/service. Use the two-character ISO country codes. | No String (2) |
Ship To - phoneNumber | The phone number of the customer receiving the good/service. Add the country code at the beginning of the phone number, if possible. Otherwise, the billing country is used to determine the country code. Do not use dashes, spaces, or parentheses. | No String (15) |
Ship To - email | The email of the customer receiving the good/service. | |
Item - unitPrice | The unit price for the good/service being purchased. This value cannot be negative. You can include a decimal point (.), but you cannot include any other special characters. | Yes String (15) |
Item - quantity | The quantity of the good/service being purchased | No Integer (10) |
Item - productName | The name of the good/service being purchased. | No String (255) |
Item - productSKU | Identification code (SKU) for the good/service being purchased. | No String (255) |
Purchase Totals - currency | The currency of the good/service being purchased. Use the ISO currency codes. | Yes String (5) |
Purchase Totals - grandTotalAmount | The total value of the basket/order for the goods/services being purchased. Must be greater than or equal to zero and must equal the total amount of each line item including the tax amount. Your request must include either this field or item_#_unitPrice. | No Decimal (15) |
merchantDefinedData -1-60 | 60 available fields where merchant specific data can be specified based on your merchant specific rules set up with Cybersource | No |
afsService run | Whether to include the Cybersource afsService run in your request. This field can be set to either true or false. We suggest always setting this to true to enable fraud scoring which is required in many rules. | Yes Boolean |
deviceFingerprintID | The session ID for the fingerprint can use any string that you are already generating, such as an order number or web session ID. The string can contain uppercase and lowercase letters, digits, and these special characters: hyphen (-) and underscore (_). | No |
Fraud Payload Example
An example of what the fraud payload in its XML form will look like:
<?xml version="1.0" encoding="Windows-1252"?>
<RequestMessage xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance">
<merchantID>woolworths_online</merchantID>
<merchantReferenceCode>18SJBB-26IO8JUN</merchantReferenceCode>
<billTo>
<firstName>Jane</firstName>
<lastName>Doe</lastName>
<street1>407 ELIZABETH STREET</street1>
<city>SURRY HILLS</city>
<state>NSW</state>
<postalCode>2199</postalCode>
<country>AU</country>
<phoneNumber>0400000000</phoneNumber>
<email>[email protected]</email>
<ipAddress>203.39.218.236</ipAddress>
<dateOfBirth>1970-01-01</dateOfBirth>
<customerID>123456</customerID>
</billTo>
<shipTo>
<firstName>Jane</firstName>
<lastName>Doe</lastName>
<phoneNumber>0400000000</phoneNumber>
<email>[email protected]</email>
</shipTo>
<item id="0">
<unitPrice>7.59</unitPrice>
<quantity>2</quantity>
<productName>Mccain Protein Plus Frozen Meal Satay Chicken</productName>
<productSKU>483660</productSKU>
</item>
<item id="1">
<unitPrice>2.00</unitPrice>
<quantity>2</quantity>
<productName>Habee Savers Needles Household Repair</productName>
<productSKU>159489</productSKU>
</item>
<item id="2">
<unitPrice>6.60</unitPrice>
<quantity>5</quantity>
<productName>Chicken Breast Fillet Skinless Small</productName>
<productSKU>118963</productSKU>
</item>
<item id="3">
<unitPrice>5.43</unitPrice>
<quantity>5</quantity>
<productName>Chicken Drumsticks </productName>
<productSKU>169014</productSKU>
</item>
<item id="4">
<unitPrice>3.50</unitPrice>
<quantity>4</quantity>
<productName>Chicken Thigh Cutlets Skinless</productName>
<productSKU>166830</productSKU>
</item>
<item id="5">
<unitPrice>10.80</unitPrice>
<quantity>4</quantity>
<productName>Lamb Diced Heart Smart</productName>
<productSKU>208970</productSKU>
</item>
<item id="6">
<unitPrice>4.94</unitPrice>
<quantity>2</quantity>
<productName>Macro Chicken Lovely Legs Free Range</productName>
<productSKU>700257</productSKU>
</item>
<item id="7">
<unitPrice>19.64</unitPrice>
<quantity>2</quantity>
<productName>Macro Organic Whole Chicken</productName>
<productSKU>229320</productSKU>
</item>
<item id="8">
<unitPrice>9.60</unitPrice>
<quantity>2</quantity>
<productName>Msa Australian Beef Steak Porterhouse</productName>
<productSKU>208988</productSKU>
</item>
<item id="9">
<unitPrice>15.20</unitPrice>
<quantity>3</quantity>
<productName>Roast Pork Shoulder Boneless Small</productName>
<productSKU>203420</productSKU>
</item>
<item id="10">
<unitPrice>10.80</unitPrice>
<quantity>2</quantity>
<productName>Select Corned Beef Silverside </productName>
<productSKU>148345</productSKU>
</item>
<item id="11">
<unitPrice>13.00</unitPrice>
<quantity>2</quantity>
<productName>Clairol Nice N Easy 114a Natural Lightest Golden Brown</productName>
<productSKU>226536</productSKU>
</item>
<purchaseTotals>
<currency>AUD</currency>
<grandTotalAmount>298.09</grandTotalAmount>
</purchaseTotals>
<merchantDefinedData>
<mddField id="19">Pickup</mddField>
<mddField id="3">Woolworths WOLLI CREEK, WOLLI CREEK</mddField>
<mddField id="1">2017-09-22 16:00</mddField>
<mddField id="2">NSW</mddField>
<mddField id="12">NO</mddField>
<mddField id="16">103</mddField>
<mddField id="23"></mddField>
<mddField id="20">WEB</mddField>
<mddField id="58"></mddField>
<mddField id="60">298.09</mddField>
</merchantDefinedData>
<afsService run="true" />
<deviceFingerprintID>18S###-26I#####</deviceFingerprintID>
</RequestMessage>
Example of the fraud payload passed as part of a payment:
{
"data": {
"transactionType": {
"creditCard": "PREAUTH",
"giftCard": "PURCHASE",
"payPal": "PURCHASE",
"googlePay": {
"creditCard": "PREAUTH",
"debitCard": "PURCHASE"
},
"applePay": {
"creditCard": "PREAUTH",
"debitCard": "PURCHASE"
}
},
"clientReference": "UNIQUE_CLIENT_REFERENCE",
"orderNumber": "UNIQUE_ORDER_NO",
"payments": [
{
"paymentInstrumentId": "213553",
"amount": 10.5
},
{
"paymentInstrumentId": "215319",
"amount": 6.5
}
]
},
"meta": {
"fraud": {
"provider": "cybersource",
"version": "CyberSourceTransaction_1.101",
"format": "XML",
"responseFormat": "XML",
"message": "<?xml version=\"1.0\" encoding=\"Windows-1252\"?>\r\n<RequestMessage xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\r\n <merchantID>TEST_MERCHANT_ID</merchantID>\r\n <merchantReferenceCode>1234-26IO8JUN</merchantReferenceCode>\r\n <billTo>\r\n <firstName>Jane</firstName>\r\n <lastName>Doe</lastName>\r\n <street1>407 ELIZABETH STREET</street1>\r\n <city>SURRY HILLS</city>\r\n <state>NSW</state>\r\n <postalCode>2199</postalCode>\r\n <country>AU</country>\r\n <phoneNumber>0400000000</phoneNumber>\r\n <email>[email protected]</email>\r\n <ipAddress>202.39.111.236</ipAddress>\r\n <dateOfBirth>1987-02-14</dateOfBirth>\r\n <customerID>3732442</customerID>\r\n </billTo>\r\n <shipTo>\r\n <firstName>Jane</firstName>\r\n <lastName>Doe</lastName>\r\n <phoneNumber>0400000000</phoneNumber>\r\n <email>[email protected]</email>\r\n </shipTo>\r\n <item id=\"0\">\r\n <unitPrice>7.59</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Mccain Protein Plus Frozen Meal Satay Chicken</productName>\r\n <productSKU>483660</productSKU>\r\n </item>\r\n <item id=\"1\">\r\n <unitPrice>2.00</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Habee Savers Needles Household Repair</productName>\r\n <productSKU>159489</productSKU>\r\n </item>\r\n <item id=\"2\">\r\n <unitPrice>6.60</unitPrice>\r\n <quantity>5</quantity>\r\n <productName>Chicken Breast Fillet Skinless Small</productName>\r\n <productSKU>118963</productSKU>\r\n </item>\r\n <item id=\"3\">\r\n <unitPrice>5.43</unitPrice>\r\n <quantity>5</quantity>\r\n <productName>Chicken Drumsticks </productName>\r\n <productSKU>169014</productSKU>\r\n </item>\r\n <item id=\"4\">\r\n <unitPrice>3.50</unitPrice>\r\n <quantity>4</quantity>\r\n <productName>Chicken Thigh Cutlets Skinless</productName>\r\n <productSKU>166830</productSKU>\r\n </item>\r\n <item id=\"5\">\r\n <unitPrice>10.80</unitPrice>\r\n <quantity>4</quantity>\r\n <productName>Lamb Diced Heart Smart</productName>\r\n <productSKU>208970</productSKU>\r\n </item>\r\n <item id=\"6\">\r\n <unitPrice>4.94</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Macro Chicken Lovely Legs Free Range</productName>\r\n <productSKU>700257</productSKU>\r\n </item>\r\n <item id=\"7\">\r\n <unitPrice>19.64</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Macro Organic Whole Chicken</productName>\r\n <productSKU>229320</productSKU>\r\n </item>\r\n <item id=\"8\">\r\n <unitPrice>9.60</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Msa Australian Beef Steak Porterhouse</productName>\r\n <productSKU>208988</productSKU>\r\n </item>\r\n <item id=\"9\">\r\n <unitPrice>15.20</unitPrice>\r\n <quantity>3</quantity>\r\n <productName>Roast Pork Shoulder Boneless Small</productName>\r\n <productSKU>203420</productSKU>\r\n </item>\r\n <item id=\"10\">\r\n <unitPrice>10.80</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Select Corned Beef Silverside </productName>\r\n <productSKU>148345</productSKU>\r\n </item>\r\n <item id=\"11\">\r\n <unitPrice>13.00</unitPrice>\r\n <quantity>2</quantity>\r\n <productName>Clairol Nice N Easy 114a Natural Lightest Golden Brown</productName>\r\n <productSKU>226536</productSKU>\r\n </item>\r\n <purchaseTotals>\r\n <currency>AUD</currency>\r\n <grandTotalAmount>298.09</grandTotalAmount>\r\n </purchaseTotals>\r\n <merchantDefinedData>\r\n <mddField id=\"19\">Pickup</mddField>\r\n <mddField id=\"10\">NO</mddField>\r\n <mddField id=\"3\">Woolworths WOLLI CREEK, WOLLI CREEK</mddField>\r\n <mddField id=\"1\">2017-09-22 16:00</mddField>\r\n <mddField id=\"2\">NSW</mddField>\r\n <mddField id=\"12\">NO</mddField>\r\n <mddField id=\"16\">103</mddField>\r\n <mddField id=\"23\"></mddField>\r\n <mddField id=\"17\">2017-09-18 12:40</mddField>\r\n <mddField id=\"18\">2017-09-18 12:40</mddField>\r\n <mddField id=\"25\">2017-09-22 16:00</mddField>\r\n <mddField id=\"20\">WEB</mddField>\r\n <mddField id=\"57\">Normal</mddField>\r\n <mddField id=\"58\"></mddField>\r\n <mddField id=\"59\" />\r\n <mddField id=\"60\">298.09</mddField>\r\n </merchantDefinedData>\r\n <afsService run=\"true\" />\r\n <deviceFingerprintID>18S###-26IO####</deviceFingerprintID>\r\n</RequestMessage>"
},
"challengeResponses": [
{
"instrumentId": "213553",
"type": "STEP_UP",
"token": "55bda344-c0ec-####-####-############"
}
]
}
}
Example of the fraud payload passed as part of a payment:
Where:
format
is the input format of themessage
being passed in. This can be XML or ZIP_BASE_64_ENCODED.responseFormat
is the output format in which you will receive the fraud response. This can be XML or ZIP_BASE_64_ENCODED.message
is the fraud payload provided in a single field in the specified format.
Updated about 1 year ago