A message proof is a cryptographic proof that a message was included in a block. You can use the getMessageProof
method to retrieve a message proof for a given transaction ID and message ID.
const result = await tx.wait();
const messageOutReceipt = <TransactionResultMessageOutReceipt>result.receipts[0];
const messageProof = await provider.getMessageProof(
TRANSACTION_ID,
messageOutReceipt.messageID
);