[英]iOS Deep Linking with Auto Login Token in the URL
I am new to deep linking in iOS and I am trying to make sign-in work with a magic link.我是 iOS 中深层链接的新手,我正在尝试使用魔术链接进行登录。
The links that the users would receive in their email inbox would be something like this:用户将在其电子邮件收件箱中收到的链接如下所示:
https://subdomain.domain.com/?autoLogin=XXXX...XXXX https://subdomain.domain.com/?autoLogin=XXXX...XXXX
I want to extract the auto login token and make sure when users click into this link, it takes the user directly to the app.我想提取自动登录令牌并确保当用户单击此链接时,它会将用户直接带到应用程序。
What path should I put in the apple-app-site-association
file?我应该在
apple-app-site-association
文件中放入什么路径?
Currently I have /?autoLogin=
and it's not working.目前我有
/?autoLogin=
并且它不起作用。
In your URL, ?autoLogin=
is a query item and not part of the path.在您的 URL 中,
?autoLogin=
是一个查询项,而不是路径的一部分。
In your apple-app-site-association
you should just need to set the path to /
.在您的
apple-app-site-association
您只需要将路径设置为/
。 The ?
?
is messing it up since it's used to match any single character in the string.搞砸了,因为它用于匹配字符串中的任何单个字符。
If you want to have a specific path, you'll have to update your url to something like https://subdomain.domain.com/autoLogin?token=XXXX...XXXX
, then you could add /autoLogin
to apple-app-site-association
.如果您想拥有特定路径,则必须将您的网址更新为
https://subdomain.domain.com/autoLogin?token=XXXX...XXXX
,然后您可以将/autoLogin
添加到apple-app-site-association
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.