Skip to main content

Webhook Action in Stack Workflows

Overview

The Webhook action in Stack allows you to seamlessly send data to external systems using HTTP POST requests. This feature is ideal for integrating with third-party applications, automating data transfers, or triggering events in other platforms based on specific workflow conditions. For instance, you can use this action to send form submissions to another platform.

Action Name

Webhook

Action Description

The Webhook action enables you to send an HTTP POST or GET request to a specified URL, facilitating data transfer to an external application or service. This action is versatile, allowing you to trigger automations in third-party systems, update external databases, or send data to custom APIs, thereby enhancing the integration capabilities of your workflows.

Action Details

Step-by-Step Guide

  1. Choose the Action Type:

    • Select Webhook from the list of available actions in the workflow builder.
  2. Name Your Action:

    • Enter a descriptive name for the action, such as "Send Contact Info to External CRM."
  3. Enter the Webhook URL:

    • Provide the URL of the external application where the data should be sent. This is typically an endpoint URL provided by systems like CRMs, email marketing tools, or other APIs.
  4. Configure Payload:

    • Define the data to be sent through the webhook using JSON format. Utilize merge fields to dynamically include information like contact details, opportunity status, or custom fields. Example:
      {
      "first_name": "`{{contact.first_name}}`",
      "last_name": "`{{contact.last_name}}`",
      "email": "`{{contact.email}}`",
      "phone": "`{{contact.phone}}`",
      "status": "`{{contact.status}}`"
      }
  5. Add Headers (Optional):

    • If the external system requires authentication or specific headers, add them here. For example, you might need to include an API key or content-type header:
      Authorization: Bearer <API_KEY>
      Content-Type: application/json
  6. Add Custom Data (Optional):

    • If needed, send custom data by adding key-value pairs in the action, such as:
      • Key: Addr
      • Value: Address from the value picker
  7. Test Webhook (Optional):

    • Before finalizing, use testing tools like Webhook.site or Postman to ensure the data is correctly sent to the external system.

Example

Scenario

You want to sync contact data with an external CRM whenever a new contact is created.

  1. Create Workflow Trigger:

    • Set up a workflow trigger to initiate when a new contact is created.
  2. Add Webhook Action:

    • Select the Webhook action and name it "Sync Contact with CRM."
  3. Enter Webhook URL:

    • Provide the CRM’s API endpoint for contact updates, e.g., https://api.externaltestcrm.com/contacts/create.
  4. Configure Payload:

    • Define the contact details to be sent in JSON format:
      {
      "first_name": "`{{contact.first_name}}`",
      "last_name": "`{{contact.last_name}}`",
      "email": "`{{contact.email}}`",
      "phone": "`{{contact.phone}}`"
      }
  5. Add Headers:

    • Include any necessary authentication details:
      Authorization: Bearer abc123xyz
      Content-Type: application/json
  6. Save and Activate the Workflow:

    • Once the workflow is active, every time a new contact is created, their details will automatically be sent to the external CRM.