WebHook Submit Actions

WebHooks are server to server communication connections that, when added to your Form, allow you to send collected Form data to a third party service through a URL.  Adding a WebHook is an excellent option when you want to send your Form data to an integration/program that Formstack does not support in-App.  To use this feature, you will first need to create or obtain a valid WebHook URL address to make a connection.  If you are sending your Form data to a Third Party Integration, then your WebHook may be found in your API or Settings Page.


Adding your WebHook


To add a WebHook to your Form, navigate to the Form Settings tab > Emails & Actions > Advance Settings > Add Webhook; alternatively, you can edit an existing one.  Choose the " Send Data to an External URL (WebHook)" Action option and enter your WebHook URL in the designated URL Address field.


Using unique field identifiers

Post using field names (default)

If you select this option when using webhooks, ensure the form has only ONE usage of each field. If you have multiple uses of one field type, for instance, 'short answer', 'name' or 'email', then only the last occurrence of the field will be sent in the webhook.
Post using field IDs
Please be aware that the 'field key' is a number and not a human-readable text value.
Post with API-friendly field keys
When utilizing this option, you must use unique labels for each of your fields. If you have multiple fields with the same label, regardless of the field type, then only the last occurrence of the label will be sent over.
Example: You have two Name fields on a form and they are both labeled ‘Full Name:’. For both the `Post using field names (default)` and `Post with API-friendly field keys` options, only the second occurrence will be passed via the webhook. Say ‘Jane Doe’ is entered in the first name field and ‘John Doe’ is entered in the second, only one name will be passed via the webhook and that value would be ‘John Doe’.


Optional WebHook Settings

"WebHook Name"

This allows you to give your WebHook a name to easily identify them if you're setting up multiple on a single form. 


"Post using field IDs instead of field names"

Selecting this checkbox will replace the field labels on your Form with the Field IDs in the data that is passed to your endpoint.


"Post with sub-field names"

Selecting this option will pass the submitted data to your endpoint with sub-field names. Example: for a Name field instead of "Name: Jane Smith" it would look like " Name: first = Jane last = Smith"


"Post with field type"

Selecting this option will pass the field type along with the data submitted for each field. Example: a Name Field's data may appear like: "Name: first = Jane last = Smith field_type = name"


Content Type

This option allows you to choose between URL Encoded Form Data, or JSON, depending on what your needs are for the endpoint you are targeting with your Webhook data from your Form.


Optionally, you may choose to enter a WebHook Shared Secret or an HMAC Key.  These are additional values you can send to your WebHook endpoint which verifies that the data is from a trusted source if your endpoint requires this.


Just like all redirects, you can apply Routing Logic to your WebHook to filter which submissions are sent to the WebHook based on how the Form is answered.  To add Routing Logic to your WebHook, simply click the "Routing Logic" link and create the routing filter.


If your endpoint is not receiving data when your Form is submitted, here are a few things to check:

  • Find out if your endpoint requires a Shared Secret to be entered into the settings. You may need to reach out to Server Administrators or Support for whatever service you are sending the data to.
  • Check to see if your endpoint is capable of accepting either URL Encoded Form Data or JSON and ensure that the proper option is selected in the WebHook Settings
  • See if it's possible to whitelist our IP Addresses for these outgoing communications:
  • Check status.formstack.com to see if there are any service interruptions with WebHooks
  • Find our Developer documentation at https://developers.formstack.com/v2.0/docs/webhook-setup

If you are still not receiving data to your endpoint upon Form Submission, either the data is not formatted in a way that can be accepted by your endpoint, or your endpoint is not configured to receive HTTP Requests.

Was this article helpful?
7 out of 15 found this helpful