Relay Data to EVM Chains

Relay oracle data, validator set, and bridge information updates back and forth between tellor and any EVM chain.

The relayer queries tellor for oracle data and their proofs and submits them to a user contract on other chains.

Setup

  1. Clone the repo:

git clone https://github.com/tellor-io/py-relayer.git
  1. Navigate to the repository directory:

cd py-relayer
  1. Create a virtual environment:

python3 -m venv venv
source venv/bin/activate
  1. Install the dependencies:

pip install -r requirements.txt
  1. Install the package:

pip install -e .
  1. Copy the .env.example file to .env and set the appropriate environment variables:

cp .env.example .env

The "email" section of the .env file is optional. If you want to receive emails when layer is down, input your gmail username and password. We recommend using an app password for your gmail account.

Other than the email section, all .env variables can alternatively be set through the CLI. We recommend setting your ethereum private key in the .env file for security reasons. For convenience, you should set any parameters which tend to remain constant across runs in the .env file. CLI arguments will override .env variables.

Additional Requirements for Ubuntu

If you are running the relayer on ubuntu, you may need to install additional tools:

After installing these dependencies, proceed with the setup instructions above.

Usage

The relayer provides several commands through its CLI:

Start Relaying

Update Oracle Data Once

Relay Token Bridge Withdraw

Initialize Data Bridge

This command initializes the TellorDataBridge contract after deployment. This must be run by the contract deployer address.

Reset Data Bridge

This command resets the validator set in the TellorDataBridge contract in the event that the last relayed validator set is over 21 days old. This can only be run by the TellorDataBridge contract’s guardian address.

To see all available options for each command:

Last updated