Connect Telegram: bots, and your own account for the agent
Bots for people, and your own account for the agent. Nobody asks you for tokens or codes: they live in Keychain.
Hedoq has two separate ways into Telegram:
- Bots. For clients, your team, reports. They do not need your account.
- Your account. Needed to create bots through BotFather, and to let the agent read your chats and write as you.
Step by step: connect your account
- Gear, “Servers and keys” block, “Telegram bots”.
- Click “Connect account” and follow the steps.
- Hedoq installs the Telegram component.
- Enter your Telegram app keys.
- Enter your phone number and the code Telegram sent you. If two-step verification is on, also your password.
- Done: “Signed in”.
Step by step: bots
- In “Telegram bots”, click “Import my bots from BotFather” to bring in bots you already have.
- New bot: type the name people will see, and a username in Latin letters ending in
bot. - In the bot window, set the menu and description.
- “Run on server”: Hedoq deploys the bot to your server and starts it. Next to it are “Logs” and “Deploy again”.
- You can group bots into projects: drag a bot with the mouse.
The agent and your Telegram
Once the account is connected, the agent in any session can, when you ask:
- find a chat by name;
- read messages;
- send a message or a file as you;
- download a file or photo from a chat.
Just ask in plain words: “find the latest message from John in Telegram and reply that everything is ready”. The agent does not ask you for keys or codes.
Good to know
- Bot tokens go straight to Keychain. They never show up in command output or project files.
- A bot can only be deleted in Telegram itself, for good. You cannot remove it “from Hedoq only”: the bot would keep living.
- The account sign-in file gives full access to the account. Hedoq keeps it in its own folder with locked-down permissions and never sends it anywhere.
- Without an account sign-in, the agent asks you once to click “Connect account”.
See also: automations, servers.