Hi, I’m trying to figure out how to set up a webhook working with my Forminator form. I’m using this code in my functions.php to overwrite the zapier one but it doesn’t seem to work:
add_filter('forminator_addon_zapier_endpoint', function($endpoint, $form_id, $connection_settings) {
if (0 !== $form_id && $form_id = 1234) { // 1234 = id of form to aplly it to
$endpoint = wp_http_validate_url( 'https://hooks.airtable.com/' );
}
return $endpoint;
}, 10, 3);
add_filter('forminator_addon_zapier_sample_data', function($sample_data, $form_id, $submitted_data) {
$webhookURL = 'https://hooks.airtable.com/';
if (0 !== $form_id && $form_id = 1234) { // 1234 = id of form to aplly it to
$sample_data['webhook_url'] = wp_http_validate_url( $webhookURL );
}
return $sample_data;
}, 10, 3);