After reading this article you’ll know how to:
Create a function block
Publish the function block
Release & install the block in your organization
Our platform expands its capabilities by presenting new features in the Next-gen applications, one of which is the possibility of adding your own custom blocks to the application and sharing them via the block store. This article in particular explains how to create your own action function and then share it with other customers and organizations.
Creating an action function
First of all, let’s go through the process of creating your own action function.
First off, preparations. I won't go in-depth into this but there's 1 preparation that has been made; it's a pre-created action function.
Check out this article if you want to learn more about this, but you likely already know how to do this when you're reading this article.
When in your custom functions project type the following code in your terminal:
A new folder called blocks gets created with a json file in it. Now, all we have to do is add the name of the function that we want to create a block of, plus add the version number. So in the block declaration, specify the name of the function:
Note: the best practice is to name your functions with dashes in them like: 'example-function'. When adding the name of your function + function number to your block write the name of your function in lowerCamelCase.
Now save the file.
Select the block you want to publish and hit enter, you should see that the block that we just created is getting published.
When we check out the block store and navigate to 'my blocks' and then 'dev blocks' we should see our block there
The next step is to release the block so it can be used.
Click on the block followed by the permissions button on the left. Select the permissions followed by which organizations are allowed to install this block, if that's the case.
Hit save when done.
Click on release to release your block!
When we check out our action builder we can use the block that we published!