solidusio / solidus_braintree

💳 Integrate Solidus with Braintree
https://www.braintreepayments.com/
BSD 3-Clause "New" or "Revised" License
19 stars 55 forks source link

Check if the SolidusBraintree PayPal checkout option is tracking the device data #120

Closed gsmendoza closed 1 year ago

gsmendoza commented 1 year ago

Goal

We want to ensure that the other SolidusBraintree payment options are tracking the device data so that the feature would be consistent across all SolidusBraintree payment options.

Requirement

Given we have Premium Fraud Tools enabled on our Braintree account And there is a user checking out an item When the user checks out the item using PayPal Checkout with Vault Then SolidusBraintree should collect the user's device data and send it to Braintree And Braintree should confirm that the device data has been captured, that is, it should include a risk data section in its transaction response, like this:

[Braintree]   <risk-data>
[Braintree]     <id>ka4fb2kz</id>
[Braintree]     <decision>Approve</decision>
[Braintree]     <fraud-service-provider>fraud_protection_advanced</fraud-service-provider>
[Braintree]     <device-data-captured type="boolean">true</device-data-captured>
[Braintree]     <liability-shift nil="true"/>
[Braintree]     <decision-reasons type="array"/>
[Braintree]     <transaction-risk-score>341</transaction-risk-score>
[Braintree]   </risk-data>

Background

We added device data collection in https://github.com/solidusio/solidus_braintree/pull/116 but it seems we only implemented it for the hosted form.

PayPal documentation