# \[APP\]\[Pro\] WhatsApp - Simple. Reliable. Private

**URL:** <https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749>\
**Category:** Apps\
**Tags:** app, tools, flow, homey-pro, advancedflow\
**Created:** [October 2, 2023, 10:03am UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749 "2023-10-02T10:03:45Z")\
**Posts on this page:** 20\
**Page:** 50

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 6, 2024, 7:30pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1004 "2024-10-06T19:30:55Z")

</div>

Just to be sure, I can “catch” the mention of my “homey ai bot ;)”,

 ![Screenshot from 2024-10-06 21-27-16](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/1/9/19f3687e616cf944fc47519c4301d264b2e3c105.png)

but I would like to do the mention in the message I sent out!

So, I would like to do something like:

HEEEE @31061234567: The washingmachine is done, please put it in the dryer.

This way I can “nagg” may teenagers in the house to do some chores 😉

 ![Screenshot from 2024-10-06 21-32-47](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/6/0/60753f5afe46f1a7b45d514c3873e324cb693a54.png)

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 6, 2024, 7:34pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1005 "2024-10-06T19:34:37Z")

</div>

@Frekel both packages you share are an external service or are using a browser window to let this work which is really heavy on memory.

The Whiskeysockets Baileys package ( linked in first post) is using the same web sockets as the WhatsApp web and therefore can be implemented at a way lower memory footprint and is also less likely to get taken down. The baileys packages is not that straightforward as the things you send and there’s not such thing as a single call 😉

But as far as I see with mention you want to send a mention and not receive?

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 6, 2024, 7:42pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1006 "2024-10-06T19:42:59Z")

</div>

@martijnpoppen Yes. Looking at the code from Baileys I am looking for something like:

`const sentMsg = await sock.sendMessage(id, { text: '@12345678901', mentions: ['12345678901@s.whatsapp.net'] })`

I kinda think this is not something you can whip up in a day, but If you need help I am more than willing to take a look!

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 6, 2024, 7:51pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1007 "2024-10-06T19:51:25Z")

</div>

@Frekel where did you see that? Will check. Think this is possible

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 6, 2024, 7:59pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1008 "2024-10-06T19:59:24Z")

</div>

@martijnpoppen Saw it on the github page:

> **[GitHub - WhiskeySockets/Baileys: Lightweight full-featured typescript/javascript...](https://github.com/WhiskeySockets/Baileys?tab=readme-ov-file#non-media-messages)**
>
> Lightweight full-featured typescript/javascript WhatsApp Web API

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 8, 2024, 6:30pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1009 "2024-10-08T18:30:54Z")

</div>

## New app update (🟩 LIVE: [1.27.7](https://homey.app/a/com.whatsapp/)):

> **Changelog:**
> 
> **NEW:**  
> **1:** NEW: add clear widget button to device  
> **2:** NEW: Add mentions to flowcards. (use like `@31612345678 this is a test`)
> 
> **FIXES:**  
> **1:** FIX: widgets performance improvements

  

* * *
  

If you find any **issues** , send a **report** via the mobile homey app

> More - apps - Whatsapp - settings wheel right top - send diagnostic report (put your email in the input field to make it easier)

  

* * *

Issue list: [[APP][Pro] WhatsApp - Simple. Reliable. Private - #3 by martijnpoppen](https://community.homey.app/t/app-pro-whatsapp/90749/3)

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 8, 2024, 6:31pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1010 "2024-10-08T18:31:30Z")

</div>

@Frekel Mentions are added (see message above ☝ )

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 8, 2024, 6:39pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1011 "2024-10-08T18:39:17Z")

</div>

NO WAY!!! 🥰 🥳

---

<div class="post-metadata">

**Author:** ![Snoep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/snoep/32/114963_2.png) [@Snoep](https://community.homey.app/u/Snoep)\
**Post date:** [October 8, 2024, 6:54pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1012 "2024-10-08T18:54:06Z")

</div>

Hi @martijnpoppen,

First of all thanks for all the hard work you’re doing with your Homey Apps, i actually love using them!

I’d like to suggest adding the ability to delete messages, and here’s why:

I have a smart doorbell that sends a notification to a WhatsApp group consisting of myself, my wife, and my Homey (Homey Pro Bot). The process works as follows:

1. The first message sent is: **“Ding dong, someone’s at the door.”** , along with a snapshot from the doorbell.

2. Immediately after, the image is sent to OpenAI for analysis.

3. Once the analysis is complete, a second message is posted: **“Ding dong, it appears the delivery driver is here with a package for you.”**

This results in two messages with the same image—one generic and one more detailed after the AI analysis.

What I would like is for the first message to act as a “Loading State”, and once the image is analyzed, that initial message should be deleted and replaced with the detailed one. This way, only the more informative message remains, avoiding redundancy in the chat.

I’ve reviewed the documentation for the WhatsApp client you’re using, and it does support message deletion.

Thanks for considering this feature!

For the ones interested in the AI Analysis:

 ![image](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/e/2/e2fadb1d3f1ec2577c900ac0b942946c38286875.png)

```auto
async function sendRequest(image, question) {

  const url = 'https://api.openai.com/v1/chat/completions';

  const headers = {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer redacted',
  };

  const body = {
    model: 'gpt-4o',
    messages: [
      {
        role: 'system',
        content: 'you are a computer, that answers questions truthfully and briefly'
      },
      {
        role: 'user',
        content: [
          {
            type: 'image_url',
            image_url: {
              url: image
            }
          },
          {
            type: 'text',
            text: question
          }
        ]
      }
    ]
  };

  try {
    const response = await fetch(url, {
      method: 'POST',
      headers: headers,
      body: JSON.stringify(body)
    });

    const data = await response.json();
    console.log(data);
    return data.choices[0].message.content; // Return the data if needed for further processing
  } catch (error) {
    console.error('Error:', error);
    return null; // Return null in case of error
  }
}

const json = JSON.parse(args[0])
const image = json.image
const question = json.question
// Call the function
const answer = await sendRequest(image, question);
tag("openai_analyze_image_answer", answer)
return answer

```

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 8, 2024, 7:08pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1013 "2024-10-08T19:08:38Z")

