Need some text to be lowercased, capitalized, or anything similar to this? The transform text step has you covered.
After reading this article you'll learn how to:
-
Install the Transform text step from the Block Store
-
Configure the Transform text step
-
Use the Transform text step in practice
Starting off
Transform text step is created by Betty Blocks, but it's not readily available in the standard set of steps within the action builder. But that doesn't matter, you can find it and install it from the Block Store. To do this navigate to the Block Store and search for 'transform' it will pop up as the first hit.
Click on View details
to check out what the block is about. In our case, the step will make a text value downcased, upcased, capitalized, or parameterized. This tab also lets you install the block into one of your applications. Simply hit the Install block
button and select your organization followed by your application.
After installing the 'Transform text' step, it can be found in your action builder of the application that was selected. You'll find it in the newly created text section of the action steps.
Configuring the step
Working with the Transform text step is rather straightforward but the step can be applied to a variety of use cases. Let's start off by just seeing how the step works in practice. Create a new action called something like 'Transform text' and create an input variable called 'email_address'.
After creating this variable drag the transform text step in the action flow. For this quick use case, we'll transform the text to be lowercase (or downcase). This is how the step is configured to achieve this:
The 'email_address' input variable is the text value we're changing, the style is going to be downcased, and the result is passed into the Finish step so that we can check it out in the playground.
If we'd now test the action in the playground by clicking the Test run
button in the top right corner. Copy the mutation code and open the playground.
As you can see when we type an email address full of capital letters, our action changes it to lowercase. This logic can also be inverted, if you want for example, only capitals - you can do this as well by changing the transformation style.
This step can be applied in a lot of various use cases but the key takeaway as to why you'd want to use this step is to ensure that your data is consistent throughout your entire application.