With the implementation of the General Data Protection Law (LGPD) in Brazil, we recognized the need to assist our clients in enhancing the privacy protection of the data that Kondado integrates into their data destinations. For this purpose, functions were created.
The functions are processes applied to the data even before it is written to the destination. For example, you can choose to apply a function that transforms the text to uppercase. This way, a text like "hello, world!" would be converted to "HELLO, WORLD!".
Kondado's functions are granular, meaning they perform one operation at a time. As a result, you can chain them, allowing the functions to be applied sequentially.
Returning to the example of the field "hello, world!", you can use the function to transform the text to uppercase and then apply a function to remove spaces. This would result in the following flow:
In the source: "hello, world!"
First function (uppercase): "HELLO, WORLD!"
Second function (remove spaces between words): "HELLO,WORLD!"
In the destination: "HELLO,WORLD!"
In Kondado, functions are classified into three (3) categories:
1. **Transformation**: Applies a process to the field that still allows its identification in a simple way. Examples include functions to remove spaces or convert text to uppercase.
2. **Anonymization**: Applies a process to the field that has no relation to its original value. For instance, a function that replaces a value with a random UUID.
3. **Pseudonymization**: Applies a process to the field that retains some relationship with the original value. However, reversing the field to its original value would be computationally expensive or would require additional values. For example, you might need to know the record ID that was pseudonymized to look up its original value elsewhere or deduce the original value through multiple associations.
Some functions will change the original data type. For example, using a function that replaces a field with a random UUID will convert any data type into text.
Additionally, some functions are limited to certain data types. For instance, a function that extracts the year from a date can only be applied to fields of the type "timestamps" or "dates."
With function chaining, the data type for subsequent functions is always based on the type generated by the last applied function (or the original field type, in the case of the first function in the chain). For example, consider a field of type "date" in the source as "2020-09-10." You can apply a transformation function that changes the field type to "text," followed by a function that removes special characters (which is only applicable to "text" fields). This process will occur as follows:
---
1. Original Field:
- Type: Date
- Value: `2020-09-10`
2. First Function:
- Transformation: Convert the date to text.
- Type After Transformation: Text
- Value: `"2020-09-10"`
3. Second Function:
- Transformation: Remove special characters.
- Type After Transformation: Text
- Value: `"20200910"`
This chaining ensures that the data type is adjusted dynamically at each step to support the operations applied by subsequent functions.
Apply Data Functions in Kondado
Learn how to use Kondado's pre-destination functions to transform, anonymize, or pseudonymize your data before it reaches your destination.
Choose a function category
Identify whether your use case needs Transformation, Anonymization, or Pseudonymization. For LGPD compliance, anonymization and pseudonymization help protect sensitive data before it is written to your destination.
Check field data types
Verify the original data type of your source field. Some functions only work with specific types—such as date/timestamp functions—while others like UUID generation will convert any type to text. The output type of each function becomes the input type for the next step in the chain.
Build your function chain
Combine multiple granular functions sequentially. For example, convert a date to text, then remove special characters. Each step's output type dynamically determines what functions can follow, enabling flexible data transformation pipelines.
Validate the final output
Review the chained result before it reaches your destination. Ensure the final value and data type match your requirements—whether for reporting, compliance, or downstream analytics workflows.