Docs
Ecosystem Roles
Relayer
Private Transaction Relaying

Private Transaction Relaying

A Private Transaction Relayer aids users in submitting proofs for private transactions that occur within the Shielded Pools of the Webb Protocol.

In essence, users create zero-knowledge proof data - a kind of cryptographic proof where one can prove they know certain information without revealing that information itself. They then format this data into an appropriate payload.

The job of the Private Transaction Relayer is to take this payload and submit it to the network on behalf of the users. In this way, the relayer plays a critical role in ensuring the smooth execution of private transactions within the system.

Participate as a Private Transaction Relayer

The relayer node is highly configurable, allowing you to tailor its functions to suit your needs. If you prefer to support specific functions only, you can easily adjust your relayer's settings accordingly.

For example, you might decide to exclusively relay private transactions. In such a case, you would disable the governance relaying and data querying functions.

Please note that by default, all functions - including governance relaying, private transaction relaying, and data querying - are enabled. If you want to specialize your relayer, you will need to manually turn off the functions you don't wish to support.

--

Exclusively Private Transactions Relay Node

To set up your relayer node exclusively for relaying private transactions we need to add the following fields to under the [evm.<network>.contracts] section in our configuration file:

1. Add the Required Fields

  • contract: Name of the contract to support (e.g. "VAnchor", "SignatureBridge")
  • address: Address of the contract
  • size: Represents the minimum size configured for deposit / withdraw on the contract
  • events-watcher: Event watcher should be set to false for this strategy
  • withdraw-fee-percentage: Determines the fee taken by this relayer
  • withdraw-gaslimit: Specifies the maximum amount of gas that will be used when submitting a withdraw transaction

2. Under the [features] section in our configuration file, we need to turn off data-querying and governance-relaying.

  • data-query: Should be set to false for this strategy
  • governance-relay: Should be set to false for this strategy
  • private-relay: Should be set to true for this strategy (set to true by default)

3. Under the [evm-etherscan] section we need to provide EtherscanApiConfiguration.

Example

An example configuration file for the goerli network and VAnchor contract should look similar to this:

You will need to update the linked-anchors and contract addresses for the applicable chains.

config file
[[evm.goerli.contracts]]
contract = "VAnchor"
address = "0x03b88eD9Ff9bE84e4baD3F55D67AE5ABA610523C"
deployed-at = 6896976
size = 0.01
events-watcher = { enabled = false }
withdraw-config = { withdraw-fee-percentage = 0, withdraw-gaslimit = "0x350000" }
 
[features]
data-query = false
governance-relay = false
private-relay = true
 
[evm-etherscan.goerli]
chain-id = 1
api-key = "$ETHERSCAN_GOERLI_API_KEY"