how to send an abi encoded message with Chainlink CCIP?

50 views Asked by At

I want to use a programmable token transfer using Chainlink CCIP. I want to send a token from Mumbai (source chain) with an function call in another contract on Avalanche (the destination chain).

I tried the token transfer with a string message, that works. But I dont know how to include a function call in the message

1

There are 1 answers

0
ZeusLawyer On

what you want to do is pass the target function's "call data" (which will be of the bytes data type) as the CCIP message (the data being sent using CCIP).

This require function call encoding.

Here is a great video on how to do that in 3 ways: https://youtu.be/70_2YHJvKIc