ABI not including certain structs

I’m trying to use the GovernanceInstruction struct in my rust test file but I can’t seem to find it in the abi even though its part of the contract:

  • how does the abi choose which struct gets compiled?
  • if you need to use a struct in sway but its not in the abi, how can you access it in rust?
  1. Only types that are used in the contract methods (as parameters or returns), logged or used as configurables will show up in the ABI.
  2. Make it part of the public interface via any of the above.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.