Deep Linking Forms and Pre-filling Fields

This guide walks through linking to an KPA EHS form from another app or website and pre-setting values on the form when the link is clicked.

Linking to an KPA EHS Form

You can link to an KPA EHS web form by right-clicking the “Fill Out” button and choosing “Copy Link Address”:

In some cases, you may prefer to link to a form within the native iOS and Android apps. In that case, use the same form id to create a short link:


When this link is clicked from another app it will open the KPA EHS app and then open the identified form within the offline forms module.

Pre-filling Fields

NOTE: The following feature is considered is subject to change at any time.

Now that you’ve linked to your form, you may want to pre-fill some of the fields. For example, maybe there’s a text field that should be pre-filled to “Hello World”.

First you’d need to know the field id. Open the field settings and click advanced:

To handle the encoding, we’ll use JavaScript to create a URL that sets this Description field to “Hello World”:

"iscout://form/6512?initialValues=" + encodeURIComponent(
    'xocbctskdnbcgjs':{ text:"Hello World!" },

So the url will wind up looking like this:


This also works on the web link we showed at the very beginning. You can pre-fill as many fields as you’d like – just keep in mind that some older browsers (like IE11) are limited to 2k characters – so probably 30 fields.

You can do the same for other field types like Select fields. The easiest thing to do is fill out a sample response then mimic what the data looks like.

For example, if you view a response then the url looks like Change the word “view” to “json” in the url and you can see the raw data. Now under “latest” find your fieldId (in this case it’s x8efsdlfnsbew). The “value” object is what you’ll want to mimic.

So pre-filling both the text field and our new select field would look like this:

"iscout://form/6512?initialValues=" + encodeURIComponent(
    'xocbctskdnbcgjs':{ text:"Hello World!" },
    'x8efsdlfnsbew': { values: ['5581c845ca0a0c14a2de621a'] },

Which generates the url:


KPA EHS in 60 Seconds

Watch this quick overview of the KPA EHS system.

10 Minute Walk-through

Watch this walk-through of the KPA EHS system.