See Full Name for more information about this algorithm framework.
Creating a full name algorithm via API
-
Find the FrameworkId for the Extensible SL Framework. That might be done via the following EndPoint:
algorithm GET /algorithm/frameworksPlugin name is dlpx-core, the framework name is Full Name.
-
Involved algorithm references might be built using the name of the desired existing extensible String-type algorithm. For example: "firstNameAlgorithmRef" : { "name" : "dlpx-core:FirstName" }
-
Create an Extensible Name Algorithm via the following EndPoint:
algorithm POST /algorithmsUsing the JSON formatted input, similar to the following example:
{ "algorithmName": demo-FullName", "algorithmType": "COMPONENT", "description": "This is a new style FullName algorithm", "frameworkId" : 3, "algorithmExtension" : { "firstNameAlgorithmRef" : { "name" : "dlpx-core:FirstName" }, "lastNameAlgorithmRef" : { "name" : "dlpx-core:LastName" }, "maxLengthOfMaskedName" : 0, "ifSingleWordConsiderAsLastName" : true, “lastNameAtTheEnd” : true, "lastNameSeparators" : [ "," ], "maxNumberFirstNames" : 2 } }
Fields description:
"algorithmName" - customer created algorithm name
"algorithmType" - should be "COMPONENT" for Extensible Algorithms
"description" - free text
"frameworkId" - the numeric value found in #1 above
"algorithmExtension" - the composite field, containing algorithm instance specific configuration parameters
Name algorithm extension
-
firstNameAlgorithmRef(required)
AlgorithmReferenceId Must be an Algorithm Reference, pointing to an existing extensible algorithm of String type.
-
lastNameAlgorithmRef(required)
AlgorithmReferenceId Must be an Algorithm Reference, pointing to an existing extensible algorithm of String type.
-
maxLengthOfMaskedName(optional, default=0)
Integer Should be a non-negative number. The output (masked) value is forcibly trimmed to that length (by the number of characters).
-
ifSingleWordConsiderAsLastName(optional)
Boolean If true consider single input word as a last name, otherwise as a first name. Default: true
-
lastNameAtTheEnd(optional)
Boolean If true last name to be detected at the end of the input staring, otherwise last name is at the beginning. Default: true
-
lastNameSeparators(optional)
List [Char] List of the last name separators. Default: contains single value: comma ','
-
maxNumberFirstNames(optional, default=2, minimum=1, maximum=4)
Integer Defines the max number of first and middle names to be masked. The rest would be ignored.