Menu

Note: This API is for preview purposes only and is subject to change.

Device Data Collection

API v1
Last updated December 2022

Access Exemptions uses Threatmetrix to gather customer device data. This is combined with the order and transaction details to form the assessment as to whether an exemption is provided or not.

Threatmetrix JS

Add the Threatmetrix JavaScript to the HEAD section of the page you want the device data collection to happen.

Give a unique name to both the JS file, e.g. asdfghjkl.js, and the function threatmetrix.profile, e.g. awddc.prfl, to avoid blockers.

<script type="text/javascript" src="path/to/asdfghjkl.js"></script>

Details Required

To call the device data function you need the following details:

  • organisation id - For Try: afevfjm6 / For Production: dzppsd1h
  • profiling domain - For Try: ddc-test.worldpay.com / For production: ddc.worldpay.com
  • sessionId - you must generate a unique value for the page view to represent that specific device data collection. We recommend a UUID.

Example sessionId generation

You must submit the sessionId in theassessmentrequest in order for the device data to be applied as part of the risk assessment. Generating this in the backend as part of the page generation is recommended. Alternatively, you can generate it via JS and then submit it, so it's available in the backend.

A valid sessionId is between 30 and 128 characters long and consists of only upper or lowercase English letters (a-z, A-Z), digits (0-9), hyphens (-) or underscores (_). To make an incorrect match unlikely we highly recommend a UUID.

Copied!
function create_uuid() {
  return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {
   var r = Math.random() * 16 | 0,
     v = c == 'x' ? r : (r & 0x3 | 0x8);
    return v.toString(16);
 });

Threatmetrix call example

Copied!
...
var sessionid = create_uuid(); // function to create UUID
awddc.prfl ("PROFILING_DOMAIN", "ORGANISATION_ID", sessionid); // call Threatmetrix
...

Linking the device data with the assessment

When sending theExemptions assessmentrequest include the sessionId in deviceData.collectionReference

Next steps


Assessment