如何让whatsapp代表react-native应用程序执行操作?

发布于 2025-01-13 22:53:53 字数 257 浏览 3 评论 0原文

我正在尝试将 Whatsapp 集成到我的反应本机应用程序中。到目前为止,我找到的资源仅告诉如何从react-native应用程序通过Linkurl发送消息或打开whatsapp。但我想更进一步,通过 Whatsapp 执行操作。想象一下,您触发通知并选择“是”和“否”,然后执行相应的操作,我想在 Whatsapp 上实现类似的功能。用户从反应本机应用程序执行某些活动后,我想在 Whatsapp 上发送通知,并且在不打开反应本机应用程序的情况下,用户应该能够执行操作。有没有办法可以实现这个功能。

I am trying to integrate whatsapp in my react-native app. So far the resources that I have found only tell how to send a message or open whatsapp via Linkurl from react-native application. But I want to take a step further and perform action from whatsapp. Imagine like you trigger the notification and you select the Yes and No and that performs the respective actions I want to make similar functionality but on whatsapp. After a user perform certain activity from the react-native application I want to send notification on whatsapp and without opening the react-native application the user should be able to perform action. Is there a way I can achieve this functionality.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

苏佲洛 2025-01-20 22:53:53

React Native/JS 不支持“whatsapp://”方案。

仅限以下方案:

  • mailto; //用于邮寄
  • 电话; //对于电话
  • 短信; //对于短信
  • http/https; //对于超链接

您可以使用此方法将 WhatsApp 消息直接发送到某个号码。

https://wa.me/

React Native/JS do not have support to 'whatsapp://' scheme.

The following Schemes Only:

  • mailto; //For Mailing
  • tel; //For Telephone
  • sms; //For SMS
  • http / https; //For Hyperlinks

You can use this method to send WhatsApp message direct to a number.

https://wa.me/<phone#>

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文