Skip to main content
Community template Uses AIPersonal ProductivityAI Chatbot

Build your first AI agent - n8n workflow template

This template launches your very first AI Agent —an AI-powered chatbot that can do more than just talk— it can take action using tools. Think of an AI Agent as a smart assistant, and the tools are the apps on its phone. By connecting it to other nodes, you give your agent the…

Template by Lucas Peyrin · Original listing (opens in a new tab)

Starts on
Chat message
Nodes
6 nodes
Level
Beginner
Setup
About 11 min

Workflow preview

How this workflow runs

  1. 1

    Example Chat

    Starts the workflow when a chat message is received through the chat interface.

  2. 2

    Get News

    A tool the AI agent can call to work with Rss Feed Read.

  3. 3

    Get Weather

    A tool the AI agent can call to work with HTTP Request.

  4. 4

    Conversation Memory

    Gives the AI short-term conversational memory of recent messages.

  5. 5

    Connect Gemini

    Provides Google Gemini as the chat model for the AI steps.

  6. 6

    Your First AI Agent

    The AI agent that orchestrates the workflow — it reasons over the input and decides which tools to call.

Creator's notes and setup

Written by Lucas Peyrin for the original listing.

How it works

This template launches your very first AI Agent —an AI-powered chatbot that can do more than just talk— it can take action using tools.

Think of an AI Agent as a smart assistant, and the tools are the apps on its phone. By connecting it to other nodes, you give your agent the ability to interact with real-world data and services, like checking the weather, fetching news, or even sending emails on your behalf.

This workflow is designed to be the perfect starting point:

  • The Chat Interface: A Chat Trigger node provides a simple, clean interface for you to talk to your agent.
  • The Brains: The AI Agent node receives your messages, intelligently decides which tool to use (if any), and formulates a helpful response. Its personality and instructions are fully customizable in the "System Message".
  • The Language Model: It uses Google Gemini to power its reasoning and conversation skills.
  • The Tools: It comes pre-equipped with two tools to demonstrate its capabilities:
    1. Get Weather: Fetches real-time weather forecasts.
    2. Get News: Reads any RSS feed to get the latest headlines.
  • The Memory: A Conversation Memory node allows the agent to remember the last few messages, enabling natural, follow-up conversations.

Set up steps

Setup time: ~2 minutes

You only need one thing to get started: a free Google AI API key.

  1. Get Your Google AI API Key:

  2. Add Your Credential in n8n:

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

    • Go to the Example Chat node.
    • Click the "Open Chat" button in its parameter panel.
    • Try asking it one of the example questions, like: "What's the weather in Paris?" or "Get me the latest tech news."

That's it! You now have a fully functional AI Agent. Try adding more tools (like Gmail or Google Calendar) to make it even more powerful.

n8n nodes used (4 types)

What every node does (6)
  • Get News (Rss Feed Read Tool)A tool the AI agent can call to work with Rss Feed Read.
  • Get Weather (HTTP Request Tool)A tool the AI agent can call to work with HTTP Request.
  • Your First AI Agent (Agent)The AI agent that orchestrates the workflow — it reasons over the input and decides which tools to call.
  • Example Chat (Chat Trigger)Starts the workflow when a chat message is received through the chat interface.
  • Conversation Memory (Memory Buffer Window)Gives the AI short-term conversational memory of recent messages.
  • Connect Gemini (LLM Chat Google Gemini)Provides Google Gemini as the chat model for the AI steps.

FAQ

Build your first AI agent: questions

How do I import the "Build your first AI agent" workflow into n8n?

Copy the workflow JSON from this page, open the n8n editor, click on an empty canvas and paste with Ctrl+V (Cmd+V on macOS). You can also download the .json file and choose Import from File in the workflow menu. Save the workflow, then attach credentials before activating it.

Which nodes and credentials does "Build your first AI agent" use?

It uses Agent, Memory Buffer Window, Chat Trigger and LLM Chat Google Gemini. Any node that connects to an external service needs your own credential — open each node after import and select or create one. Trigger, logic and transformation nodes usually need no credentials.

Can it run on n8n Cloud and on self-hosted n8n?

The workflow format is the same on both. If a node appears as unknown or outdated after import, update n8n to a recent version or, on self-hosted instances, install the required community node package. Features such as $env access are available on self-hosted instances only.

How can I customise "Build your first AI agent"?

Start by changing the trigger (schedule, webhook or app event) and the destination nodes to match your stack — it is listed under Personal Productivity, AI Chatbot. Edit prompts, field mappings and filters in the relevant nodes, use expressions like {{ $json.field }} to map data, and test with a manual execution before activating.

n8n is a trademark of n8n GmbH. AltFTool is not affiliated with, endorsed by or sponsored by n8n. Community templates are credited to their creators and link to the original listing; AltFTool originals are written and tested by the AltFTool team.

About this page

Free n8n workflow templates to copy and import

The AltFTool n8n library collects free n8n workflow templates for AI agents, Gmail, Google Sheets, Telegram and other apps. Each workflow page shows a preview, the list of nodes and the credentials it needs, and lets you copy or download the JSON to import into your own n8n.

Search the templates by app or task, or browse them by category and by node. The Workflow Inspector checks any workflow JSON for triggers, credentials and hardcoded keys before you share it, and the expressions cheat sheet gives copy-paste n8n expression examples. AltFTool is not affiliated with n8n.

People also search for

  • n8n workflow templates
  • n8n templates
  • n8n automation examples
  • n8n json workflows
  • n8n nodes
  • free n8n workflow templates
  • n8n ai agent template
  • n8n expressions cheat sheet