WhatsApp notifications from Home Assistant
There's no built-in WhatsApp integration in Home Assistant. For a business number, the usual route is a rest_command that calls a WhatsApp API. Here's the config, with examples from holiday parks, marinas and buildings.
A rest_command to your own number
A template
Get a utility template approved, with fixed wording around the details such as the location and the fault.
A rest_command
The API key goes in secrets.yaml, the command in configuration.yaml. Restart once and it's ready.
An automation
Call the command from any trigger: a leak sensor, a door contact, a temperature reading.
tobachat_api_key: tc_live_...rest_command:
tobachat_alert:
url: https://api.tobachat.nl/v1/send-template
method: POST
headers:
X-API-Key: !secret tobachat_api_key
content_type: "application/json"
payload: >-
{"phone": "{{ phone }}",
"template": "outage_alert",
"language": "en",
"variable_mapping": {"1": {{ where | to_json }}, "2": {{ what | to_json }}}}- alias: "Leak in the plant room"
triggers:
- trigger: state
entity_id: binary_sensor.leak_sensor_plant_room
to: "on"
actions:
- action: rest_command.tobachat_alert
data:
phone: "+31612345678"
where: "Plant room"
what: "water on the floor"Alerts businesses set up
Fixed template wording, with the details filled in by Home Assistant.
Marina
Office building
End every template with fixed wording, such as: You get this message because you signed up for our outage alerts.
What an alert has to meet
- Only to people who asked: your team, or a customer who signed up for alerts. Anyone who replies STOP gets nothing more.
- Pick the Utility category and leave offers out, or Meta may reclassify the template as marketing, which costs more.
- A template can't start or end with a variable.
Alerts from the number your customers already know
Your own business number
The alert comes from your number with your business name on top, over the official WhatsApp Business Platform.
No duplicates
Add an Idempotency-Key and we won't send the same alert twice within 24 hours, even when Home Assistant retries.
Every alert in your inbox
You see every alert in your shared inbox, and when the caretaker or a guest replies, you answer right there.
More than alerts
The same number answers customer questions too, handled by your team or the AI agent.
What it costs
Alerts are part of every plan. Start free, then €29, €99 or €199 a month, cancel any month. Meta charges per alert on top, depending on the recipient's country.
Home Assistant and WhatsApp
Other questions about WhatsApp
Your first alert from Home Assistant
Start free, connect your number and create an API key.
Prefer a hand getting started? We'll get you started