By now, you will likely be familiar with how the Survey123 web and field apps can help you capture data through smart forms. In this blog post I want to introduce a new capability you may not know about: feature reports. The purpose of Survey123 feature reports is to let you generate high quality printable documents from data captured with Survey123. The concept is simple: first define the contents and look and feel of your final report using Microsoft Word, then associate the report template with your survey. From that point, you can create reports at will.
Below are a couple of examples showing what Survey123 feature reports can look like. Note that you can define your own header and footer, carefully set the position and size of maps, photos, signatures and any other data captured with Survey123.
Survey123 Feature Reports are useful when you need to present your survey123 data following strict formatting guidelines, for example when mimicking legacy paper forms or to comply with legal documents.
A bit of context: Survey123 feature reports vs summary reports
Generally, the word report is associated with summary reports where data is aggregated to help identify trends. Survey123 includes basic summary report capabilities, but these are not the focus here. This discussion is about feature reports. A feature report presents data from a single survey record.
Say for example you use Survey123 to support asset inspections and you want to generate one document, as proof-of-work, for each inspection performed. For that you use feature reports. Say your smart forms are used to document city code violations and you want to generate and mail individual tickets for violations observed… for that you use feature reports too. The purpose of a feature report is not to aggregate data across multiple surveys; the purpose is to present data for a single submitted survey.
In a way, this capability is about bringing your survey data back into a form format, except that in this case, you want the form to present data, as opposed to using the form to collect data.
Feature Report Templates
The way you configure your own report templates is quite simple, yet powerful. A Survey123 Feature Report template is essentially a Microsoft Word document with some keywords referencing survey questions.
We chose Microsoft Word because it is a very popular tool that you likely know how to use. Who does not know how to set a header and a footer, arrange a table or define font formatting in Microsoft Word? You can put all your Microsoft Word tricks to work to ensure your report looks exactly as you want.
Templates include certain keywords referencing questions in your survey. These keywords will ultimately be replaced with the data from the survey records you want to report. This is what a report template looks like:
The Survey123 Report Template syntax allows you to simply reference data in your survey but also do other more interesting things. For example, you can build conditional logic to incorporate or hide certain portions of your survey record. You can build repeatable sections to loop through related records, and even extract data from attachments and display that information within your report.
Once your survey has been associated with one or more report templates, you can create reports right from within the Survey123 website. The output file is a Microsoft Word document (pdf outputs coming before end of 2019), which will be stored in your own content. For your convenience you will also be able to download right away the report from your browser.
You can choose to generate feature reports in bulk selecting multiple records or applying a filter to your Survey123 data.
Very often you will want to automate report generation. By leveraging Survey123 webhook support, you can automatically create and e-mail a feature report document as soon as a survey record is added into ArcGIS. Think violation reports as an example: a Survey123 form is used to document a violation. As the data comes into your ArcGIS Online account, an email is being sent to a specified recipient with a properly formatted violation report: City logo at the top, signature at the bottom, a nice map highlighting the location, a photo, comments, etc.
Our friend Jim Moore describes how this can be done in this video tutorial:
If you are a fan of the ArcGIS Python API, you may want to look at the generate_report operation in the Survey123 Python class.
ArcGIS Online credits
The Survey123 feature report service is an ArcGIS Online Premium service. It takes 2.5 credits per survey report generated. For those of you who have been using this service for a while, we waived credit consumption while in Beta. We also introduced a grace period from July 2019, when this service was generally made available, until the October 2019 update to smooth out transition. Time is approaching: Starting with the October 2019 Online update, credit consumption will kick-in.
ArcGIS Enterprise support
The Survey123 feature report service is at this moment hosted in ArcGIS Online and it is designed to work with surveys hosted in ArcGIS Online. However, with some limitations, this service can also be used with surveys hosted in your own ArcGIS Enterprise 10.5 or newer.
- Your ArcGIS Enterprise instance must be accessible to the Survey123 ArcGIS Online feature report service. That is, you must configure your ArcGIS Enterprise web adaptor to expose access to your Enterprise instance from the internet. Please note that portals with Integrated Windows Authentication will not work with the feature report service.
- The inclusion of any type of feature service attachments (photo, signature, annotated images…) is not supported when your data is hosted in ArcGIS Enterprise.
Bearing the limitations above, the use of the ArcGIS Online feature report service from your ArcGIS Enterprise instance will not incur into any ArcGIS Online credit costs.