.png)
smart home integrations
Let your smart home raise the alarm
A door sensor, a camera, a smoke alarm or a button by the bed can raise a MyGuardz home alarm, through a webhook. Your household and your Circle are pulled in at once, and a guard too if Guard Cover is on for that home.
What is a webhook?
A webhook is a private web address. When your smart home platform calls that address, MyGuardz knows something has happened and acts on it. It works one way only: your devices can tell MyGuardz something, but MyGuardz can't see or control your devices.
Front door opens
while everyone's away. A home alarm is raised.
Smoke detected
while you're out. Your Circle gets the address straight away.
A button by the bed
A Zigbee button that raises the alarm without reaching for a phone.
What happens when it fires?
A home alarm is raised
The same alarm as pressing the button in the app, for the home you linked the webhook to.
Your household and Circle are pulled in
They see the address and your webhook's message, for example “Front door opened, nobody home”, so they know what set it off.
If Guard Cover is on, the control room calls first
Stand it down on that call and no guard is sent. No answer, or you confirm, and the nearest available licensed guard is dispatched to the address.
Create a webhook in MyGuardz
1
Open Set up integrations
In the app, go to your Profile and tap Set up integrations, then Webhooks.
2
Create a webhook
Tap Create webhook, choose the home it belongs to, and give it a name you'll recognise, like Front door.
3
Add a message
Optional, but worth it: this is what your household and Circle see in the alarm, like “Front door opened, nobody home.”
4
Copy the URL
Copy the webhook URL and paste it into your smart home platform, using the guide for your platform below.
One webhook per event is clearest, so the message says exactly what happened. You can also use one webhook for a group of similar devices, like every window sensor.
Keep it secret
Each webhook is a unique HTTPS address. Anyone who has it can raise an alarm for your home, so treat it like a key:
​
-
Don't share it, post it in forums or screenshots, or commit it to GitHub.
-
In Home Assistant, keep it in secrets.yaml, not in your automations.
-
If it might have leaked, delete the webhook in MyGuardz and create a new one.
Webhooks add to your home security. They don't replace a monitored alarm system, and MyGuardz is not an emergency service.
Platform guides
Every platform does the same thing: when your trigger happens, send an HTTP POST to your MyGuardz webhook URL. In the examples, replace YOUR_MYGUARDZ_WEBHOOK_URL with the URL you copied.
1. Store the URL. Add it to secrets.yaml:
myguardz_webhook: "YOUR_MYGUARDZ_WEBHOOK_URL"
​
2. Add a REST command. In configuration.yaml:
rest_command: myguardz_home_alarm: url: !secret myguardz_webhook method: post
​
3. Restart Home Assistant. Go to Settings, open the three-dot menu (top right) and choose Restart Home Assistant. A quick reload isn't enough the first time you add rest_command; later changes to it can be reloaded with the rest_command.reload action.
​
4. Create the automation. Settings - Automations & scenes - Create automation.
Add your trigger, add a condition (for example, alarm armed away), then under Then do add the action rest_command.myguardz_home_alarm. In YAML:
actions: - action: rest_command.myguardz_home_alarm
​
Keys in YAML are lower case. Upper-case keys like REST_COMMAND won't load. Keep method: post: without it, Home Assistant sends a GET request.
You'll need a home hub (Apple TV or HomePod) so the automation runs when you're away.
-
In the Home app, tap +, Add Automation and choose your trigger, for example a door sensor opening.
-
Choose any scene or accessory to continue, then scroll down and tap Convert to Shortcut.
-
Tap + to add an action, choose Web, then Get Contents of URL.
-
Paste your webhook URL, tap Show more and set Method to POST.
-
Tap Done.
-
-
In the sidebar, go to Automations - Rule Machine - Create New Rule, and name it.
-
Under Trigger events, choose your device and event.
-
Under Actions to run, choose Send, Speak, or Log a Message, Send HTTP Request - Send HTTP Post.
-
Paste your webhook URL and save. Turn on Use required expression to limit it to when the home is set to away.
-
Test it
A test raises a real alarm.
Tell your household and Circle first, and make sure Guard Cover is off for that home while you test, or a guard may be sent.
Trigger the device, or send a request yourself from a computer:
curl -X POST "YOUR_MYGUARDZ_WEBHOOK_URL"
The alarm should appear in the app within moments, with your message. Close it, and let everyone know it was a test.
Stuck? Email team@myguardz.com with your platform and what you've tried. Never send us the webhook URL itself.