Webhooks are HTTP-defined call-back functions that notify apps/websites in case of any event on the app they are linked with. We use webhooks to connect two apps/websites. Whenever you pay online via card and get notified via SMS of your transaction, the medium between your bank and SIM company is a configured webhook.
Say you have an online website selling clothes and you’d like to connect it to a payment gateway [e.g Stripe] so that whenever a purchase is made and paid via Stripe, you get notified. Webhooks will act as a messenger, giving you automatic updates in case of any transactions.
To set up webhooks in SubscriptionFlow, follow these steps:
- Access Administration Settings: Start by navigating to the Administration Settings. You can do this by clicking the gear icon on the navigation bar to open the Administration Settings menu.
- Go to Webhooks: In the Administration Settings, locate the "Automation" section, and under that, select "Webhooks."
- Configure Webhook: Click on the "Configure Webhook" option to begin the setup process.
Webhook configure page will be open, as shown below.
- Webhook Name and URL:
- Webhook Name: Choose a name for your webhook. This name will be used to refer to the webhook within your SubscriptionFlow instance.
- Webhook URL: Specify the URL to which your SubscriptionFlow instance should send webhook notifications.
- Webhook Module, Event, and Description:
-
- Webhook Module: Use the dropdown menu to select the SubscriptionFlow module associated with the event you want to trigger.
- Webhook Event: Select the specific event from the available options that you want to trigger within the selected module.
- Description (optional): Optionally, provide a brief description of the webhook for reference.
- Webhook Payload Type and Method:
- Webhook Payload Type: Choose the payload type
- Custom: If you select the custom payload type, you can define the request type and data to be sent via the "entity" or custom parameters fields.
- Default: Selecting default payload type means the request will be sent as a POST, and the default API response for that event will be sent.
- Webhook Payload Type: Choose the payload type
- Webhook Method: Define the HTTP request method (GET/POST) used for sending data from your SubscriptionFlow instance to the provided URL.
- Webhook URL Parameters:
- Webhook URL Parameters: Specify the data to be sent with the webhook request. Two types of parameters can be added:
- Entity Parameters: Send fields associated with the selected module as query parameters (for GET requests) or as form data (for POST requests).
- Custom Parameters: Define custom parameters as needed for your webhook request.
- Webhook URL Parameters: Specify the data to be sent with the webhook request. Two types of parameters can be added:
- Webhook Preview URL: You can preview the final webhook URL in the "Preview URL" section to ensure it's correctly configured.
These steps will guide you through the process of setting up a webhook in SubscriptionFlow. Be sure to review and confirm your webhook settings before saving to ensure they match your desired configuration.
Comments
0 comments
Please sign in to leave a comment.