0

Suppose I have a solidity contract deployed at address X in Hedera testnet. I want to call a function from the contract deployed at contract X a get function that returns an array of structs...how do I decode that array of structs? (I am using ContractCallQuery function from the Hedera JS SDK library to call the get function) Ref: Link

Tahlil
  • 1,031
  • 1
  • 14
  • 26

1 Answers1

1

the SDKs have support for "simple" data types, for more complex types, I suggest you use existing web3 libraries such as ethers.js, web3.js or abiDecoder. You can find some examples here, not with structs, but using the above libraries alongside the SDK: https://github.com/hashgraph/hedera-smart-contracts-libs-lab

Greg Scullard
  • 241
  • 1
  • 10