I am writing this blog post because I wanted to document a useful workflow that I developed for using Integromat to automate the creation of Feature Reports for Survey123 after editing the survey data. As someone who had never used Integromat before, I spent a great deal of time researching the different intricacies of the Integromat modules and how to make them work for what I needed, as I couldn't find any examples that were quite the same as mine. A lot of this workflow was accomplished by trial and error, so I'm posting this here in the event that someone else may find this example useful. My particular difficulty in this project came when I attempted to process the automation differently when the survey was initially submitted (addData event type) vs. when it was edited (editData event type.)
My scenario is this:
I work in local government (city level) and we have continually been making services and applications available online as a convenience to our citizens. As such, one item on our agenda was to make our Application for New Sewer Service available on the internet. I created a survey in Survey123 for the purpose of allowing citizens to apply to our Sanitary Board for new sewer service (when you move to a new house and need to put the service in your name, or when you build a new house and need brand new service). I also needed an easy way for our Sanitary Board staff to process these requests. Creating an automated workflow with Integromat seemed like it would provide the perfect solution for automation, and paired with the power of Dashboards for ArcGIS, I think it did!
The Simple Workflow:
1) Citizen submits an application for new sewer service.
2) Sanitary Board staff receives the request.
3) Sanitary Board staff processes the request (they need to add some information to the form, such as new account number, deposit cost, date paid, etc.)
4) Microsoft Word application form is filled out with applicant’s information and filed in archive.
The Solution:
Workflow Item # 1 – Submitting the Application
To allow citizens to submit an application, I created a new survey in Survey123 Connect with all pertinent information included and published to our ArcGIS Online Organization. This was the easy part.
Workflow Item # 2 – Receiving the Application
In order for the staff to access the information, I was going to train them on how to use the Survey123 online interface. The problem with doing this is that they also need to have the ability to edit the data, which at the present time is only available to the survey owner or the individual survey submitter. This was not going to work. This is where I found out about embedding surveys in a dashboard https://community.esri.com/groups/survey123/blog/2020/04/27/survey123-tricks-of-the-trade-embedding-.... Even more importantly, embedding that survey into a dashboard in edit mode using URL parameters https://community.esri.com/groups/survey123/blog/2019/02/06/survey123-tricks-of-the-trade-web-form-u... (both great blog posts by Ismael Chivite). This gave our staff the ability to go into the survey record and add data to the “office use only” fields (or change any other field that may have been entered incorrectly in the initial survey), including account number, deposit cost, date paid, etc. Below is a screenshot of the dashboard with the editable survey form included:
I also wanted the staff to receive an email when a new record was submitted to avoid missing one or prevent a delay in processing, and this is the first use case for Integromat (I could have used Microsoft Power Automate (MS Flow), but I needed to run a feature report later, which at this time was not available in MS Power Automate). I’ll post a screenshot of the Integromat Scenario a litte farther down. I will also attach the blueprint exported from Integromat for those who might want to take a look. That takes care of workflow item #2 – the actual receipt of the application. Moving on to processing.
Workflow Item #3 – Processing the Application
Using the dashboard with the editable survey form embedded, staff can now select the survey record (newest submissions come in on top of the list), review all the submitted information, add the new account number and other “office use only” information, then re-submit the now-complete survey form. Now we need to get all this information onto the Microsoft Word Template that is the actual application form. This is done using the “Create Feature Report” module in Integromat. There was a little problem with this step, which I’ll explain a little further down when you can see the Integromat Scenario screenshot.
Workflow Item # 4 – Getting the Information onto the “paper” application
This item is accomplished using the Integromat “Create Feature Report” for Survey123 module https://support.integromat.com/hc/en-us/articles/360020842234-Survey123. I then used the "Microsoft Office 365" module to send the Sanitary Board staff an email with the completed Feature Report attached.
Integromat Scenario
Here is a screenshot of the Integromat Scenario:
Here’s an explanation of the scenario, step-by-step:
Now, here is the logical explanation: When a new survey is submitted, a confirmation email is sent to the submitter, then an email is sent to the office staff to notify them of the new submission, including any image attachments submitted with the survey. The office staff then processes the application and uses the custom Dashboard to edit the survey record to include additional information. When they submit their edits, a Feature Report is created from the survey record and it attaches to an email and sends to the office staff.
.
I’m sure there are other ways to go about doing what I have done, but this is the way worked for me. I could not find a good resource that explained how to run the “Create Feature Report” module after an “editData” condition, so if nothing else, I hope this helps to explain that process. I’m no programming master (by a long shot!). Shoot, I’m not really even a novice. But I do have to say that this Integromat integration is pretty easy to use. Good stuff ESRI!
I've exported the blueprint for the scenario from Integromat and attached it to this post for reference.
You should also check out https://community.esri.com/groups/survey123/blog/2019/06/02/getting-started-with-survey123-and-integ... and https://community.esri.com/groups/survey123/blog/2019/06/04/survey123-tricks-of-the-trade-integromat. There is great information in both of these links. Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.