1. Create a New Flow
Go to Flow Builder and click Create
Flow to create the flow for your WhatsApp Chatbot.
2. Select API Request from the Content Block
3. API Request Configuration
Follow the below steps to configure API Requests:
1. URL
Specify the URL of the API endpoint you want to communicate with. This URL should resemble the one used in Postman.
2. Request Type
Select the appropriate request type from the available options: GET, POST, PUT, PATCH, or DELETE.
3. Parameters
Users can either provide static values for the parameters or select attributes to dynamically share information within the flow.
4. Headers
Include any necessary headers for your API request. Headers provide additional information about the request, such as authentication credentials or content type.
5. JSON Raw Data
If required, you can send JSON raw data as part of the request body. Users can pass attribute values within the JSON object using the $ sign followed by the attribute name.
6. Test the API
Once you have configured the API request, you can click on the "Test" button to send the request and verify its functionality. This will simulate the actual API call and provide you with the response.
7. Capture Response Data
After a successful API response, you have the option to capture specific data from the response and save it as attribute values. This allows you to store and use the retrieved data within your flow for further processing.
8. Save the Request
If you are satisfied with the configured API request, you can click on the "Save" button to store the request for future use. This ensures that your request settings are preserved and can be easily accessed when needed.