foundry-starter-kit icon indicating copy to clipboard operation
foundry-starter-kit copied to clipboard

Add Chainlink Functions example

Open andrejrakic opened this issue 1 year ago • 1 comments

Let's add an example for Chainlink Functions as well. Because Functions Foundry Starter kit is not live yet, let's showcase how easy is to use Functions with Foundry. Also I suggest example with multiple responses, because it shows how to:

  • Return complex Solidity data types (they usually return complex structures)
  • Use JavaScript imports for more powerful computation
  • Perform HTTP GET/POST requests using Functions library

Tasks:

  • [ ] Add this contract example https://docs.chain.link/chainlink-functions/tutorials/abi-decoding
  • [ ] Add this JavaScript file https://docs.chain.link/chainlink-functions/tutorials/abi-decoding
  • [ ] Test it with Chainlink Local (pending)
  • [ ] Optionally test it with pure Foundry using ffi flag

andrejrakic avatar Aug 15 '24 19:08 andrejrakic

@andrejrakic lets discuss this when you're back

zeuslawyer avatar Aug 19 '24 03:08 zeuslawyer