Skip to content
Agentmart
Submit a tool

telegram

Operating procedures for the Telegram channel in smolbot.

Skill by Nomadcxx

IndexedBSD-3-Clause★ 1
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/nomadcxx-telegram

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Operating procedures for the Telegram channel in smolbot. Use when sending messages, handling errors, or managing Telegram bot sessions.

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/telegram

What's inside

Skill name
telegram
Description
Operating procedures for the Telegram channel in smolbot. Use when sending messages, handling errors, or managing Telegram bot sessions.
License
BSD-3-Clause
Instructions
89 lines in SKILL.md · view on GitHub

Files (1)

  • SKILL.md

SKILL.md (first lines)

---

## Telegram Channel

smolbot connects to Telegram via the `go-telegram/bot` library using long polling. All operations pass through `pkg/channel/telegram/adapter.go`.

### Sending Messages

Use the `message` tool with `channel: "telegram"`:

```
message(channel="telegram", chat_id="123456789", content="Hello")
```

The `chat_id` is a numeric Telegram chat ID (as a string). For DMs, this is the user's numeric ID. For groups, this is the group's numeric chat ID.

### Message Content

**Only text is supported.** The adapter explicitly filters for text:
```go
if update.Message == nil || update.Message.Text == "" {
    return
}
```

No support for photos, videos, documents, inline keyboards, or reply keyboards — these are not implemented in smolbot's Telegram adapter.

### Character Limit

Messages are chunked at **4096 characters** using paragraph-aware splitting (finds last `\n\n`, `\n`, or space). Code blocks spanning splits should close and reopen the `<pre>` tag.

### Formatting

smolbot's Telegram adapter does **not** apply automatic formatting. Agents must construct messages with appropriate Telegram-native formatting if desired. HTML is supported by Telegram's API but not automatically generated:

- `<b>bold</b>`
- `<i>italic</i>`
- `<code>code</code>`
- `<pre>pre-formatted</pre>`

### Token Management

Telegram uses a bot token (format: `123456789:ABCdef...`). Tokens are loaded from:
1. `BotToken` config field directly
2. `TokenFile` — reads from file, trims whitespace

Tokens never expire but can be revoked via @BotFather.

### Status States

- `disconnected` — initial state
- `connecting` — during `Start()`
- `connected` — running
- `error` — error with `Detail` containing the error message
- `auth-required` — token validation failed via `GetMe()`

### Error Handling

Errors from the Telegram API propagate directly:
- `401 Unauthorized` — token invalid or revoked → `auth-required` status
- `403 Forbidden` — bot blocked by user or removed from group
- `400 Bad Request` — malformed request
- `429 Too Many Requests` — rate limited, check `retry_after`

### Rate Limiting

smolbot does not implement explicit rate limiting. Telegram enforces:
- Global: 30 messages/second across all chats
- Per-chat: 1 message/second

Space rapid messages 1 second apart to stay within per-chat limits.

### Allowed Chat IDs

Optional whitelist in config:
```json
{
  "enabled": true,
  "botToken": "...",
  "allowedChatIDs": ["123456789", "-100987654321"]
}
```

Messages from non-whitelisted chats are silently ignored by the adapter.

### Inbound Deduplication

Messages are deduped within a 5-minute window using a `recent` map. Duplicate messages (same `chat_id` + same text) are silently ignored.

From Nomadcxx/smolbot, BSD-3-Clause.

More from Nomadcxx/smolbot

Signals

Stars
1
Forks
0
Open issues
0
Last commit (this folder)
Mar 31, 2026 (7 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
BSD-3-Clause
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from Nomadcxx

Cite this page

telegram skill. Agent Mart. https://agentmart.dev/skills/nomadcxx-telegram (last updated 2026-10-24)