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
- Receives an incoming chat message via a webhook request.
- 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.
- Returns the agent’s reply to the chat client as a JSON webhook response.
- If the agent flags the conversation for escalation, summarizes the chat with Google Gemini and formats an email subject and body.
- Sends the escalation email through Gmail to the configured support address and responds to the user with a confirmation message.
Setup
- Copy the webhook URL from the trigger and configure your chat app or frontend to POST messages (including a sessionId) to it.
- Add Google Gemini (PaLM) API credentials for the Google Gemini chat model nodes.
- Add Google Docs OAuth credentials and point the Google Docs tool to the document you want to use as the support knowledge base.
- Add Gmail OAuth2 credentials and replace
[email protected] with your real escalation inbox in the Gmail send step.
- Ensure your client sends the expected fields (for example
body.message and body.sessionId) so memory and replies work correctly.