标签: ios-universal-links

如何正确格式化和提供 apple-app-site-association 文件

apple-app-site-association我正在尝试为共享一组公共路径的多个应用程序设置一个文件。Apple 提供的两套文档存在冲突。首先,该文档说每个应用程序都应该有自己的部分,然后有一个包含映射的 paths 元素:

{
    "applinks": {
        "apps": [],
        "details": [
            {
                "appID": "9JA89QQLNQ.com.apple.wwdc",
                "paths": [ "/wwdc/news/", "/videos/wwdc/2015/*"]
            },
            {
                "appID": "ABCD1234.com.apple.wwdc",
                "paths": [ "*" ]
            }
        ]
    }
}
Run Code Online (Sandbox Code Playgroud)

然后有一个 XCode 文档,它显示了完全不同的格式:

{
  "applinks": {
      "details": [
           {
             "appIDs": [ "ABCDE12345.com.example.app", "ABCDE12345.com.example.app2" ],
             "components": [
               {
                  "#": "no_universal_links",
                  "exclude": true,
                  "comment": "Matches any URL whose fragment equals no_universal_links and instructs the system not to open it as a universal link"
               },
               {
                  "/": "/buy/*", …
Run Code Online (Sandbox Code Playgroud)

app-store ios ios-universal-links

5
推荐指数
1
解决办法
1182
查看次数

Google Ads 应用互动广告系列不适用于 Firebase 动态链接

我尝试使用 Firebase 动态链接运行应用互动广告系列,但收到一个问题:“该链接不起作用,因为 Google Ads 不支持第三方重定向网址”。将其替换为支持的链接类型`。

您知道如何将动态链接应用于 Google Ads 应用互动广告系列吗?

deep-linking ios-universal-links firebase-dynamic-links google-ads-api android-app-links

5
推荐指数
0
解决办法
490
查看次数

与 Firebase 的动态链接

我正在尝试为我的应用程序/网站设置 firebase 动态链接www.example.com,但我做错了。这是我所做的

  1. 转到 Firebase 控制台中的动态链接,为域创建新的动态链接example.com
  2. 出现此错误www.example.com is not connected properly - There was a problem with your DNS configuration, check this configuration in Firebase Hosting. Note: it could take up to 24 hours for your DNS configuration to reflect recent changes.
  3. 我去托管连接域,我将必要的文件添加ATXT我的 DNS 提供商(网站未托管在 firebase 上)

完成此操作后,我测试了动态链接,这是我发现的

  1. 这些链接适用于该应用程序 - 如果我单击指向www.example.com它的链接,只会将我带到关联的应用程序,这就是我想要的
  2. 但是,当尝试访问该网站时,www.example.com我会看到Invalid Dynamic Link - Requested URL must be a parsable and complete DynamicLink

尝试使用网站时的响应

为什么动态链接可以工作,但网站却不能?如何修复动态链接,使其正常工作以及网站正常工作?

deep-linking firebase ios-universal-links firebase-dynamic-links

5
推荐指数
0
解决办法
857
查看次数

React Native Navigation,从自己的应用程序内打开通用链接

我正在使用React Native 的React Navigation。我已成功将其配置为处理通用链接,如下所示

// linking.ts
import { APP_ID } from '@env';

const config = {
    screens: {
        LoginScreen: 'authorize',
        RegisterScreen: 'register',
        CustomerStack: {
            screens: {
                OrderDetailScreen: 'customer/order/:orderId',
            },
        },
    },
};

const linking = {
    prefixes: [`${APP_ID}://app/`, 'https://example.com/app/'],
    config,
};

export default linking;
Run Code Online (Sandbox Code Playgroud)
// App.tsx

import linking from './linking'

const App = () => {
   return (
      <NavigationContainer linking={linking}> <MyApp /> </NavigationContainer>
   )
}
Run Code Online (Sandbox Code Playgroud)

当我按下浏览器中的链接(例如 )时https://example.com/app/customer/order/1234,它会成功打开我的应用程序的订单页面。

问题

我希望能够打开 url(例如https://example.com/app/customer/order/1234 在我的应用程序内部)并让它打开订单页面。我努力了

<Button onPress={() => …
Run Code Online (Sandbox Code Playgroud)

deep-linking reactjs react-native ios-universal-links react-navigation

5
推荐指数
1
解决办法
2816
查看次数

在 Flutter 移动应用程序中打开重置密码链接

在我的 Flutter 移动应用程序中,身份验证由我自己的服务器 API 处理

\n

目前,我的移动应用程序中有一个询问重置密码功能,它将重置密码链接发送到用户\xe2\x80\x99s 电子邮件收件箱。

\n

此链接会在用户\xe2\x80\x99s浏览器中打开一个网页,用户可以在其中输入新密码。

\n
\n

我不打开网页,而是喜欢此链接,在特定的重置密码路线上打开我的移动应用程序+坚持并向该路线提供重置密码代码

\n

我的链接应该具有什么样的属性才能实现此行为并向路由提供重置代码

\n

有没有办法在不使用 Firebase 动态链接的情况下实现这一切?

\n

我需要在 Flutter 应用程序中设置什么才能实现这些逻辑?

\n

I\xe2\x80\x99m 使用 BLoC 状态管理。

\n

deep-linking ios-universal-links flutter android-deep-link

5
推荐指数
1
解决办法
1388
查看次数

通用链接 - 域有一些验证问题

我正在使用通用链接打开应用程序,同时点击网址.我正在使用https服务器并完成了Apple(Apple Doc)的所有步骤.但苹果通用链接验证器显示以下错误,

未找到或未识别您文件的"内容类型"标头.

在此输入图像描述

apple-app-site-association文件成功上传到服务器,文件如下,

   {
    "applinks": {
        "apps": [],
        "details": [
         {
            "appID": "J2HBF9A3PZ.com.aors.speaku",
            "paths": [“*”,”/“]
         }
        ]   
    }
}
Run Code Online (Sandbox Code Playgroud)

苹果表示无需签署apple-app-site-association文件,无论域名是否为https.

如果文件是无符号的,则它应具有Content-Type of application/json.否则,它应该是application/pkcs7-mime.

所以我的查询是如何在这个apple-app-site-association文件中提及内容类型(application/json)???

请帮帮我.我不知道它究竟是什么意思.

https deep-linking ios ios-universal-links

4
推荐指数
1
解决办法
3185
查看次数

通用链接不会重定向到应用商店

我正在尝试使用两种配置为IOS 9设备实现设置Universal Link.首先,我在服务器端完成了配置步骤:

1.创建一个未签名的apple-app-site-association-unsigned.txt文件,文件内容为

{
        "activitycontinuation": {
            "apps": [
              "9JA89QQLNQ.com.apple.wwdc"
            ]
          },
        "applinks": {
                "apps": [],
                "details": [
                    {
                        "appID":"9JA89QQLNQ.com.apple.wwdc",
                        "paths": [
                                        "*",
                                        "/"
                                ]
                    }
                ]
            }
     } 
Run Code Online (Sandbox Code Playgroud)

2.使用标记上述文件

cat apple-app-site-association-unsigned.txt | openssl smime -sign -inkey demo.key -signer demo.crt -certfile demo.pem -noattr -nodetach -outform DER> apple-app-site-association

3.然后它在签名文件上创建,即apple-app-site-association

4.将此文件移动到我的证书可用的根服务器中.

5.用node.js创建一个端点

var https = require('https');
var fs=require('fs');
var express = require('express');
var privateKey  = fs.readFileSync(home_path + 'src/Server/API/demo.key', 'utf8');
var certificate = fs.readFileSync(home_path + 'src/Server/API/demo.crt', 'utf8');
var credentials = {key: privateKey, …
Run Code Online (Sandbox Code Playgroud)

server-side node.js ios9 ios-universal-links

4
推荐指数
1
解决办法
1954
查看次数

ios:通用链接无法在iOS 10上运行

我正在尝试在我的iOS应用中集成通用链接.因此,只要有人点击<myapp>.herokuapp.com/content就会直接重定向到应用程序.我按照指南进行设置.我做了以下设置,但无法使其正常工作.我还检查了stackoverflow上的其他线程,但没有一个解决了这个问题.

  • 在我的应用目标上的功能选项卡中添加了关联域.添加了两个域:activitycontinuation:<myapp>.herokuapp.comapplinks:<myapp>.herokuapp.com.
  • 在Build Phases> Copy Bundle Resources中添加了文件.entitlements.
  • https://developer.apple.com/account/#/membership获得teamId
  • 在我的网站上添加一个路由,apple-app-site-associationhttps://<myapp>.herokuapp.com/apple-app-site-association其返回以下JSON:

    {
        "applinks": {
            "apps": [],
            "details": [
                {
                    "appID": "<teamId>.<bundleId>.dev",
                    "paths": [ "*" ]
                },
                {
                    "appID": "<teamId>.<bundleId>",
                    "paths": [ "*" ]
                }
            ]
        },
        "activitycontinuation": {
            "apps": [
                "<teamId>.<bundleId>.dev",
                "<teamId>.<bundleId>"
            ]
        }
    }
    
    Run Code Online (Sandbox Code Playgroud)
  • 安装了从Xcode到iPhone 6s Plus(物理设备)的应用程序,带有包ID <bundleId>.dev和复制https://<myapp>.herokuapp.com/content到Notes的链接,但它在Safari中打开.

xcode deep-linking ios ios-universal-links

4
推荐指数
1
解决办法
5921
查看次数

如何获得通用链接打开应用程序而不是safari?

我已经尝试了一段时间才能获得iOS10的通用链接,但它到目前为止还没有工作.

我配置了一个apple-app-site-association.尝试在同一台服务器或其他服务器上使用根域,使用子文件夹.在所有情况下,我都被重定向到safari网页,下拉打开我的应用程序作为选项 在此输入图像描述 我错过了什么?

xcode ios mobile-development ios-universal-links

4
推荐指数
2
解决办法
6670
查看次数

iOS Universal Links有时会停止工作

我的应用程序支持通用链接,在大多数情况下,它可以正常工作,点击链接可以打开应用程序.

但有时候,我不确定为什么,它会停止工作.

它发生了几次给一个用户,点击链接停止打开应用程序,而是打开网络.
从那一刻起,你无能为力,让它再次发挥作用.

我知道如果你点击状态栏右上角的链接,它会禁用通用链接,从那一刻开始点击链接就会打开网页.要重新启用通用链接,您可以点击Notes App上的链接(例如),然后点击"在MyApp中打开"按钮.

但这似乎并非如此,用户告诉我他没有按状态栏上的链接,更奇怪的是,当试图通过点击Notes App中的链接重新启用通用链接时,"打开" MyApp"按钮丢失了.

什么可能导致这个问题?

deep-linking ios ios-universal-links

4
推荐指数
1
解决办法
2831
查看次数