How to use AVflow with Zapier
AVflow and Zapier flow together nicely. :) And together they create a really powerful combo!
Imagine you have a workflow where you captured data in the frontend with Zapier which then triggers AVflow and uses part of that captured data in the Flow.
Here is how you can use a Zap in Zapier to trigger a Flow in AVflow.io
In this example we will guide you to create a sample Zap that can receive JSON data from a POST request; then Zapier will trigger AVflow's Flow.
1. Create a Zap that can accept POST request and JSON data
Create a Zap.
Select Webhooks By Zapier
Select Catch Raw Hook as Trigger Event
Copy the Webhook URL and save it somewhere to yse for later. Select Continue
2. Test the Zap with sample data (Using POSTMAN)
Create POST request to Zapier flow: Use POST method with the Webhook URL that we copied before in Zapier Trigger setup
Config the Body to send to Zapier endpoint:
- Set data payload type to raw and JSON format
Paste the payload to body
Below is the sample pay payload:
Now go back to Zapier and Select Test trigger
Now we can see that the Zap received the request from POSTMAN with data:
3. Setup AVflow flow that can be triggered via POST request (using webhook trigger)
Create a Flow (in this example it is named "avflowEndpoint") in an AVflow.io workspace
Drag the Webhook Trigger to the Flow. This trigger will allow Zap trigger this flow via HTTP request
Set Action to HTTP POST to enable triggering the flow via HTTP POST request.
Specify the Webhook output data.
which mean the incoming data will have structure as below:
Copy the Webhook Endpoint and keep it somewhere else for later use. We will need this endpoint to setup the Zapier webhook.
Go to TABLE, select the default table / or create a new table
Add a Log column to store data to be received from the webhook trigger:
Go back to the Flow and add the Table step and setup configuration to store the data from webhook to just the table column you just created.
Set Action to Insert, which means this step will insert row to a table
Select Setup Table Options
Setup Table Option, specify which table and column the data to be saved to.
4. Add the Zapier webhook to the Zap to trigger AVflow's Flow
Click on the box to add more actions to the existing Zap
Search and select Webhook By Zapier. We will use this action to trigger the AVflow
Set Action Event to Custom Request then select Continue
Set Method to POST
Set URL to the AVflow Webhook Trigger's endpoint that we saved before
Set Payload Type to Raw Body
Set Wrap Request In Array to No, Leave File blank. That means we reserve the structure of JSON and don't send any file to AVflow
Set Data Pass-Through? to False, which means we will forward the data from previous action to the target endpoint
Set Unflattern to No
Leave Basic Auth blank, because AVflow use "apiKey" key value to do authentication as below
Include AVflow apiKey in request header
--> To find the the AVflow apiKey, go to AVflow and load your profile page by clicking on your name at the bottom left. See here for more info.
Select Test & Continue to test the Zap with the new action
Zapier will show the result as below:
4. Turn on both Zap and AVflow flow then use POSTMAN to send the test request again
Check the Zapier log as below to see the result.