Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE REQUEST] Replace copy/paste of public key with URL parameter to wallet provider #311

Closed
jeremiahlee opened this issue Jun 6, 2024 · 5 comments
Labels
discussion: idea Ideas of potential features triage Waiting to be assigned labels

Comments

@jeremiahlee
Copy link
Contributor

jeremiahlee commented Jun 6, 2024

Describe the feature you would like to request

I would like the extension onboard to have fewer steps the user must complete.

In the alpha 1 release, the user must copy a public key from the extension and paste it into the wallet provider's website.

2024-05-30.alpha1.clip.share.mp4

Describe the solution you would like

  1. User enters wallet address and taps connect.
  2. Extension opens the wallet provider's website with the extension's public key as a URL parameter.
  3. Wallet provider authenticates the user and saves the extension's public key when the user confirms they want to authorize the amount to use from the wallet.

Additional context

I'm not sure if additional information can be passed along with the grant approval. If not, then the desired solution would be to first confirm the user wants to use this browser for Web Monetization (as a way to approve saving the public key) and then the grant approval for the budget is a second approval.

While Interledger does not control the wallet provider website, but it could define a URI scheme as part of the wallet provider specification. Something like https:// (walletProvider.example/usersWalletAddress) /keys/add?key= (public key contents here). Because the key is a public key, it's fine for it to be passed as a URL parameter, where it might be included in server access logs.

@jeremiahlee jeremiahlee added triage Waiting to be assigned labels discussion: idea Ideas of potential features labels Jun 6, 2024
@tselit tselit added this to the Backlog milestone Jun 20, 2024
@sidvishnoi
Copy link
Member

Some related discussion in #332 also (but about removing keys, not adding).

@sidvishnoi
Copy link
Member

During Slovenia work week, I proposed a potential approach, which the team generally agreed with.
As the extension can control web pages (and we already use those permissions), we can emulate user adding the key, without requiring manual copy-paste. We can add a button "connect keys" (or something) in extension which will do the automatic key addition - we still want it happening on user interaction only (though, goal is to reduce amount of interaction required). If we fail to add, we fallback to the current copy-paste approach.
It's a bit fragile (wallets changing UI), but the happy path would reduce UX overload a lot.
This would require some major rework on connect screen UI, so it may or may not make it to beta release, but we aim to do so.

I plan to discuss another (long-term) approach in today's Rafiki community call. But we'll likely go with above approach until/if all wallets support a standardized way.

@jeremiahlee
Copy link
Contributor Author

From the Slovenija work week: the approach proposed at the top was agreed to be technically viable. However, @AlexLakatos said current wallet providers are not willing to do any additional integration work. The proposed approach remains a long-term option.

I do not support implementing extension-controlled user agent automation. Technical workarounds for business development problems should be a last strategy.

  • The user would see flashes of page navigation and form input manipulation occurring, which could appear like someone was controlling their device, especially on lower end hardware or slower Internet connections.
  • When wallet providers change their websites, they could break the onboarding without notice. This would require an extension update in order to fix. A fallback to the copy/paste method would prevent a full onboarding outage until an extension update rolled out, but this would then still require onboarding documentation to account for this scenario, which then does not achieve our goal of simplifying how much information a new user needs to be exposed to in order to get started.
  • We could instead imitate the API requests the forms on wallet providers' websites use to not have visible page navigation, but this also is a fragile implementation.

@sidvishnoi
Copy link
Member

Filed an issue for the long-term idea (interledger/rafiki#2995). We've decided to go with the "browser automation with extension" idea for now.

@sidvishnoi sidvishnoi moved this from Backlog to Todo in Web Monetization Extension Sep 20, 2024
@sidvishnoi
Copy link
Member

Closing in favor of #613

@github-project-automation github-project-automation bot moved this from In Progress to Done in Web Monetization Extension Sep 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion: idea Ideas of potential features triage Waiting to be assigned labels
Projects
Archived in project
Development

No branches or pull requests

4 participants