js icon indicating copy to clipboard operation
js copied to clipboard

Wallet connect safe EIP 5792 not working

Open avp1598 opened this issue 2 weeks ago • 3 comments

Description: I am trying to perform atomic batch transactions (EIP-5792) using a Safe Wallet connected via WalletConnect. However, I am unable to configure the initial WalletConnect handshake (Session Proposal) to request the necessary capabilities.

The Issue: Smart Accounts like Safe have a strict WalletConnect bridge: if the wallet_sendCalls method or atomic capability is not explicitly requested in the optionalNamespaces or sessionProperties during the initial connection, the wallet permanently hides these RPC methods for the session.

Currently, the Thirdweb SDK v5 (e.g., createWallet("walletConnect") or <ConnectButton />) does not appear to expose a way to pass custom namespaces or sessionProperties. It seems to use a hardcoded default set that excludes EIP-5792 methods.

Steps to Reproduce:

Initialize a Thirdweb v5 client.

Connect a Safe Wallet (via the Safe Web App's WalletConnect bridge) using createWallet("walletConnect").

Attempt to send a batch transaction using wallet_sendCalls (via Viem adapter or raw provider).

Result: The Safe bridge rejects the call with MethodNotFoundRpcError or UnknownRpcError.

avp1598 avatar Dec 23 '25 09:12 avp1598