User applications can modify cross-chain behavior by configuring certain values. These configuration values are established at the LayerZero endpoint of each chain. The user application's smart contract must initiate the transactions that alter these configuration values.
A User Application (UA) can use non-default protocol settings. To implement it, please refer to the following function as specified in the LayerZero documentation.
bytes calldata _config
The parameters for the
setConfigfunctions are as follows:
|Ultra Light Client version (
0 refers to the default version).
|The destination chain ID can be found in the Supported Chain IDs.
🚧 Important note: LayerZero uses different identifiers than those described in EIP-155.
See more in Config Types.
|The ABI encoded Oracle address.
See more in Blockdaemon Oracle Addresses.
If your user application extends
NonBlockingLzApp.sol, it already implements the
ILayerZeroUserApplicationConfig.solinterface, which includes the function
|Blockdaemon Oracle Addresses
|The address to use for the configuration. The available addresses can be found here.
Users must call the
setConfig function for each pair of chains.
let config = ethers.utils.defaultAbiCoder.encode(
To repeat this configuration on each source chain for every destination chain, UA-Utils Tooling is used to simplify the process of modifying configurations across multiple blockchains.
For more information, please refer to the LayerZero documentations below:
Updated about 1 month ago