Closed Gropher closed 1 month ago
Hi @Gropher, I can't reproduce this issue with MetaMask deeplinks.
Can you give more context into what you are trying to achieve?
This whole procedure works fine on iOS but on Android we getting ERR_UNKNOWN_URL_SCHEME error on final step
And no we do not use Wallet Connect
@Gropher You are saying you were able to open another app from within the MetaMask Browser? How did you achieve this? I am trying to use deep linking but its not working for me.
For example after the user is finished interacting on MetaMask and its time for them to go back to "MyApp" I do
window.location.href = "myapp://user?id=12345"
but nothing happens. Are you able to expand more on this? Or do can you explain your implementation using branch.io
Thank you!
I too have a problem open firebase dynamic link or any deep link in metamask
Even the firebase dynamic link actually redirect to intent://
url scheme so it become broken when metamask cannot handle it. This very much decrease metamask app usability for other dapp
I think the solution is that metamask should at least open any error link in the external browser, or relegate them to native OS to handle instead of this useless ERR_UNKNOWN_URL_SCHEME
message
And there was a fix at least for intent://
schema that firebase was used with originWhitelist
attribute and onShouldStartLoadWithRequest
event
source : https://stackoverflow.com/a/60883730/1513380
I suspect that the origin of this problem are around here
and here
So I would like to suggest
const onShouldStartLoadWithRequest = ({ url }) => {
if (isENSUrl(url)) {
go(url.replace(/^http:\/\//, 'https://'));
return false;
}
if (!url || url.startsWith("http:") || url.startsWith("https:")) {
return true;
}
// open natively
Linking.openURL(request.url).catch(er => { console.log('Failed to open Link:', er.message); });
return false;
};
Is it possible?
Further investigation seem to be the reactnative itself not handle the intent://
url scheme
https://github.com/facebook/react-native/pull/31836
So we could try to make the reactnative team to fix this then wait metamask to rebuild a new version. Or metamask might try to handle intent:
scheme with the intent URL parser in the mean time ?
Another thing I would like to be considered
Given that firebase dynamic link, $projectname$.page.link
, has this domain pattern and normal browser could handle this link. Maybe it would be better to detect .page.link/
in url and use Linking.openURL
for this domain (with onShouldStartLoadWithRequest
?)
Alternatively, maybe could you have some way to expose Linking.openURL
in webview?
Such as allow postMessage({ "action" : "openURL", "url" : "customscheme://custompath" })
or something like this to be call in webview ?
Hello all, I'm facing a similar issue with deep links on a React Native application (v0.64.0
), currently only tested on iOS.
Trying to open a page to connect a wallet and navigate back to the app with a few details passed via a deep link URL something like app://connect/detailshere
or https://app.com/connect/detailshere
.
These deep links do work on a browser like Safari, the prompt to open them in the app shows up but not within the MetaMask browser.
Is this simply not possible for now or are we missing something? Any thoughts on how to go about this would be deeply appreciated. 🙏
This seems like a natural user journey that we should try and support.
Are there any progress on this?
It might be related to Universal Link handling if you are on iOS. It is said, a Universal Link can only be activated by user interaction. Perhaps your codes are like
setTimeout( () => { window.location.href = "https://yourapp.page.link/hook"; }, 1000);
Somehow, it will redirect the user to App store even with the App installed.
But after I changed it to
someBtn.onclick = () => { window.location.href = "https://yourapp.page.link/hook"; };
It works just fine.
Did anyone know how to programmatically navigate users back to our Apps?
Is that issue fixed? I'm getting the same problem. I cannot redirect from metamask browser to my app by gaggle://home link
@andreahaku @ezgi-cengiz there may be some limitations in scalability on supporting link back to dapps, but I'd defer to your judgment on how we can support this issue.
@gantunesr we have users reporting this error when attempting to list NFT's on opensea.
ZD 931973 and 933120
Hi everyone, I've been searching for solution where I would be able to redirect user back to browser app after he connects his wallet. I don't know if that would be possible, since WalletConnect had to implement whole bunch of stuff to make it work.
My idea was to use deep link in format https://metamask.app.link/dapp/myapp.com&redirect=true&function=auth or in case of message signature https://metamask.app.link/dapp/myapp.com&redirect=true&function=signMessage
Where after the function is done user would be redirected /dapp/
Any ideas, maybe temporary solutions are welcome 😁
Nearly 3 years passed and this bug still persist
Hi all! Is this issue still applicable?
This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 7 days. Thank you for your contributions.
So metamask not in development anymore?
This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 7 days. Thank you for your contributions.
So would it be fix or will be closed?
This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 7 days. Thank you for your contributions.
Is this problem still not being solved?
cc @andreahaku @adamceresko
This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 7 days. Thank you for your contributions.
This issue was closed because there has been no follow activity in 7 days. If you feel this was closed in error please provide evidence on the current production app in a new issue or comment in the existing issue to a maintainer. Thank you for your contributions.
Describe the bug I'm trying to use deep link to get the result of transaction back into my native Android app but it doesn't work. I'm getting ERR_UNKNOWN_URL_SCHEME error after redirect to my app link: jjoapp://open?click_id=123456
Screenshots https://ibb.co/Bq5WRhY
To Reproduce Redirect to any deep link in Metamask browser
Expected behavior After redirect to deep link Metamask opens the app in question
Smartphone (please complete the following information):
to be added after bug submission by internal support / PM Severity