Fingerprint is a device intelligence platform offering 99.5% accurate visitor identification. Fingerprint Pro React SDK is an easy way to integrate Fingerprint Pro into your React application. It's also compatible with Next.js and Preact. See application demos in the examples folder.
See our Use cases page for open-source real-world examples of using Fingerprint to detect fraud and streamline user experiences.
Linking and tagging information
The visitorId provided by Fingerprint Identification is especially useful when combined with information you already know about your users, for example, account IDs, order IDs, etc. To learn more about various applications of the linkedId and tag, see Linking and tagging information.
Associate the visitor ID with your data using the linkedId or tag parameter of the options object passed into the useVisitorData() hook or the getData function:
Fingerprint Pro usage is billed per API call. To avoid unnecessary API calls, it is a good practice to cache identification results. By default, the SDK uses sessionStorage to cache results.
Specify the cacheLocation prop on <FpjsProvider> to instead store results in memory or localStorage. Use none to disable caching completely.
Specify the cache prop on <FpjsProvider> to use your custom cache implementation instead. For more details, see Creating a custom cache
in the Fingerprint Pro SPA repository (a lower-level Fingerprint library used by this SDK).
Pass {ignoreCache: true} to the getData() function to ignore cached results for that specific API call.
[!NOTE]
If you use data from extendedResult, pay additional attention to your caching strategy.
Some fields, for example, ip or lastSeenAt, might change over time for the same visitor. Use getData({ ignoreCache: true }) to fetch the latest identification results.
Error handling
The getData function throws errors directly from the JS Agent without changing them. See JS Agent error handling for more details.
To ask questions or provide feedback, use Issues. If you need private support, please email us at oss-support@fingerprint.com. If you'd like to have a similar React wrapper for the open-source FingerprintJS, consider creating an issue in the main FingerprintJS repository.
License
This project is licensed under the MIT license. See the LICENSE file for more info.