Date replacement
See Date Replacement for more information about this algorithm framework.
Creating a date replacement algorithm via API
Retrieve the frameworkIdfor the Date Replacement Framework. This information can be retrieved using the following endpoint:
CODEalgorithm GET /algorithm/frameworks
The framework information should look similar to the following:
CODE{ "frameworkId": 1, "frameworkName": "Date Replacement", "frameworkType" : "LOCAL_DATE_TIME", "plugin" : { "pluginId" : 7, "pluginName" : "dlpx-core" } }
Create a Date Replacement algorithm via the following endpoint:
CODEalgorithm POST /algorithms
Configure a new algorithm using the JSON formatted input similar to the following:
CODE{ "algorithmName": "exampleDateReplacementAlgorithm", "algorithmType": "COMPONENT", "frameworkId" : 1, "algorithmExtension" : { "minDate": "2020-01-01 00:00:00", "maxDate": "2021-01-01 00:00:00", "unit": "DAYS" } }
Date replacement algorithm extension
minDate
String A date representing the minimum value that an input can be masked to. The range is inclusive of this value.
maxDate
String A date representing the maximum value that an input can be masked to. The range is inclusive of this value.
unit(default="SECONDS")
String A unit of time that determines what the output is truncated to. For example, when the unit is set to days, the years, months, and days may change, but the hours, minutes, and seconds will always be 00:00:00. Unit options supported by this framework: days, hours, minutes, and seconds.