Working with Workflows
The essentials of building workflows and working with Ensemble
Ensemble Workflows
Ensemble workflows serve as a primitive element for automating on-chain processes across diverse blockchain networks. These workflows are composed of a series of sequential steps and triggers, enabling developers to create powerful automation solutions that can be customized by users to suit specific use cases. By facilitating the automation of decentralized operations, from DeFi transactions to automated trading strategies, Ensemble workflows offer the flexibility and scalability needed for various blockchain applications.
Ensemble Roles
Workflow Builders - Create new workflows, build new modules, and assist in workflow integration in customer applications. Need to be tech or crypto-savy. Receive builder fee
Node Operators - Operate and assist in the the workflows execution. Run the Ensemble engine that performs the workflow execution. Need to be tech and devops-savy. Receive operation fee.
Workflow User - Consume and request new workflows. Consumer can be businesses and pro-users that use Ensemble directly, or end-users that use Ensemble via third party integrations.
How it works
Working with Ensemble workflows involves three main stages: Build, Configure, and Execute, each typically handled by a different role.
Build – Developers create the automated workflow by defining steps and triggers in a workflow.yaml file.
Configure – Users customize workflow parameters that influence scheduling and execution logic to suit their specific needs.
Execute – Node operators execute the workflows by running the Ensemble Engine, while users monitor and control the workflow through an admin interface or API.
Build: Creating the Workflow
In the Build stage, developers create workflows by defining them in a workflow.yaml file. This file outlines the workflow steps, triggers, and parameters that the user will later provide, making the workflow adaptable to various use cases. Each workflow consists of a sequence of steps with conditional logic, enabling interactions with smart contracts across multiple blockchains and wallet types (EOAs and Smart Wallets). Additional workflow functionality can be extended via custom modules, allowing for more advanced use cases. The versatility of workflows enables them to be reused and configured by different users, streamlining the development process for various on-chain operations.
Configure: Customizing the Workflow
After the workflow is assembled and uploaded, users configure it to suit their specific needs by setting parameters that influence execution and scheduling logic. Example parameters include wallet and contract addresses, network names, and other settings that tailor the workflow to the user's requirements. Once the workflow is configured, the engine evaluates any necessary permissions or prerequisites, such as wallet permissions or token approvals.. After these prerequisites are fulfilled the workflow can be executed, automating the intended on-chain operations.
Workflow Execution
In the Execution stage, the node operator receives permission to execute the workflow. The node operator runs the Ensemble engine node, which reads the workflow and processes it through its internal execution pipeline. During this phase, users maintain full control over the workflow, with the ability to monitor performance and statistics via the admin interface or programmatically with the API/CLI. Users can stop, start, or reconfigure the workflow as needed, ensuring flexibility and oversight throughout the workflow’s lifecycle.
Last updated