如何为快捷方式应用程序自定义SiriKit意向扩展以询问是否允许访问? [英] How to customise SiriKit intent extension for shortcuts app to ask allow access?

查看:213
本文介绍了如何为快捷方式应用程序自定义SiriKit意向扩展以询问是否允许访问?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

通过扩展 SiriKit ,我们可以为Siri构建自定义意图. 此外,苹果公司介绍了如何管理 Siri快捷方式和应用程序

We are allowed to build custom intent for Siri, by extending SiriKit. Moreover, Apples present how to manage basic integrations and customizations to Siri Shortcuts and Shortcuts app

链接快捷方式应用程序

尽管如此,某些应用程序还是具有一些自定义的快捷方式UI.例如带有允许访问API的按钮,我们该怎么做?

Nonetheless, some apps have their own shortcuts UI with a little customization; for instance with the button to allow access for API, how can we do that?

在Apple提供的文档中,没有关于如何根据我的应用程序创建的自定义意图自定义快捷方式应用程序中的UI的说明.

In the documentation presented by Apple, there is no such instruction for how is it possible to customize the UI inside the shortcuts app regarding the custom intent created by my app.

我试图对Intent响应进行自定义失败,但没有找到用于API访问的选项.就像↴

I tried to make custom failure for the Intent response but didn't find the option for API access. Like ↴

但是,在尝试首次运行trello while时,没有什么与Shortcuts App呈现的用户界面非常相似

However nothing quite similar to the UI presented by Shortcuts App, while attempt to first run trello ↴

推荐答案

这些操作由快捷方式"应用程序本身提供,而不是由其他应用程序公开的Siri意图提供.实际上,这些操作甚至都不需要安装Trello或Wunderlist应用.

These actions are provided by the Shortcuts app itself rather than by Siri intents exposed by another app. Indeed, these actions don’t even need the Trello or Wunderlist apps installed.

这意味着快捷方式可以显示不同的UI.

This means that Shortcuts can present a different UI.

将为您的应用显示的用户界面由intents文件中的参数定义.

The UI that it will show for your app is defined by the parameters in your intents file.

您无法为您的应用创建相同的体验,但是用户可以在您的应用本身中执行任何必需的授权,因此可以合理地预期他们已经在运行您的应用之前尝试设置使用该应用的快捷方式.

You can’t create the same experience for your app, however the user can perform any required authorisation in your app itself and it is reasonable to expect that they have run your app before trying to set up shortcuts that use it.

这篇关于如何为快捷方式应用程序自定义SiriKit意向扩展以询问是否允许访问?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