Simplifying Data Transformations with the Expanded Handlebars Helpers Library

What It Is :

 

This article explains how Celigo has enhanced its mapping and transformation capabilities by introducing an expanded library of built-in Handlebars helpers. These new helpers give you stronger and easier ways to format, manipulate, validate, and transform data directly inside mappings—reducing the need for custom scripts.

 

 

Need to Use :

 

Use this when your integration flow requires transformations such as:

Converting or cleaning text (e.g., trimming, changing case, removing protocols)

Manipulating arrays and checking conditions (e.g., checking existence in array, filtering)

Formatting numbers or bytes, reading types, or sanitizing input

If you were previously writing custom JavaScript or external code for such transformation logic, these new helpers enable you to keep the logic inside the mapping environment in Celigo.

 

 

Key Benefits :

 

Reduced need for scripting: Many common transformation tasks (text/array/logic) are now available as built-in helpers so you can avoid writing custom code.

Cleaner, more readable mappings: With more helpers, your mapping expressions are shorter, clearer and more maintainable.

Faster development & fewer errors: Using predefined helpers reduces copy-paste or custom script mistakes and improves the speed of building transformations.

Better maintainability and reuse: Since logic is declarative inside the mapper, future changes are easier, and handoffs between developers/business users are smoother.

 

 

Steps Involved

 

1. Open your flow in Celigo and navigate to the Mapping / Transformation step.

 

2. In the value field where you map source to destination, choose to use a Handlebars expression (look for the {{ }} icon or option).

 

3. Choose from the new built-in helpers. For example:

 

{{trimLeft source.field}}

{{camelcase source.productName}}

{{#inArray “Premium,Standard” order.type}}HighVolume{{else}}Normal{{/inArray}}

 

4. Use the Preview or Test Data feature to validate the output of your transformation before activating the flow.

 

5. Save and deploy the flow. Monitor for expected results during initial runs.

 

6. For reuse: document the helper usage in your team’s mapping guidelines so that other flows adopt the same pattern.

 

Leave a comment

Your email address will not be published. Required fields are marked *