-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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] On-ramp: Add buy-crypto deeplink #5743
Conversation
eb83cd7
to
13518bd
Compare
@wachunei, can we configure the |
@wachunei Could you provide a video of this feature in action? Is it also intended to work for both tapping on a link as well as scanning a QR code? |
@Cal-L sadly no, the simulator was not handling any of the deeplinks correctly.
|
@lorenzosantos might also make sense to trigger an event here with referrer to know if this is being used and where their coming from (assuming user opted-in) |
@worldlyjohn we're intentionally keeping this PR simple as a POC while we develop a buy intent spec that can handle all the on-ramp edge cases. We plan to add several properties like token, amount, and referrer in an upcoming release (more details here). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
swinging this back your way @wachunei
1
When I attempt to deep link to a contract approval: https://metamask.app.link/approve/0x514910771AF9Ca656af840dff83E8264EcF986CA@1/approve?address=0x178e3e6c9f547A00E33150F7104427ea02cfc747&uint256=3e18
I get TypeError: undefined is not can object (evaluating ‘’t.toLowerCase;)
See recording: http://recordit.co/WSXnJIi1ro
2
When I deep link to the onramps flow via the URL SCHEMA deep link, then try to deep link to a dapp, The onramps flow always appear prior to opening the dapp.
See recording:
https://recordit.co/dDdpvRSzUa
To reproduce:
Deep link here metamask://buy-crypto
Tap get started
Then tap on “cancel”
Now kill the app and attempt to deep link here: https://metamask.app.link/app.olympusdao.finance/#/bonds
Notice the app opens to the onramps screen
If you were to tap cancel, then you are taken to the dapp in the browser
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't reproduce the issue as well. Checked the code, tested the deep link and universal link, tried to reproduce the issue following the instruction by @cortisiko and everything work correctly as expected. LGTM
@wachunei I am seeing the Your Region screen constantly pop back up if user cancels out of it and never continues pass Your Region. |
@chrisleewilcox is the browser loading the deeplink again and again? Can you kill the browser from the task manager? @andreahaku how can we solve the issue? If the above is not the case then the deeplink is not being marked as handled although |
@wachunei to clarify, it's seems to be any screen during the payment flow to set region or pay method these screens will pop back up when MMM app is selected/foreground on device. Device browser closed still does not fix problem. |
Issue #1 reported from @cortisiko is resolved. Issue #2 reported from @cortisiko is resolved. Payment deeplink device browser tap
Payment deeplink in-app browser tap
Regression: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Development & PR Process
release-xx
label to identify the PR slated for a upcoming release (will be used in release discussion)needs-dev-review
label when work is completedneeds-qa
label when dev review is completedQA Passed
label when QA has signed offDescription
This PR adds support for
metamask://buy-crypto
andhttps://metamask.app.link/buy-crypto
, these will open the buy flow when the current network supports it.Screenshots/Recordings
If applicable, add screenshots and/or recordings to visualize the before and after of your changeIssue
Progresses #???
Checklist