- Home
- Integrations
- Telegram
- Telegram + OpenAI (ChatGPT)
ChatGPT Telegram bot without code: replies from OpenAI
You can build a ChatGPT Telegram bot without code in nana800 from three blocks: a trigger catches the message, the OpenAI block writes a reply, and the send block returns it to the chat. You need a bot token from @BotFather and your own OpenAI API key, with no server and no code. The message and the reply cost as much as basic blocks, the OpenAI request twice as much, and OpenAI bills the tokens to your account.
Build it in the builderWhat you can automate
- Answer common customer questions about prices, delivery and opening hours, with the facts and rules written in the system instruction
- Describe a photo sent to the bot: in IMAGE_ANALYSIS mode the model gets the photo link from the Telegram trigger
- Split a free-form request into name, phone and topic with the json_object response format and pass the fields to the next blocks
- Translate, shorten and proofread texts your team sends to the bot
- Answer voice messages: the Speech to text block turns the recording into text with the same OpenAI key first
How to set it up
- 1
Create the bot and the OpenAI key
Send /newbot to @BotFather and copy the bot token that looks like 123456789:AAH... Then open API keys in your OpenAI account, press Create new secret key and copy the key that starts with sk-... Your OpenAI account needs a positive balance, otherwise the model will not answer.
- 2
Add the incoming message trigger
Create a scheme in the builder and add the Telegram message from user to bot trigger. Paste the bot token and choose message as the event type, so the bot answers messages and ignores button presses.
- 3
Set up the Open AI request block
Add the Open AI request block, keep TEXT_COMPLETION as the operation and paste your key. In the system instruction describe the role and rules, for example "You are a shop assistant, keep answers short". In the prompt field insert the message text from the trigger.
- 4
Send the answer back
Add the Telegram message send block with the same token. Put chat_id from the trigger into the chat ID field and text_response from the OpenAI block into the message text. Pick the plain_text format so asterisks or brackets in the model answer do not break the message.
- 5
Test it with the button trigger
Connect the button trigger to the OpenAI block, temporarily type a test question into the prompt and your own ID from @getmyid_bot into the chat ID field. Turn the scheme on and press the button: the answer arrives in Telegram. If it does not, error_text of the OpenAI block shows why, for example a wrong key.
- 6
Keep the scheme on
Put the trigger data back into the fields, keep the scheme on and message the bot yourself. Every new message now starts the scheme. While the scheme is on, it costs $0.0042 per hour.
Pricing
A run of a Telegram block costs $0.001, a run of a OpenAI (ChatGPT) block costs $0.002. Every month the balance is topped up to $3.50 for free, an enabled scheme costs $0.0042 per hour.
Services in this connection
- Telegram
Build a Telegram bot without code: reply to messages, add buttons, send leads and alerts to a chat, group or channel. Free balance every month, no card needed.
- OpenAI (ChatGPT)
Use the ChatGPT API without code: reply to leads, summarize emails, read photos, get JSON for tables and generate images. Your OpenAI key, free balance every month.
Frequently asked questions
Build your first scheme for free
Sign-up is free and needs no card. Every month the balance is topped up to $3.50 for free, enough for about 3,500 runs of basic blocks.
Build it in the builder