</div>

@Snoep i like the idea but this app was never intended to interfere with the original messages  
I also foresee a lot of issue with this setup. As it can conflict with other messages

If this gets any votes of other people I might consider it. But for now I won’t integrate this

---

<div class="post-metadata">

**Author:** ![Snoep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/snoep/32/114963_2.png) [@Snoep](https://community.homey.app/u/Snoep)\
**Post date:** [October 8, 2024, 7:11pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1014 "2024-10-08T19:11:03Z")

</div>

I understand, unfortunate.  
I might fork your app and try it myself. JS/Typescript is not really my expertise tho 😃

---

<div class="post-metadata">

**Author:** ![Rogier\_Verheugen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/rogier_verheugen/32/77406_2.png) [@Rogier\_Verheugen](https://community.homey.app/u/Rogier_Verheugen)\
**Post date:** [October 8, 2024, 7:40pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1015 "2024-10-08T19:40:03Z")

</div>

Hi @martijnpoppen,

I have updated the app to 1.27.7. The scroll function in the Widget is working on my tablet.

Well done. Thanks

Rogier

---

<div class="post-metadata">

**Author:** ![Michael\_Zimmer](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/michael_zimmer/32/80082_2.png) [@Michael\_Zimmer](https://community.homey.app/u/Michael_Zimmer)\
**Post date:** [October 8, 2024, 7:48pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1016 "2024-10-08T19:48:34Z")

</div>

On my device the whatsapp widget is not showing any messages.  
I sent the code (without 'and with ‘CODE’) to the whatsapp group I created.  
No change

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 8, 2024, 7:49pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1017 "2024-10-08T19:49:31Z")

</div>

@Michael_Zimmer Please send a diagnostics report

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 8, 2024, 9:06pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1018 "2024-10-08T21:06:44Z")

</div>

@martijnpoppen It is working _buuuutttt_ I saw one small thing. If you enter a comma directly after the phonenumber to mention, it is not working:

 ![Ontwerp zonder titel](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/9/6/960dd86766c3f7bc3b20330dbf2277f33b971b63.png)

For now, this is no issue. I create the messages myself, so I can just prevent it from happening (just a space between the number and `,` will do!!)

Thanks again for the great work!

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 8, 2024, 9:07pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1019 "2024-10-08T21:07:30Z")

</div>

@Frekel oh yeah correct I take the whole text just behind the @ so it won’t validate it properly with the comma indeed.

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 8, 2024, 9:13pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1020 "2024-10-08T21:13:09Z")

</div>

=== offtopic ===  
I am kinda doing the same thing (except no image processing). Did you see [OpenAI App for Homey | Homey](https://homey.app/en-nl/app/com.openai.ChatGPT/OpenAI/).

Will prevent you the hassle of homeyscript 😉

=== ontopic 2 cents ===  
My first response to the doorbell would be to say:  
`Someone ring the bell, please open the door. In the mean time I will try to figure out who it is`  
Then do the processing of the image.  
Based on the result, you can send either the enhanced image or the original image

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 8, 2024, 9:14pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1021 "2024-10-08T21:14:14Z")

</div>

I guess you can (but don’t need to) take the 10 numbers after an @-sign. It will always be 10 😉

---

<div class="post-metadata">

**Author:** ![martijnpoppen](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/martijnpoppen/32/84849_2.png) [@martijnpoppen](https://community.homey.app/u/martijnpoppen)\
**Post date:** [October 8, 2024, 9:22pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1022 "2024-10-08T21:22:37Z")

</div>

@Frekel for NL 06 it is. But for 097 it’s 12  
So that won’t work 😉

Ps: I use a E.164 validation so in that case the phone number is always correctly validated. I prefer not to sanitize the number. But it can be done if needed.

---

<div class="post-metadata">

**Author:** ![Frekel](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/frekel/32/4983_2.png) [@Frekel](https://community.homey.app/u/Frekel)\
**Post date:** [October 8, 2024, 9:29pm UTC](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749/1023 "2024-10-08T21:29:40Z")

</div>

For now I have this in my flow, so I am all good 😉  
 ![Screenshot from 2024-10-08 23-27-47](https://us1.discourse-cdn.com/flex025/uploads/athom/original/3X/3/e/3e09128327c1f56001e6857fc2806e60fc45bd86.png)

So I am running a replace “+” → “@” and add a `space` after the senders number and use that for my mentions!

[Previous page](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749.md?page=49)

[Next page](https://community.homey.app/t/app-pro-whatsapp-simple-reliable-private/90749.md?page=51)
