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 [2026/02/03 18:41] davel17indigo_2025.1_documentation:webhooks [2026/02/03 19:45] (current) – [Test Your Webhook] davel17
Line 245: Line 245:
  
 ==== Synology NAS Webhook Example ==== ==== 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.1770144093.txt.gz
  • Last modified: 2026/02/03 18:41
  • by davel17