When using the Recurly.js React library with Kount Fraud Management, device data may fail to appear on test or live transactions if the RiskDataCollector component is not implemented correctly.
This article explains the most common cause of missing Kount device data when using React and provides the correct implementation pattern.
Key takeaway: The
RiskDataCollector component must be placed inside the same HTML <form> element used to submit payment data.Common Symptoms
- Kount dashboard shows transactions with no device fingerprint data
- Recurly transactions indicate device data was not captured
- Fraud rules relying on device data do not trigger as expected
- Issue occurs only when using React (non-React Recurly.js works)
Root Cause
The RiskDataCollector component relies on being able to attach to the nearest ancestor HTMLFormElement.
If the component is rendered outside of the payment form, device data collection will silently fail and no data will be sent to Kount.
Important: Rendering
RiskDataCollector at a higher component level (for example, outside the checkout form) will prevent device data collection.Correct Implementation
Ensure that the RiskDataCollector component is rendered inside the same <form> element that submits payment details.
<form
ref={formRef}
onSubmit={handlePurchaseSubmit}
>
<RiskDataCollector
strategy="kount"
onError={handleError}
/>
<CardElement />
</form>
Support tip: The
strategy prop must match the fraud provider configured on your Recurly site (for example, kount).How to Verify
- Submit a test transaction using the updated implementation.
- Open the transaction in the Recurly Admin UI.
- Confirm device data is present on the transaction record.
- Check the Kount dashboard to ensure the device fingerprint is visible.
Additional Notes
- This requirement applies specifically to the React wrapper for Recurly.js.
- Standard (non-React) Recurly.js implementations are not affected.
- This behavior applies in both sandbox and production environments.
Comments
0 comments
Please sign in to leave a comment.