● Custom Code Nodes
Canvas allows you to create your own algorithms and advanced processes using Custom Code nodes.
Overview
In addition to the built-in nodes above, EverWorker supports Custom Code Nodes that appear as a separate section in the "Add Node" dropdown.
What are Custom Code Nodes?
Custom Code Nodes are user-created JavaScript/TypeScript functions that can be saved and reused across workflows. They appear in the dropdown under a "Custom Code Nodes" section.
Creating Custom Code Nodes
- Access Code Node Edtior from the menu in the left hand side.
- Write your custom JavaScript/TypeScript code
- Define input parameters your code expects
- Test and save your code node
- It will automatically appear in the "Add Node" dropdown
Using Custom Code Nodes
When you select a custom code node from the dropdown:
- The node uses methodId: "code_node" internally
- It automatically gets a codeNodeId parameter pointing to your saved code
- Additional parameters are generated based on your code node definition
- The display name shows your custom node name in green
Example Custom Code Node
A custom code node might look like:
// Custom code that processes user data
function processUserData(userData, apiKey) {
// Your custom logic here
return {
processedData: userData.map(user => ({
...user,
processed: true,
timestamp: new Date()
})),
count: userData.length
};
}
This would appear in the dropdown as a selectable node that you can add to your workflow.
Updated 10 days ago