【问题标题】:Android Google Assistant open my app with just app nameAndroid Google Assistant 仅使用应用名称打开我的应用
【发布时间】:2021-05-08 09:03:33
【问题描述】:

我看到了 Google Assistant 代码实验室,并通过 Google Assistant 实现了开放应用。我正在使用actions.intent.OPEN_APP_FEATURE 意图,它没有达到我的预期。例如,当我说“Hey google open myAppName app/application/work/run”时它可以工作。但我希望它在我说“嘿 google appName”时打开我的应用程序。谁能帮我解决它?提前致谢!

<?xml version ="1.0" encoding ="utf-8"?>
<actions>
    <action intentName="actions.intent.OPEN_APP_FEATURE">
     <fulfillment urlTemplate="https://app.page.link/open{?featureName}">
        <parameter-mapping
            intentParameter="feature"
            urlParameter="featureName" />
    </fulfillment>
    <parameter name="feature">
        <entity-set-reference entitySetId="FeaturesSetId"/>
    </parameter>
   </action>

<entity-set entitySetId="FeaturesSetId">
    <entity name="App" identifier="app"/>
    <entity name="Application" identifier="application"/>
    <entity name="Work" identifier="work"/>
    <entity name="Run" identifier="run"/>
</entity-set>
</actions>

【问题讨论】:

标签: android android-deep-link google-assistant app-actions


【解决方案1】:

App Actions BII 无法识别超出其预定义语言模式的请求。从open app feature documentation 可以看出,它可以识别如下模式:

  • 打开 Youtube 历史记录。
  • 打开 ExampleApp ExampleFeature。
  • 显示 ExampleApp 上的 ExampleFeature。

因此,您尝试执行的操作可能不受开放应用功能的支持。

如果您想使用 BII 不支持的语言模式,则需要考虑使用 custom intent

【讨论】:

    猜你喜欢
    • 2022-12-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多