How-to · Sending elsewhere
Talk to sessions from Telegram
Set up a bot and a private group, then start sessions, answer their asks and add people from Telegram.
You want to start a session, steer it and answer its permission asks from Telegram. Only you and the people you add can enter the group.
Turret answers a single bot in a single private group with Topics on. This is the home group. Each session gets a topic of its own in the group. The bot's direct chat is for pairing and notices, and no session runs there.
Set up the bot and the group
- Open Settings, then the Accounts tab, and pick Telegram. The Setup list at the top has eleven steps. Work down it.
- Make a bot with @BotFather and save its token under Bot. The first two steps check this with Telegram.
- In @BotFather, open Bot Settings for the bot and turn on Restrict bot usage. Turret cannot check this step, so tick it yourself.
- Under Channels, switch on answering for this computer and press Pair. Send the code to the bot in a private chat.
- In Telegram, make a new group and add only yourself. Do not give it a public link.
- In the group's settings, turn on Topics.
- Add the bot to the group yourself. The first group you add it to becomes the home group. Turret then checks Topics for you.
- In the group, open Administrators, add the bot, and switch on Manage topics, Ban users and Invite users via link. Leave every other right off.
- In @BotFather, turn Allow Groups off. Nobody can add the bot to another group after that.
- Under Sessions from Telegram, add the folders Telegram may start sessions in.
- Pick a permission mode, Manual or Auto.
The bot posts a first message in the group's General topic once it is the home group. When a step is still to do, that message lists it.
The Setup list collapses to a single line when every step is checked or ticked. A step that stops passing opens the list again and names the failing step.
Start a session
- In the home group's General topic, send
/session. - Pick a folder from the approved list. Pick a mode when the bot asks for it.
- Open the new topic. The bot's first line names the folder, the host and what the session asks before it acts.
- Send your first message in the topic. It is the session's first prompt.
Every message from you or from a Steer member in a topic reaches the session without a mention. Each reply comes back to the topic.
/session offers only approved folders. With none approved, the bot says so and offers nothing. A folder you remove later closes no session already running in it.
Attach a session you already have
- Open a topic in the home group and send
/bindwith the session's title or id. - Send
/bindalone to see recent sessions on the host.
A session you attach keeps its own permission mode. The bot refuses a session that runs with permissions bypassed, and tells you to change its mode in Turret first.
Answer an ask
A session in Manual mode asks in its topic before it edits files or runs commands. The message has Allow once and Deny buttons. It adds an always-allow button when the engine offers it.
Only the owner and a Steer member with Can approve tool calls ticked can press them. A session started from Telegram never runs in Bypass, whatever this computer's own default is.
Commands in the home group
| Command | What it does | Who may use it |
|---|---|---|
/session |
Opens a topic with a new session in an approved folder. | Owner |
/bind |
Attaches an existing session to the topic. | Owner |
/status |
Shows what is bound and what it is doing. | Owner, Steer |
/stop |
Stops the turn that is running. | Owner, Steer |
/new |
Starts a fresh conversation in the topic's session. | Owner |
The bot's direct chat answers /pair, /help and /start. A plain message there gets a line saying where sessions live.
Add someone
Only people you add can be in the group. Turret declines everyone else's request to join and removes anyone else who is added.
- Under Channels, open Members.
- Press Invite someone, type their name and press Make invite.
- Send them the link. Their request to join comes up under Asked to join.
- Press Let in to add them as a Watcher. Press Decline to turn them away.
- Change a person's role to Steer to let their messages start turns.
A person who has already written to the bot appears in the list of people the bot has seen. Press Add beside them instead of making an invite.
A Watcher can read the group. What they write reaches a session only as background, on a turn you or a Steer member starts. Remove from the group takes a person off the list and out of the group.
Turret tells you in the bot's direct chat each time it declines someone, removes someone or leaves a group. Recent actions under Home group lists the last few. Turned away lists the people it sent off.
Check the group's settings
Under Home group, Turret reads the group's settings and the bot's rights, and lists each as healthy, failing or unreadable.
- Press Check again to read the group once more.
- Press Fix 2 settings to have Turret stop members adding people and making topics. The count is how many settings it changes.
- Make the group private and give the bot any missing right in Telegram. The bot cannot change these. A private group needs nothing else: Telegram offers Approve new members only on a public group, and only there does Turret ask for it.
A bot that is not an admin cannot read the rest of the group's settings. Those rows read as unreadable until you make it an admin.
Fix a problem
| You see | What to do |
|---|---|
| Another program is answering the bot | Switch answering off in the other Turret, or stop the other program. Telegram gives a bot's messages to a single program at a time. |
| The bot left a group | Someone other than you added it. The bot only stays in the home group. Add it to your own group yourself. |
| The bot is in groups and none is the home group | Press Choose a group under Home group and pick one. The bot leaves the rest. |
| The bot cannot decline or remove someone | It lacks Invite users via link or Ban users. Give it the right in the group's Administrators. |
/session offers nothing |
No folder is approved. Add one under Approved folders. |
| Nothing happens in a topic | Check that the person is listed as Owner or Steer and that the bot is still an admin. |
An older session that the bot's direct chat once drove keeps its place on the sidebar. It is read-only and nobody can answer it. Archive it when you are done reading.
See Send a message to Telegram for the token, the saved chats and the send tool.