Functions in AI Pilots allow developers to build reusable, custom logic that extends an agent’s capabilities. From simple data transformations to complex third-party API integrations, functions enable smarter, more dynamic agent behavior.
- How to manage your Functions
- To configure a new Function
- To edit an existing Function
- Steps to Delete a Function
How to manage your Functions:
- Navigate to the More Icon from the left menu bar
- Click on the AI Pilots
- Select the AI Pilot from the drop-down.
- Move to the Functions.
You’ll see a list of functions (if any exist) with the following columns:
-
Function Name: Name of the function for the identification
-
Deployment Status: Indicates if the function is Ready to Use, Failed, or In Progress.
-
Hover over the error icon to view error details if the status is Failed.
-
-
Description: A summary of the function’s purpose.
-
Last Modified By: The user who last updated the function.
-
Last Modified Date: When the function was last modified.
How to configure a new Function
-
Click the New button.
-
The Function Editor opens, divided into:
-
Left Panel: Code editor
-
Right Panel: Configuration panel.
-
Configuration Panel Details
Function Details:
-
Function Name: Name of the function for identification.
-
Description: A summary of what the function does.
-
Thumbnail Image:
-
Supports .png, .jpeg, .jpg under 1 MB.
-
Appears in selection lists where this function is referenced.
-
Input Variables:
-
-
Variable Name: Used within the function code.
-
Description: Details about the expected input.
-
Click + Add to add multiple inputs.
-
Output Variables:
-
- Variable Name: Identifier variable for the output.
- Description: Details about the expected output.
-
Click + Add to define more outputs.
Paths:
-
-
Path Name: Logical route (e.g., Success, Failure).
-
Canvas Label: Label displayed in the flow builder.
-
Click + Add to define additional paths.
-
Writing Function Logic:
-
Use the left-side code editor to write your function using the supported language.
-
Choose from:
-
Primary runtime (first launch): Node.js 22
-
Supported by Monaco Editor (for syntax): JavaScript, Python, Go, PHP, HTML, CSS, Java, C++, etc.
-
Comments
0 comments
Article is closed for comments.