Message with Ton
Messaging with Ton Network
Chain Id and Contract
Check Contract here.
Ton Network message out
Call message out
relay
indicates whether message processing is required on MAP Relay Chain.msgType
indicates different message,MESSAGE
orCALLDATA
.target
is the contract address where the message will be executed upon reaching the target chainpayload
is the data intended for cross-chain transmission.gasLimit
is the maximum gas limit allowed for execution on the target chain.
External out message
If the omni-chain message is sent successfully, an external out message will be generated, similar to an EVM event.
Message to Ton Network
Sending a omni-chain message to TON is the same as sending messages to other chains. You can directly encode the assembled MessageData
and then call transferOut
to send the omni-chain message. It is essential to ensure that the message data payload is a message that can be recognized by TON.
Here, toChain
is the TON Network chain id:
mainnet:
1360104473493505
testnet:
1360104473493506
Last updated