Skip to content

[feature-request] Ability to Use Ethereum Gas Station Network #52

Description

@jpiabrantes

Allow Gasless Transactions
The Ethereum GSN allows for gasless transactions. This gives users a very good UX because they don't need to go through KYC to buy ETH (or MATIC) to use your dapp and pay the gas fees. The way this works is that the user signs a meta-tx that is sent to a relayer and then gets executed by a smart contract that pays the gas fees (the dapp owner funds this smart contract).

Describe the solution you'd like
Openzeppelin has a package @openzeppelin/network where the web3 provider can work with GSN:

const local = useWeb3Network('http://127.0.0.1:8545', {
  gsn: { signKey: useEphemeralKey() }
});

OpenGSN also has a package @opengsn/provider that gives a GSN compatible provider:

const { RelayProvider } = require('@opengsn/provider')

const config = { 
    paymasterAddress,
    loggerConfiguration: {
        logLevel: 'debug'
    }
}
const provider = await RelayProvider.newProvider({ provider: web3.currentProvider, config }).init()
const web3 = new Web3(provider);

To sum up, to get the best web3 UX I would love to have a flutter_web3 provider compatible with GSN.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions