How to Use Webhooks in Otter Forms?

๐Ÿ“ Note: This article presents specific settings of the Otter Forms, and it is a premium feature that you can get from here.

The Otter Forms creates a wide palette of use cases, including the  communication between form submissions and an external given URL (application). For example, after submitting the form, an SMS, email, or message can be sent to specific applications using this Webhook service.

Webhook Editor

To enable the Webhook, open Form settings, click on the three dots, and select Webhook.

After this, you will be able to select existing Webhooks, edit them, or create new ones:

When you try to create a new Webhook, the  modal from the above screenshot appears. Here are the available options:

  • Webhook Name - as suggested, insert the name of the application where the data goes.
  • URL - insert the URL that will be used in the Webhook request. where the data is sent.
  • Method - select from the dropdown the method that best suits your needs (POST/GET/PUT).
  • Headers - allows you to specify HTTP headers to be sent along with the request.

Connect with Zapier

๐Ÿ“ Note: The steps presented in this doc are available after you create a Zapier account. The necessary trigger requires the Zapier Pro version. 

In this example, we will establish a connection between the form submissions and our Slack workspace so that any time an answer is submitted, a Slack message will appear.


Create/Log into your Zapier account.


On the Webhook Integrations page, search for the external app (e.g. Slack).


In the Choose a Trigger dropdown, select Catch Hook.


In the Choose an Action dropdown, select the desired output (e.g. Send Channel Message).


After this, click on the Connect My Apps button.


Once the editor opens, click on the Trigger field.


Expand the Test accordion, and you will see your webhook URL.


Click on the Copy button.

Now that you are connected to Zapier, it's time to attach it to Otter Forms. Go back to the page where you added the form and click on the Edit Webhooks button.


Insert a suitable name, then paste the copied URL from the above step.


Pick POST as the method and save the changes.

The last part is to  test the connection. This can be done by submitting your answer to the form, then going back to the Zapier interface. From the accordion where you copied the URL, click on Test Trigger. Once a submission is made, you will do something similar:


Then click on the  action field to edit the action. You can select data from the form submission to be sent on the external app (Slack).


In the Test accordion, click on the Test action button.


Connect with IFTTT

Similar to the connection with Zapier, we will demonstrate a connection with IFTTT. In our case, every time the form is submitted, we will get an email on Gmail.


Once you get on the IFTTT page, click on the Connect button.


After you're redirected to the below window, click on the Add button next to If This.


In the search field, type Webhooks and select the appropriate service.


As a trigger, select Receive a web request with a JSON payload.


In the new window, set the event name and click on Create trigger.


Save the changes and get back to the Create tab (from step 2).


Click on the Add button, next to the Then That field.


Search for the desired  output service (e.g. Gmail).


Choose the preferred action (e.g. Send yourself an email).


In the configuration modal, edit the  subject and body of the email, to recognize it easier.

When everything is done, the editor should look like this:


Click on the Continue button, and you will be redirected to the below window:


After this, navigate to this page and click on the Documentation button.

In the first code area, you will find an URL of this type:{event}/json/with/key/AjdeTuqvKTHtbInv4xa8u3(...)

Replace the {event} with your event's name (in our case: submitted_form).

Copy the code and  navigate to the website page where you added the Form block.


Open the Webhook editor and create a new one.


Insert a suitable name, then paste the URL and select POST as a method.


Save the changes and submit an answer as a test.


Mapped Name

As you can see, the data might not necessarily look very friendly. This is because the data is prepared in a payload, having the structure key: value. The value represents the data collected from the form (e.g. andreea). and the key represents the label of the form field. To make things clearer, each field has a Mapped Name, which will replace the key in the payload.

Mapped Name in the Editor

Mapped Names in the Email

Change payload data with PHP Hooks

PHP enables users to modify the payload data that will be sent to the webhook.


To do this, copy the code below.

	 * Add extra data to the payload that marks the IFTTT webhook provider.
	 * @param mixed $payload The payload.
	 * @param Form_Data_Request $form_data The form data.
	 * @param mixed $webhook The webhook.
	 * @return mixed
	function mark_ifttt_provider( $payload, $form_data, $webhook ) {
		if ( str_contains( $webhook['url'], '' ) ) {
			$payload['webhook_provider'] = 'ifttt';

		return $payload;

        add_filter( 'otter_form_webhook_payload', 'mark_ifttt_provider', 10, 3 );

Make the desired changes and paste the code into the currently active theme  functions.php file or using Code Snippets.

๐Ÿ“ Note: If you paste the code snippet into the plugin's source file, the changes will be lost when you update the plugin. The same thing may happen when you update the theme, this is why we recommend using a child theme.

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us