Back to Templates

Handle chat support and escalate unresolved tickets with Google Gemini and Gmail

Created by

Created by: M S Vishnu || vishnu
M S Vishnu

Last update

Last update 4 days ago

Categories

Share


Quick overview

This webhook-based customer support workflow uses Google Gemini and a Google Docs knowledge base to answer chat messages, remembers conversation context, and escalates unresolved issues by summarizing the chat and sending a support email via Gmail.

How it works

  1. Receives an incoming chat message via a webhook request.
  2. Uses a Google Gemini-powered support agent with a Google Docs knowledge base and short-term memory to draft a user reply and decide whether escalation is needed.
  3. Returns the agent’s reply to the chat client as a JSON webhook response.
  4. If the agent flags the conversation for escalation, summarizes the chat with Google Gemini and formats an email subject and body.
  5. Sends the escalation email through Gmail to the configured support address and responds to the user with a confirmation message.

Setup

  1. Copy the webhook URL from the trigger and configure your chat app or frontend to POST messages (including a sessionId) to it.
  2. Add Google Gemini (PaLM) API credentials for the Google Gemini chat model nodes.
  3. Add Google Docs OAuth credentials and point the Google Docs tool to the document you want to use as the support knowledge base.
  4. Add Gmail OAuth2 credentials and replace [email protected] with your real escalation inbox in the Gmail send step.
  5. Ensure your client sends the expected fields (for example body.message and body.sessionId) so memory and replies work correctly.