How to get function signature offchain