For all of you out there with teams in the field collecting data with paper and pencil, we’d like to introduce you to the mobile form expert, iFormBuilder.  With iFormBuilder you can setup mobile forms that your field reps can fill out on their mobile devices and that data is immediately sent to HQ. 

Then, add Formstack Documents into the mix and you can automatically generate reports of that data to share with the test of your team.  In this example, we’re going to show you how you can automatically generate a building inspection report after an inspection has taken place.

The first step in the process is setting up our report template in Formstack Documents.  We’re going to use the online builder to setup our template, so go ahead and click the New Document button, give it a good name, then choose the “Build Your Own” option.

On the next step, you’re going to setup your template in the editor.  To add merge field tags (where you want your data to go), you’ll use tags like {$InspectionDate}, {$BuildingAddress}, etc.  Simply type in these merge fields like you do other text in the document. We’re also going to add a few images (more info here) placeholders to the template for images that will be uploaded on the form.  Here’s what our report template looks like:


Once we have our document setup, let’s jump over to the Settings tab and turn on Test Mode + Debug (we’ll use this in a little bit), plus turn on the Field Map setting located under the Advanced Options section.  We’ll be using the Field Map a little bit later too.

Ok great, now we’re ready to start the integration process with iFormBuilder.  Before you leave Formstack Documents, go to the Merge tab for your document and you’re going to see a Merge URL.  This is a unique URL for your document that you’ll use in iFormBuilder.  Go ahead and copy that URL, then let’s jump over to iFormBuilder.

Inside iFormBuilder, we’ve already setup our inspection form, so that’s all ready to go.  Now what we need to do is setup the form to automatically send information to our Formstack Documents document.  To do this, we’re going to go to the Form Assignments page, pick our form, then click the Assign button.

After you’ve selected your form, you’ll be taken to a page that has a section called “Post Data”.  This is where you are going to setup the data feed to Formstack Documents.  Go ahead and click “New Endpoint”.  Give it a name, then enter your document’s Merge URL for the Endpoint URL.  The data format will be “JSON” and you’ll use “application/json” as the content type.

After you save the endpoint, we’re ready to run a test submission through so that we can match up our document fields with the fields that iFormBuilder will be sending over.  Go ahead and submit a test record, then jump over to Formstack Documents and go to the Overview tab for your document.  On the Overview page, you should see a “View Data” button in your Recent Merges section.  Click that and you’ll see the data we are receiving from iFormBuilder.  You can click each of the fields and it will show you the merge codes that you will need to use.

However, instead of updating our document, we’re just going to use the Field Map to easily map our document merge fields with the fields that are coming through from iFormBuilder.  In the corresponding box next to each merge field, go ahead and enter the merge tags like {$_0.record.building_address}.  Here’s what our Field Map looks like:

Great, we’re done!  Now that the field map is complete, we’re ready to run another test record through iFormBuilder and we should receive a populated document with the inspection information.  Here’s what our completed report looks like:

Congrats, you can now save your team hours every day by auto-generating reports!  Are there any other ways that Formstack Documents and iFormBuilder could help streamline your business?

Was this article helpful?
0 out of 0 found this helpful


  • I am trying to create a field map for a iform with many multipaging subforms. Could someone post an example code for a field in a subform in the field map? For example, my main form has:

    Mile Post From:
    Mile Post To:

    My subform also has those fields, but the number entered there should come from the appropriate place, subform or mainform.

    Thanks in advance.

  • Hi Spencer,

    Please turn on Debug Mode (https://webmerge.zendesk.com/hc/en-us/articles/206526126-Debug-Mode) for your document and then you can get the exact merge fields to use in your Field Map.


  • Hi, this is a great start. I have an iForm configuration where the field techs will fill out many of the same subform under a single parent form, but I don't want to make individual placeholders for each one. Is it possible for the web merge document to automatically create all the results for as many of the subform datasets that exist in my main form?

  • Hi Clinton,

    Yes, you can use "loops" in your document to loop through each subform. Check out https://webmerge.zendesk.com/hc/en-us/articles/206526116-Loop-through-a-list-of-items

    Please submit a support ticket if you need more specific help and we'll get you pointed in the right direction!

    Thanks :)

  • That's great thanks for the reading. Before I get to that....I feel like I'm missing an obvious step. You mention submiting a test record after we setup our Form endpoint URL. I'm not seeing a "Submit" of any kind on the iForms side to send over a test record. Do you mean manually uploading (on webmerge) the json payload from the data record in the iForms data table view?  I'll submit a support ticket too, but I thought this would be good to have sticky on this post if the detail could help others...


    Update:  I figured this out, when you finish submitting an iForm record it will post, or you can edit an existing one and when you save it, it will post.  No "Test Submit" as I was imagining. 

    Thanks again for the good article on getting this setup.

  • Ok, great!

  • Is it possible to have a document for both the parent form and subform? For instance if I used this for timesheets and I needed a timesheet for each day (5 - subforms) and one weekly summary (parent) is it possible for all to be posted when the weekly parent form is submitted?


  • Hi Eric,

    Yes, it's possible! The subforms should be included in the JSON then you can loop through them like this: https://support.webmerge.me/hc/en-us/articles/206526116-Loop-through-a-list-of-items

    You'll need to turn on Debug Mode (https://support.webmerge.me/hc/en-us/articles/206526126-Debug-Mode) to find out what the field names are to use form the subforms.



Please sign in to leave a comment.