Latenode

Automate Telegram customer support with GPT-4 and Google Docs

This template starts when your Telegram bot receives a message, loads a Google Docs knowledge base, and asks ChatGPT for a reply.

Telegram sends that answer back to the user. Connect Telegram and Google Docs. Put the bot token on the Telegram connection. ChatGPT is a Latenode AI step.

Updated Sep 16, 2026Est. run: 20sEst. cost: $0.0012
How Latenode estimates time and cost

Latenode bills workflow runtime in CPU seconds. The first 10,000 CPU seconds are free each month, then usage follows pay-as-you-go CPU-second pricing. Plug-and-Play (PnP) AI nodes are billed separately—each PnP token is $1 USD, charged pay-as-you-go at vendor cost plus a small processing fee, with no API keys required.

Full pricing — how CPU seconds work →

Workflow preview

What this template does

  • Answers Telegram messages from a Google Doc
  • Writes the reply with ChatGPT
  • Sends the answer back in the same chat
  • Keeps the bot token on the Telegram connection

How it works

1
Trigger

Catch the Telegram message

The scenario starts when someone writes to the Telegram bot you connect.

2
Action

Load the knowledge base

Google Docs reads the knowledge document. JavaScript combines that text with the user message.

3
AI

Write the reply

ChatGPT returns an answer grounded in the Doc. You do not paste an OpenAI key.

4
Action

Reply in Telegram

Telegram sends the ChatGPT answer back to the same chat.

Setup guide

1

Connect Telegram

Add a Telegram connection and paste your bot token there. Add a trigger for new updates on that bot.

2

Connect Google Docs

Add a Google Docs connection and point it at the document that should ground the answers.

3

Wire ChatGPT and the reply

Load the Doc, build the prompt in JavaScript, then send it to ChatGPT. ChatGPT is a Latenode AI step. Map the answer onto a Telegram text reply. Send a test message to the bot and confirm the response.

Requirements

A Telegram bot token stored on the Telegram connection
A Google Doc Latenode can read as the knowledge base
ChatGPT available as a Latenode AI step

FAQ

Common questions about this template

Each run uses credits on your Latenode plan. We charge for processing time (1 credit = 30 seconds). Your actual cost depends on your plan and how long the run takes. See pricing plans for plans and how credits work. Plug-and-Play AI nodes are billed separately.