Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 14 Next »

The Call function node is used for calling Python functions in your workflows. This page explains how you can build your own workflow utilities.

Built-in functions

There is a number of built-in functions for you to implement. They allow you to retrieve user-related data, such as a user name or email, retrieve dialog-related data, such as attachments, and much more.

To view the reference material on these functions, view the help page. It is available on your instance as https://<yourinstance>.konverso.ai/doc/Call-Function-reference_781418611.html. Just substitute <yourinstance> with the actual name of your host.

ITSM Jira Service Management

You can use Jira Service Management (Cloud) specific functions in your workflows. To view the list of such functions and their details, see the JSM utility workflow functions.

Custom utilities

You can build custom utilities for interacting with users, invoking requests on external systems, and returning results.

Creating and editing custom functions

Editable files allow you to modify code that can be used to leverage Koji functionalities. There is no access to source code of the software, but editable files help you modify some parts.

To view and modify editable files:

1. Go to Development.

2. In the Configuration section, click one of the Workflow utilities files.

3. Modify its content in the window and click Save.

Sample

Note that by default Workflow Utility files provide you with the tips on how to create functions.

What’s next?

Once you have created a function, you can use it with the help of the Call function node in workflows.

An example is described on the Web service node and APIs page:

  • The Call function node is used for obtaining the authorization details.

  • It uses the wf.itsm.ticket.get_authorization_header function, which returns Session Auth Token.

To use your custom function in a workflow:

1. Create the Call function node.

2. In the Function name field, specify the function. For example, if you have created a new function called check_status in my1 file, you must refer to it in the Call function node as wf.my1.check_status.

3. Save the result in a variable, so you can use it in other nodes later on. The variable is defined in the Keep result in variable field.

  • No labels