New whatsapp integration for Home Assistant

04/04 - Important update
I have made some changes in the integration:

  • I moved the “target” from configuration to the service field to make it more dynamic.
  • I added support to send media file (Image/Video, etc.).

All changes are documented in the updated README:

Hi All,
I created a new whatsapp integration for Home Assistant.
This time, using the Green-API free account.

Enjoy (:

3 Likes

Thanks Tomer for great integration! Does it support sending files/screenshots from HA?

Hi @Abunafha
Not yet, I’m working on it.
I will add it to the next version

1 Like

Done!
You can now attach media:

Follow the updated instructions

Works great! Thanks much!

Implemented notification with screenshot from camera, once camera detects person in the area.

hello.
this sounds so cool. can you help me how to implement it.
i am new to HA… :slight_smile:

Hello Again.
i managed to connect the Green api, and to send messages.
i will try to find how to take screenshots from my unifi cameras. but i have a bigger problem. after i scanned the QR from green-api i dont get notifications on my phone for new whatsapps. i can see the massages in the chats but i dont get notified about any whatsapp i get on my phone.

Toda for your help in advance.

Hello! Using a different phone number than the one registered with our WhatsApp could be a potential solution. I’ve personally tried this approach, and haven’t found another workaround yet. Hope this helps!

Hey guys, im trying here but it doesnt appear on services :confused:

Tried the HACS/manual version.

image
image

Having the same issue. Not showing up in services. Any help?

How trustworthy is the Green API? It’s not an offical WhatsApp integration, is it?

Same thing … did you manage to get it going?

Comment out or remove the 'Target" in the config.yaml section.

Maybe related to this:

Working now:

image

Please share a how-to :smile: Thanks!

I did the notification using node-red instead and work 100%

Weird, I dont have it on my config and does not work :confused:

Does anyone know how to set up a flow in nodered to send ss?

Hi, you need create an automation, triggered by camera motion detection, then perform 2 actions: 1) take a snapshot from camera and store under selected location, 2) send message using the API with screenshot within data, please refer to below automation YAML

alias: WhatsApp alert on entrance person detection
description: WhatsApp alert on entrance person detection
trigger:

  • platform: state
    entity_id:
    • <binary_sensor.YOUR_CAMERA_MOVEMENT_SENSOR>
      to: “on”
      condition:
      action:
  • service: camera.snapshot
    metadata: {}
    data:
    filename: /media/snapshots/entrance/last_snapshot.jpg
    target:
    entity_id: camera.cameraentrance_sub
  • service: notify.greenapi
    data:
    message: Person detected on entrance
    target: <YOUR GROUP/PERSON ID>
    data:
    file: /media/snapshots/entrance/last_snapshot.jpg
    mode: single

hello .
is there an option of sending a whatsapp to home assistant.
so basically when i send a whatsapp to a specific chat then i can make an automation to turn on the light for example.