Workflows Overview
Workflows let you build automated processes that chain multiple API calls, add conditional logic, transform data, and handle errors - all through a visual drag-and-drop interface.What Are Workflows?
Workflows are automated sequences of actions that execute in response to triggers or manual invocation. Example workflow:Key Concepts
Nodes
Nodes are the building blocks of workflows. Each node performs a specific action:| Node Type | Purpose |
|---|---|
| Trigger | Starts the workflow (webhook, manual, schedule) |
| HTTP Request | Make API calls to external services |
| Code Block | Run custom JavaScript code |
| Condition | Branch based on if/else logic |
| Loop | Iterate over arrays |
| Router | Route to different paths based on conditions |
| Delay | Pause execution for a specified time |
| Error Handler | Catch and handle errors |
Edges
Edges connect nodes and define the flow of execution. Data passes from one node to the next through these connections.Variables
Workflows use a variable system to pass data between nodes:Node Types
Trigger Node
Every workflow starts with a trigger node that determines when the workflow runs: Trigger Types:- Manual: Run on-demand from the UI or API
- Webhook: Run when an HTTP request hits the workflow endpoint
- Route Event: Run when a KnoxCall route processes a request
HTTP Request Node
Make HTTP requests to external APIs: Configuration:Code Block Node
Run custom JavaScript for data transformation: Example:- Data transformation
- Calculations
- Formatting responses
- Complex conditional logic
Condition Node
Branch workflow execution based on conditions: Configuration:- True path: Executes when condition is true
- False path: Executes when condition is false
===,!==(equality)>,<,>=,<=(comparison)&&,||(logical)includes(),startsWith()(string methods)
Loop Node
Iterate over arrays: Configuration:Router Node
Route to different paths based on multiple conditions: Configuration:Delay Node
Pause execution for a specified duration: Configuration:Error Handler Node
Catch and handle errors from previous nodes: Configuration:Creating a Workflow
1. Navigate to Workflows
- Click Workflows in the sidebar
- Click + Create Workflow
2. Add a Trigger
Every workflow needs a trigger node:- The trigger node is added automatically
- Configure the trigger type (manual, webhook, etc.)
- Set any trigger-specific options
3. Add Nodes
- Click the + button on a node’s output
- Select the node type from the menu
- Configure the node settings
4. Connect Nodes
- Drag from one node’s output to another’s input
- Edges show the flow direction
- Some nodes (Condition, Router) have multiple outputs
5. Configure Variables
Use the variable picker to reference:- Trigger data
- Previous node outputs
- Environment variables
6. Save and Enable
- Click Save
- Toggle Enabled to ON
- Your workflow is now active
Executing Workflows
Manual Execution
- Open the workflow
- Click Run
- Optionally provide input data
- View execution progress in real-time
Webhook Execution
- Configure a webhook trigger
- Get the workflow URL
- Send HTTP requests to trigger the workflow
Via API
Execution Monitoring
Real-time Progress
When a workflow runs, you can watch execution in real-time:- Each node highlights when it starts
- Success/failure status shown per node
- Execution time displayed
- Output data visible
Execution History
View past executions:- Open the workflow
- Click the Executions tab
- See list of all executions with:
- Status (running, completed, failed, cancelled)
- Start time
- Duration
- Trigger type
Execution Details
Click on an execution to see:- Full execution timeline
- Each node’s input and output
- Error messages (if any)
- Duration per node
Error Handling
Automatic Retries
HTTP Request nodes can be configured to retry on failure:Error Handler Nodes
Catch errors and execute recovery logic:Workflow-level Error Handling
If no error handler catches an error:- Workflow status set to “failed”
- Error message logged
- Execution stops at the failing node
Common Use Cases
1. Payment Processing Pipeline
2. User Onboarding
3. Data Synchronization
4. Error Alerting
Workflow Versioning
Workflows automatically version when you save changes:- Each save creates a new version
- View version history
- Rollback to previous versions
- Open workflow
- Click Versions tab
- See all saved versions with timestamps
Best Practices
1. Start Simple
Begin with basic workflows and add complexity gradually:- Start with Trigger → HTTP Request
- Add Condition nodes as needed
- Use Error Handlers for critical paths
2. Use Descriptive Names
Name nodes clearly:- “Fetch Customer Data” not “HTTP Request 1”
- “Is Payment Valid?” not “Condition 1”
3. Handle Errors
Always add error handling for:- External API calls
- Critical business logic
- Data transformations
4. Test Thoroughly
Before enabling:- Run manually with test data
- Verify each node’s output
- Test error scenarios
5. Monitor Executions
Regularly check:- Execution history for failures
- Execution times for performance
- Error patterns
Next Steps
Creating Workflows
Step-by-step workflow creation guide
Webhooks
Get notified when workflows complete
Routes
Understand API routing basics
Monitoring
Track workflow performance
Statistics
- Level: intermediate
- Time: 10 minutes
Tags
workflows, automation, orchestration, visual-builder, no-code