Starting with Survey123 for ArcGIS 3.0, webhooks can be set up and activated when a survey response is submitted. What does this mean? Basically, when a survey is successfully submitted, different workflows can be triggered based on the content of the submission: sending notification emails, adding results to a spreadsheet and so on.
There are a wide variety of workflow services available, such as Power Automate (aka MS Flow), Integromat, tray.io, Zapier, IFTTT, n8n.io, CloudHQ and the list goes on. Most (if not all) of them can be used to incorporate Survey123 as a trigger to build your automated process. Out of these, Integromat and Power Automate have a Survey123 connector making it easier to implement your processes. This article guides through an example using Power Automate.
What will you need to create Survey123 webhooks?
- ArcGIS Online (AGOL) Organisational account
- Your Survey123 form published into AGOL
- Office 365 account to access Power Automate
Below is a workflow for creating a webhook that triggers an alert email if the submitted data meets a condition (for example the weather is Adverse).
1. Open Power Automate (go to your O365 account and search for the app), go to My flows and click on + New > Automated - from blank :
2. Give your webhook a meaningful name, so you know which one to edit/disable later if needed when you have more of them.
Under the branch, add a new step (click on the ‘+’ sign) and search for Send an email (Outlook). Set up the required details and save your flow – use both Save buttons: one at the bottom and one in the top right corner!
6. Download your survey in the Survey123 app and test your trigger. If you downloaded the survey before the trigger was added, delete the survey and re-download it. Otherwise your webhooks won’t work.
In Part 2 we will discuss how to add the survey time to your webhook/flow and convert time zones.