Engati - User Guide
Engati APIs
API Trigger V2
8min
1 introduction 1 introduction forward integrations would allow you to create an automation flow in your chatbot that can be triggered by an api without the need of an end user ever interacting with your chatbot you can create a form asking for information from clients and pass them into the api via params into attributes and use them to perform functions based on the input and accomplish the goals note this feature is only for whatsapp channel 2 availability 2 availability forward integrations are available in our enterprise plans based on an entitlement, please reach out to info\@engati com for assistance 3 working mechanism 3 working mechanism when a user would enter information in a form and the api is triggered in which the user inputs are passed as attributes via params then the flow will be executed, as an example in the below form my users would be entering the information and based on their category i would be generating and storing information in salesforce and send out emails 4 functioning 4 functioning 4 1 instructions for using api v2 method post post request url https //api engati com/bot api/v2 0/customer/\<cid>/bot/\<bot key>/flow/\<flow key> https //api engati com/bot api/v2 0/customer/\<cid>/bot/\<bot key>/flow/\<flow key> headers authorization basic \<api key> authorization basic \<api key> content type application/json for whatsapp, if in any case, the user's name is not present with its phone number then the 'user user name' attribute will capture and store its phone number cid – customer identifier will be available in the 'integrations' tab > engati api bot key – the bot key will be available in the 'integrations' tab > engati api api key – a key available in the 'integrations' tab > engati api that would be used for authentication purposes flow key – the key of the flow which you would like to have initiated when the api request is made you can access it by clicking on the " i " (path info) icon present at the top of the respective path 4 2 passing the attributes to the bot when the api will be triggered the attribute data will be passed through the api into the flow and this flow will be executed these attributes can be configured in the request body of api 4 3 api trigger v2 curl please find below the entire curl for the version 2 of api trigger curl location 'https //api engati com/bot api/v2 0/customer/\<cid>/bot/\<bot key>/flow/\<flow key>' \\ \ header 'authorization basic \<api key>' \\ \ header 'content type application/json' \\ \ data '{ "user channel" "whatsapp", "user phone no" \<to number>, "attribute 1" "this is parameter 1", "attribute 2" "this is parameter 2" }' in case of issues please reach out to support\@engati com