Skip to main content

Create your first AI agent

Workflow preview

Workflow preview
100%
Create your first AI agent preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Who is this for? This workflow is designed for anyone who wants to automate AI driven chat responses integrated with Google Docs and Google Sheets, using the Google Gemini (PaLM) language model via...

Best for

  • Support Chatbot automation workflows
  • AI Chatbot automation workflows
  • intermediate n8n builders looking for reusable templates

Tools used

@n8n/n8n-nodes-langchain.agent, n8n-nodes-base.stickynote, @n8n/n8n-nodes-langchain.googlegeminitool, n8n-nodes-base.googledocstool, n8n-nodes-base.httprequesttool, @n8n/n8n-nodes-langchain.lmchatgooglegemini, @n8n/n8n-nodes-langchain.chattrigger

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by DevCode Journey.

Original n8n.io source

1.1 Workflow description

Title
Create your first AI agent
Workflow name
Create your first AI agent

Who is this for?

This workflow is designed for anyone who wants to automate AI-driven chat responses integrated with Google Docs and Google Sheets, using the Google Gemini (PaLM) language model via n8n. It’s perfect for teams looking to:

  • Automatically generate AI replies to chat messages,
  • Pull content dynamically from Google Docs,

What this Workflow Does

  • Receives chat messages via a webhook trigger.
  • Sends the chat input to the Google Gemini AI Chat Model for generating replies.
  • Optionally retrieves a document from Google Docs if a URL or ID is provided.
  • Uses an AI agent node to coordinate between the AI model and tools like Google Docs.

Key Features

  • Integration with Google Gemini (PaLM) AI for natural language understanding and response generation.
  • Ability to fetch and use data from Google Docs dynamically.
  • Modular structure using n8n nodes for flexibility and easy customization.
  • Credential management for Google APIs (Docs, Gemini) via n8n’s built-in credential system.

Get Your Google AI API Key

  1. Visit Google AI Studio.
  2. Click "Create API key in new project".
  3. Copy the API key that appears.

Add Your Credential in n8n

  1. On the workflow canvas, go to the Connect your model (Google Gemini) node.
  2. Click the Credential dropdown and select + Create New Credential.
  3. Paste your API key into the API Key field.
  4. Click Save.

Start Chatting!

  1. Go to the Example Chat node.
  2. Click the "Open Chat" button in its parameter panel.
  3. Try asking it one of the example questions:
    • "What's your name?"
    • "What time now in bangladesh?"
    • "What's the weather in bangladesh?"

You're now ready to chat with your personal AI agent powered by Google Gemini! πŸŽ‰

Requirements

  • n8n instance with internet access.
  • Google Cloud account with:
    • Access to PaLM API (Google Gemini).
  • Proper OAuth2 credentials configured in n8n for Google APIs.

πŸ™‹ For Help & Community

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - AI Agent

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.1

Block 2 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 3 - Gemini

Type / Role
@n8n/n8n-nodes-langchain.googleGeminiTool - googleGeminiTool
Config choices
Version 1

Block 4 - Docs

Type / Role
n8n-nodes-base.googleDocsTool - googleDocsTool
Config choices
Version 2

Block 5 - Request

Type / Role
n8n-nodes-base.httpRequestTool - httpRequestTool
Config choices
Version 4.2

Block 6 - Gemini Chat

Type / Role
@n8n/n8n-nodes-langchain.lmChatGoogleGemini - lmChatGoogleGemini
Config choices
Version 1

Block 7 - Chat message

Type / Role
@n8n/n8n-nodes-langchain.chatTrigger - chatTrigger
Config choices
Version 1.1

Block 8 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 9 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 10 - Sticky Note12

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 11 - Sticky Note13

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Create your first AI agent
Complexity intermediate
Nodes 11
Categories Support Chatbot, AI Chatbot
Author DevCode Journey
Published 06 Oct 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/9311/9311.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Create your first AI agent do?

Who is this for? This workflow is designed for anyone who wants to automate AI driven chat responses integrated with Google Docs and Google Sheets, using the Google Gemini (PaLM) language model via...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Support Chatbot, AI Chatbot use case.