Submit Task

Core AVS logic consists of the atomic units of work called Tasks.

We will now run the operator node software and submit the first task in your example AVS, which fetches the price of ETH from Binance, verifies it, and posts the result on-chain.

Prerequisites

  1. Docker Engine installed, including docker-compose


1

Verify docker installation

Run:

docker compose version # Should output: Docker Compose version [...]
2

Verify environment variables setup

Make sure your .env file exists and includes all the variables as per the .env.example in the repo.

3

Build the docker setup

From the root of your example AVS directory, run:

docker compose build --no-cache

This command will build the operator node software, which consists of multiple services defined in the docker-compose.yml file.

4

Run Operator Nodes

Run the command to run the node software:

docker compose up
5

Execute Task

In a new terminal session, run the following command:

curl -X POST http://localhost:4003/task/execute

The above command will trigger task execution by the Performer Node and validation by all three Attester Nodes, and finally onchain submission by the Aggregator Node.

6

Verify Successful Execution and Submission

To find the transaction hash, check the Docker container logs or visit the AttestationCenter contract and look for submitTask transactions.

Look for the following logs emitted by the aggregator container:

Task with proofOfTask: <proofOfTask> has been approved and submitted, on chain 84532, tx: <txHash>

Success!

Next, explore how to extend AVS functionality beyond the basics.

Next Steps

  • Explore the Quickstart repository

  • Extend Execution and Validation service logic Implement your own business logic and use the AVS you just deployed as scaffolding.

  • Use the CLI Command Reference Refer to the CLI Command Reference for a complete list of commands.

Last updated