We are integrating Gnosis Safe Wallet into our app with ethers library but we are unable to get a signer, i.e., required for completing transactions. I used @gnosis.pm/safe-apps-react-sdk for getting sdk into our app and @gnosis.pm/safe-apps-provider for getting a provider, which I used to fetch provider, safeAddress, account etc., and I am able to connect my app with safe app with safe app address. But when I am trying to do transaction using the safe app, I am unable to get a signer which is required to complete the transaction. Can someone help from team how I am able to get signer so that I am able to do transactions on safe app with a safe app address?
1 Answer
You should be able to get a signer like this:
const signer = new SafeAppsSDK({
allowedDomains: [/app.safe.global/],
debug: false,
});
const { safeTxHash } = signer.txs.signMessage(message);