Hello, I would like to know more about the use of the function API Request. This seems very powerful, and might be the perfect solution for a use case I cant solve.
Basically, some of my users wants to use the bot to make orders or to check prices. I thought I could use the “Google Sheet” content for structured data, but it often makes mistakes and mixes prices and information.
I would like to use the API function, to send an API request to a system that will programmatically retrieve the information and pass it to the agent. My questions are:
- How can I make the body of the API request to dynamically send information based on the conversation? For example, if the function triggers when the user asks prices, I would like to send the previous messages of the users in the body of the API request, as then I will process it to parse the product and request
- How can I then feed the agent with the response from the API request?
- Is there another way to achieve my use case, or would this work at all?
Thank you, Juan