UIHow-to guidesTransform data

Manage User-defined Functions

Overivew

This guide shows how to create and use User-defined Functions in Sift to simplify and centralize logic across Rules and Calculated Channels. It covers practical actions like defining a function using CEL, referencing it in expressions, managing versions, and updating shared logic safely. Use this guide when you want to reduce duplication, improve expression clarity, and maintain consistent telemetry calculations across your workspace.

Instructions

Create a User-defined Function

To create a User-defined Function:

  1. In Sift, click .
  2. In the Sift navigation menu, click User-defined Functions.
  3. Click + New Function.
  4. In the User-defined function name box, enter a name for the User-defined Function.

    When creating a User-defined Function, follow the following naming requirements:

    • No spaces
    • The name must be 1 to 253 characters long
    • Must start with a letter
    • Use only letters, numbers, and underscores
  5. Optional: In the Description box, enter a description for the User-defined Function.
  6. In the Number list (inside the Inout Channels box), select an input data type for the first input Channel ($1).
    • To add other input Channels, consider the following steps:
    1. Inside the Input Channels box, click Plus.
    2. In the new Number list. Select an input data type for the second input Channel ($2).
  7. In the Enter an expression box, define the expression for the User-defined Function using the previously created (defined) input Channels.
  8. Click Save.

Preview a User-defined Function

To preview a User-defined Function:

  1. In Sift, click .
  2. In the Sift navigation menu, click User-defined Functions.
  3. In the User-defined Functions table, click the user-defined function you want to preview.
  4. In the Preview box, click click Plus.
  5. In the Runs table, select a Run to preview the User-defined Function.
  6. Click Next.
  7. In the Select Channels tab, select the Channels from the selected Run to associate with the created input Channels.
  8. Click Preview.

Edit a User-defined Function

To edit a User-defined Function:

  1. In Sift, click .
  2. In the Sift navigation menu, click User-defined Functions.
  3. In the User-defined Functions table, click the User-defined Function you want to edit.
  4. Click Edit.
  5. Edit and preview your changes.
  6. Click Save changes.

    Making and saving changes to a User-defined Function creates a new version of that User-defined Function. However, there are some important limitations to be aware of when editing:

    • Name: The User-defined Function name can only be edited if it has not yet been referenced by anything else.
    • Input Channels: The Input Channels can be modified as long as they are not currently being referenced elsewhere.

Archive a User-defined Function

To archive a User-defined Function:

  1. In Sift, click .
  2. In the Sift navigation menu, click User-defined Functions.
  3. In the User-defined Functions table, click the user-defined function you want to archive.
  4. Click More options.
  5. Select Archive.
  6. Click Archive Function.

Unarchive a User-defined Function

To unarchive a User-defined Function:

  1. In Sift, click .
  2. In the Sift navigation menu, click User-defined Functions.
  3. Click Show Archived.
  4. In the User-defined Functions table, click the user-defined function you want to unarchive.
  5. Click More options.
  6. Select Restore.

On this page