logoAcademy

Dataflow

Learn the complete flow of a Cross-Chain message.

Looking at the bigger picture, the data flow of an interchain message can be described as follows:

Message Initialization

Cross-Chain dApp initiating the message calls the Interchain Messaging Contract on the source Avalanche L1

Warp Precompile

The Interchain Messaging contracts interacts with the AWM precompile of the EVM

Message Relaying

An AWM Relayer relays the message to the destination Chain. It periodically checks the source Avalanche L1 for outgoing messages and delivers these by calling the Interchain Messaging contract on the destination Avalanche L1.

Signature Verification

The Interchain Messaging contract on the destination chain interacts with AWM to verify the signature of the message and whether it has been signed by a sufficiently large stake share of the source Avalanche L1's validator set.

Destination Contract Call

The Interchain Messaging contract then calls the destination dApp contract

Message Processing

The dApp decodes the message payload and processes it accordingly.

As you noticed in the Teleporter Basics chapter most of the cross-chain communication has been abstracted away from the dApp developer. The only interfaces for them are:

  • Sending a message: Simply calling the Interchain Messaging contract on the source chain
  • Receiving a message: Being able to be called by the Interchain Messaging on the destination chain

To start, we will assume there is always an AWM Relayer to deliver our messages without any incentives. Let's dive deeper into the sending and receiving of messages in the next sections.

On this page