To mint USDC on the destination blockchain, we're using the messageBytes from the depositForBurn event and the attestation signature (attestationResponse.attestation). We're fetching both from Circle's attestation services and call the receiveMessage function on the Message Transmitter contract in the destination blockchain network.
Using Programmable Wallets' smart contract execution API:
You will be interacting with the Message Transmitter contract on the destination chain, so the contractAddress parameter of the request is 0xe09A679F56207EF33F5b9d8fb4499Ec00792eA73
The function being called on the Message Transmitter contract is:
receiveMessage(bytes message, ,bytes attestation)
This will be the abiFunctionSignature property of the request receiveMessage(bytes,bytes)
For the call to receiveMessage, the abiParameters are
The wallet that is performing the contract execution. This will be the ID of the developer-controlled wallet you created earlier.
A dynamic blockchain fee level setting (LOW, MEDIUM, or HIGH) that will be used to pay gas for the transaction. HIGH is used for this transaction.
Universally unique identifier (UUID v4) idempotency key. This is automatically generated for you.
A base64 string expression of the entity secret ciphertext. Refer to this helpful tool.
Once the message has been received, the specified amount of USDC will be minted at the recipient's address on the destination blockchain.
Note: The input parameters of this component differ from those of the actual endpoint. For instance, we automatically generate the Entity Secret Ciphertext to simplify the process and ensure a better experience for you.
A transactionId will be returned after you submit the receiveMessage request. You can use this transactionId to look up the status and details of the final transaction.