MessagingParams
Title: ILayerZeroEndpointV2 (LayerZero v2 EndpointV2) — vendored subset
Authors: David Dada <daveproxy80@gmail.com> (https://github.com/dadadave80), Vendored minimal subset of LayerZero v2's ILayerZeroEndpointV2 (https://github.com/LayerZero-Labs/LayerZero-v2). Upstream license: MIT.
Minimal vendored subset of the LayerZero v2 EndpointV2 (the OApp messaging endpoint): the quote
/ send pair the adapter dispatches through, plus the setDelegate / eid / lzToken /
nativeToken reads. LayerZero routes by uint32 endpoint id (eid), not EVM chainId.
Verified verbatim against LayerZero-Labs/LayerZero-v2 (MIT):
packages/layerzero-v2/evm/protocol/contracts/interfaces/ILayerZeroEndpointV2.sol and its
IMessageLibManager / IMessagingContext message structs. Re-declared at pragma ^0.8.30 — do NOT
add a LayerZero-v2 dependency. The shared message structs are file-level (see also
ILayerZeroReceiver, which imports Origin from here).
Parameters for an outbound message: destination eid, 32-byte receiver (the remote OApp), the
message body, the packed executor/DVN options, and whether the fee is paid in the LZ token.
Note:
- lattice-source: LayerZero
struct MessagingParams {
uint32 dstEid;
bytes32 receiver;
bytes message;
bytes options;
bool payInLzToken;
}Properties
| Name | Type | Description |
|---|---|---|
| dstEid | uint32 | |
| receiver | bytes32 | |
| message | bytes | |
| options | bytes | |
| payInLzToken | bool |