You may have noticed that assigning a field type to a field in your Blueprint does not natively assign data type based validations. For example, you can create a field with a type of number
, and still type words in that field without the field producing an error.
This is an intentional design choice in the Blueprint - to ensure that any validations associated with the field type match your business rules, Flatfile does not transform or validate data out of the box according to its field type. We do provide a plugin that can be deployed and used to assign some basic validations, like ensuring that only numbers are entered in a number field.
Our AutoCast plugin is located in our Plugins library, and can be installed and used to convert the data in a field to match its type. This plugin is also open-source, so if there are additional transformations necessary for your fields that are not covered in this plugin, it can be cloned and modified for your own purposes.