I have created a Gnosis-safe. In general I wonder, how I can interact contractually (using web3) with the Gnosis-safe contract. The Gnosis-safe address links to a proxy contract.

My question is how I can interact with the Gnosis-safe and get all owners of that safe.

1 Answer 1


The following solution, interacting right with the contract GnosisSafeL2:

const code = await web3.eth.getCode(SAFE_ADDRESS)
if(code !== '0x') {
    const jsonGnosisSafeL2 = JSON.parse(fs.readFileSync('./contracts/build/GnosisSafeL2.json'));
    const gnosisSafe = new Contract(jsonGnosisSafeL2.abi, SAFE_ADDRESS);
    console.log(await gnosisSafe.methods.getOwners().call());

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.