visit
Vested Interest Disclosure: The author is an independent contributor and has a vested interest in the company/ies mentioned in this story through direct compensation, media partnerships, or networking. HackerNoon has reviewed the story for quality, but the claims hereon belong to the author. #DYOR
It’s easy to forget how, not too long ago, web3 tooling felt like a time-intensive, debug-crazy endeavor. As the community grows, new solutions arise to solve the problems devs face when developing on blockchain. One such problem is the lack of auto-execute methods calls by smart contracts.
The awareness of automation has been increasing since 2015, with the first attempt being the Ethereum Alarm Clock project. However, it was the Defi explosion that made clear the imperative need to simplify the adoption of smart-contract automation.
A more in-depth explanation of the smart-contract automation genesis can be found at blog by David Liebowitz. David presents the three main solutions:
Gelato Ops by Gelato Network (production ready in July 2020)
Keep3r Network (since October 2020)
Keepers by Chainlink (open beta June 2021)
Autotasks & Relayers, Defender by Open Zeppelin
Disclaimer: Although this analysis was commissioned by Gelato, all research was conducted independently and the conclusions are my own.
1) Resources: docs are your best friend- this includes everything from good online documentation to tutorials, and even covers responsiveness in Discord channels or other forums when you have technical questions or are simply looking for guidance.
2) Build & Test- for this experience to be optimal there are a few things to consider, such as:
3) Features- the main question to consider here is not only whether the solution is providing the automation you need for your project (sometimes devs think that is finished when it is coded), but also other aspects that may influence scalability and user adoption when moving to production:
One crucial aspect of the features is the solution’s ability to provide the executors/keepers in a decentralized manner. Though this isn’t relevant for the job itself, it can impact scalability when moving to production (after all, decentralization is sacred in web3)
4) Dashboard & UI:
a) Maintenance Task Examples: Increase counter, a classic hello world smart contract automation example, increasing a counter when a specific time has elapsed (or condition is met).
b) On the Fly: One shot and cancel, dynamically create and cancel the task. As the ecosystem grows, I imagine we’ll see an explosion of different use cases where we’re required to control our tasks programmatically. We will implement this use case only in Gelato and Chainlink Upkeep.
First, users complete registration through the . The UI is pretty intuitive and asks for the contract address and the function you want to automate, in case the contract is not verified, you will have to provide the abi.
Gelato offers the ability to (if needed) split the execution logic from the condition logic. This is done by creating a resolver contract, which comes in handy for automating tasks of already deployed contracts with custom logic.
One very powerful Gelato feature is the ability to have, programmatically, full control over the tasks, which gives users the ability to create/cancel tasks within a smart contract. Gelato Network provides decentralized execution through a whitelisted set of Node Operators and plans to have achieved full permissionless decentralization by mid-2023
For the time being Gelato Network doesn’t add any fee to the transaction cost. Gelato offers the possibility to deposit funds (like ChainLink or OZ Defender) but also the ability to pay independently for each transaction.
Gelato ensures privacy by submitting transactions through flashbots enabling front-running protection. It also provides users with a very simple interface to set up a Discord or Telegram notification bot for when users are running into low balance.
Gelato provides an intuitive UI dashboard for registering and controlling the execution of the tasks. You can find jobs by the connected wallet or “on the fly tasks” by searching the input contract address. The UI also provides the transaction logging to understand when a transaction reverts.
At a first glance, Keep3r appears to be similar to Chainlink UpKeep or Gelato. The first step is to, register your job in the , and then implement a specific interface in the contract defining the conditions and providing the execution logic
However, the similarities end here:
Although the developer experience is really tough, with almost no detailed docs/tutorials on how to implement a job, within the forum and discord, the Defi Wonderland Team provides excellent support (user wei3erhase supported my tests).
This solution is focused on maintenance/pre-programmed tasks. For very dynamic scenarios (although feasible) I don’t believe that the implementation of this solution is fit for purpose as the infrastructure of keep3r requires off-line manipulation.
Guided tutorials and “easy to find” test addresses would be beneficial.The key feature of the Keep3r network is the implementation of the payment option by the yield accrued into a pool. This allows users to provide liquidity one time and doesn’t require any funds in the future.
Keep3r is a pure decentralized network and encourages every user to join. Though it may appear complicated at first, in the frame of this post, I’ve been able to understand the structure and how it works, and have simulated a task execution with the CLI (I could join the network as a Keeper)
Keep3r ensures privacy by submitting transactions through flashbots enabling front-running protection.
Keep3r Network could increase user adoption by improving the Ux experience with more documentation targeted to “no pro” developers.
First, users will need to register an “Upkeep” (task/job) within the Chainlink Keepers Network in the , and then connect their wallet.
We can define the time interval to trigger the Upkeep or specific custom logic with a condition, for this later case we are required to inherit the KeeperCompatible interface into our contract (it’s a very simple interface with two functions and the required addresses). Within the UI we will need the contract address and if it isn’t verified we will be prompted to input the method’s abi.
The fees on mainnet amount to 20%. As in other applications within Chainlink, you will need LINK to operate. More flexible payment methods would be beneficial.
Both testnets and faucets are available. If you want to develop locally with a forked network, although this is feasible (you will have to deploy it locally using a Chainlink node), it can be cumbersome if you haven’t done it before.
Chainlink Keepers have started to provide the ability to control the tasks programmatically. So far the functionality only allows users to create a task within a smart contract with specific custom logic. If a use case requires a time interval or only one run of the job, users will have to code it within the condition or execution logic. As developments occur very quickly in web3, I will have to review this post in the coming weeks to update the available features.
On the other hand, this architecture allows the offsetting of some gas-intensive calculations off-chain and only passing within the performData the required data for the performUpKeep() execution.
Chainlink provides a very intuitive dashboard UI for registering/controlling the execution of the tasks.
The dashboard shows the UpKeeps registered by the connected wallet. Moving forward it will help devs to implement a search functionality by contract address for “on the fly” created tasks.
ChainLink summary Official feedback from Chainlink is still pending, therefore my comments and analysis may change in the future.
Users need to register a relayer in charge of the execution and an autotask. Within the autotask, define the conditions under which the task has to be triggered (by time or webhook) and any custom logic needed to define the execution.
One very interesting feature proposed by Open Zeppelin is the ability to trigger the autotask by a webhook, which fits very nicely with the sentinel ability to be notified when events on-chain happen.
Open Zeppelin does not allow “out of the box” to create and cancel a task on the fly from a smart contract. The minimum time between two triggers is one minute, a smaller interval can be achieved by a never-ending loop.
Open Zeppelin summary Official feedback from Open Zeppelin is still pending, therefore comments and punctuations may change in the future.
Averaging the different punctuations we could create the following representation:
After my personal experience testing the four solutions, the above picture accurately represents my view of Gelato Network being one step ahead in UX.
Increase counter:
Gelato:
Keep3r Network:
Chainlink Keepers: Mumbai
Open Zeppelin Defender:
Create and cancel task:
Gelato:
Chainlink Keepers:
Github repo: