drips-network / app

💧 Funding that flows — Drips Frontend
https://drips.network
GNU General Public License v3.0
31 stars 17 forks source link

Sponsor Project Claim & Collect transactions #1187

Open efstajas opened 1 month ago

efstajas commented 1 month ago

Depends on #1182

Gas on FVM is extremely cheap, and Gelato Relay will be available (projected by end of August). We can easily cover costs for claiming projects and collecting tokens, which makes those flows entirely gasless, and makes it possible for people to move earned tokens on Drips to their wallet without needing to acquire any FIL.

What we need

UX Outline

Claiming project

Below is for the case when the app instance is configured to sponsor all claim & collect transactions on the given network. If it's not, things are generally the same, except the user needs to execute the 2nd transaction rather than it being gasless.

Collecting

Failure cases

(All errors below must be sent to Sentry in addition to being caught)

efstajas commented 2 weeks ago

Summary for claiming gaslessly on FVM with rate limiting:

On networks where we don't sponsor both transactions (e.g. mainnet) OR if the user is using a Safe, everything is the same as above, except for that the 2nd transaction is proposed to the user's wallet instead of being relayed gaslessly.