Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
indigo_2025.1_documentation:webhooks [2025/10/21 19:54] – [Locative Webhook Examples] davel17indigo_2025.1_documentation:webhooks [2026/02/03 19:45] (current) – [Test Your Webhook] davel17
Line 13: Line 13:
  
 <code> <code>
-https://myreflector.indigodomo.com/webhook/IDFROMCONFIG+https://myreflector.indigodomo.net/webhook/IDFROMCONFIG
 </code> </code>
  
Line 19: Line 19:
  
 <code> <code>
-https://myreflector.indigodomo.com/webhook/IDFROMCONFIG?api-key=APIKEYHERE+https://myreflector.indigodomo.net/webhook/IDFROMCONFIG?api-key=APIKEYHERE
 </code> </code>
  
Line 243: Line 243:
 == Summary == == Summary ==
 We created a single Indigo webhook that catches a JSON payload and in an embedded script it uses data from the payloads to determine where Joe is. We also created two locations in Locative that represent home and work, and configured the webhooks for both locations to hit our single webhook trigger and pass through their data. We created a single Indigo webhook that catches a JSON payload and in an embedded script it uses data from the payloads to determine where Joe is. We also created two locations in Locative that represent home and work, and configured the webhooks for both locations to hit our single webhook trigger and pass through their data.
 +
 +==== Synology NAS Webhook Example ====
 +
 +Synology DSM supports webhook events and they work great with Indigo's Webhook Events. This document describes how to set up a Synology DSM webhook event (sender) and Indigo webhook event (receiver). It assumes a certain level of familiarity with both Synology DSM Notifications, Indigo Webhook events and Indigo authentication. There are many configurations that are possible and this article describes a very basic example. 
 +
 +=== Setting Up Indigo Webhooks ===
 +
 +  - In Indigo, create a new Trigger.
 +  - Under Type, select Web Server Event.
 +  - Under Event, select Webhook.
 +  - Under the Configure Webhook dialog, copy the Webhook ID and paste it somewhere safe. If you want, you can change the ID to something else -- it must be unique.
 +  - Under Webhook Method, ensure it's set to POST.
 +  - Under Processing, ensure it's set to JSON.
 +  - Set up the Action for your Indigo Trigger (send an email, write to the event log, etc.)
 +  - Save your Trigger.
 +
 +{{:indigo_2025.1_documentation:synology_nas_webhook_trigger.png?600|Webhook Trigger}}
 +
 +{{:indigo_2025.1_documentation:synology_nas_webhook_config_post.png?600|Webhook Trigger Config}}
 +
 +{{:indigo_2025.1_documentation:synology_nas_webhook_action.png?600|Webhook Action}}
 +=== Setting Up Synology DSM Webhooks ===
 +
 +  - Log into the Synology NAS administrative dashboard.
 +  - Open the Control Panel app.
 +  - Select Notification.
 +  - Select Webhooks
 +  - Click the "Add" button to add a new webhook.
 +  - Choose a Notification Rule, enter a Provider Name, and Subject
 +  - Enter the configured webhook URL which should have a form similar to this: **''https://MY_REFLECTOR_NAME.indigodomo.net/webhook/MY_INDIGO_WEBHOOK_ID?api-key=MY_INDIGO_API_KEY''** where you replace **''MY_REFLECTOR_NAME''**, **''MY_INDIGO_WEBHOOK_ID''**, and **''MY_INDIGO_API_KEY''** with values from your Indigo setup. Use the webhook ID you got from the Indigo Webhook Trigger. For the API key, you can also use a local secret.
 +  - Click Next (or switch to the HTTP Request tab).
 +  - Adjust the request as needed -- can leave at defaults for your first webhook.
 +  - Save your webhook.
 +
 +{{:indigo_2025.1_documentation:synology_nas_webhook_provider.png?600|Webhook Provider}}
 +
 +{{:indigo_2025.1_documentation:synology_nas_webhook_request.png?600|Webhook Request}}
 +
 +=== Test Your Webhook ===
 +
 +  - Select your new Synology web hook if it's not already selected.
 +  - Press the "Send Test Message" button.
 +  - Confirm the webhook worked (depends on the Action options you chose above.) 
 +
 +An example event log success message:
 +
 +<code bash>
 +Trigger     Synology Webhook Event
 +Email+      sending email 'Synology Webhook Event' to '[email protected]' using Email+ SMTP Server
 +</code>
 +
 +And the notification!
 +
 +{{:indigo_2025.1_documentation:synology_nas_webhook_email.png?600|Webhook Email}}
 +
 +=== Customize Your Webhook Event ===
 +
 +Now that you've confirmed that your Indigo Webhook event is working properly, you can customize it to make it even more useful. Because we've selected a POST event, the Synology DSM webhook will pass DSM event data to Indigo. You can use that payload to take different actions. When an Indigo POST web hook is triggered, it includes the payload that was POSTed. You can access this payload with a Python script. The payload is sent as JSON, so you can access the DSM event information by working with the `event_data` payload that's sent to the trigger. See the [[indigo_2025.1_documentation:webhooks|Webhooks Page]] for more information. 
 +
 +
  • /www/perceptive/wiki/data/attic/indigo_2025.1_documentation/webhooks.1761076463.txt.gz
  • Last modified: 2025/10/21 19:54
  • by davel17