Skip to main content

I’m trying to create a chatbot for an ecommerce website that is capable of checking live price and stock data. I can provide the price & stock data as a CSV or JSON file, or have it stored in a Zapier Table that is refreshed hourly.

My primary issue is that the most frequent you can update knowledge sources is daily, so theoretically data provided to the bot that way could be almost 24 hours out of date. I therefore want to have the bot fetch the data when prompted by the user (e.g. “Is product x in stock?”)

Is there any way to do that? I thought maybe give the user a Zap Button to check stock, but I can’t feasibly see how to pass the item the user is interested in from the chat content into the Zap (e.g. the lookup value for a Zapier Tables action).

If you could trigger a prompt as Logic, that would be ideal, e.g. “If the user asks if an item is in stock or what the price is, do a lookup for the product in the products table to see if it is in stock”.

Any ideas welcome! 😀

Hi ​@Ian Lockwood 

Have you explored using the Zapier Chatbot Zap app?

Triggers/Actions: https://zapier.com/apps/zapier-chatbots/integrations#triggers-and-actions

 

You may need to then add one of these Zap steps to isolate the lookup value:

  • AI by Zapier - Analyze and Return Data
  • Code
  • Formatter 

 

 


Thanks Troy, I hadn’t spotted the AI by Zapier functions, I think that’s the missing piece of the jigsaw if this is going to work at all. 🙂