channel-post
Skill11 starsChanged 21 days agoApache-2.0View on GitHub
Compose and post formatted content to a Telegram channel -- MarkdownV2 escaping, message splitting, media ordering
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 27
Split long messages: if content exceeds 4096 characters:
- Distinctive: line 34
Verify the message appears correctly in the channel
- Distinctive: line 35
If formatting breaks, check the escaping rules below
- Very specific: line 39
All these characters MUST be escaped with \ when used as literal text (outside formatting markup):
- Distinctive: line 63
When nesting, the inner delimiter must also be escaped:
≈ “Common” is an estimate: at least 1 in 5 of the 308,232 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Channel Post
Compose and post formatted content to a Telegram channel with correct formatting.
Steps
- Identify target channel:
chat(action="list")to find the channel- Channel chat_id is a negative number (e.g., -1001234567890) or @username
- Compose content with the user:
- Draft the message text
- Apply MarkdownV2 formatting (see escaping rules below)
- Determine if media attachments are needed
- Handle media attachments (if any):
- Photo with caption:
media(action="send_photo", chat_id="...", file_path_or_url="...", caption="...")-- caption goes WITH the photo, not as a separate message - Document:
media(action="send_file", chat_id="...", file_path_or_url="...") - Multiple photos: send as media group, first photo carries the caption
- Photo with caption:
- Split long messages if content exceeds 4096 characters:
- Split at paragraph boundaries (double newline) to preserve readability
- Each chunk must be independently valid MarkdownV2 (no unclosed formatting)
- Send chunks sequentially with the same parse_mode
- Send and verify:
message(action="send", chat_id="<channel>", text="<content>", parse_mode="MarkdownV2")- Verify the message appears correctly in the channel
- If formatting breaks, check the escaping rules below
MarkdownV2 Escaping Rules
All these characters MUST be escaped with \ when used as literal text (outside formatting markup):
_ * [ ] ( ) ~ ` > # + - = | { } . !Common patterns
| Intent | Correct MarkdownV2 |
| Bold text | *bold* |
| Italic text | _italic_ |
| Code inline | `code` |
| Code block | ```language\ncode\n``` |
| Link | [text](https://url) |
| Literal dot in "v2.0" | v2\.0 |
| Literal dash in list | \- item |
| Price "$9.99" | \$9\.99 |
| Exclamation "Done!" | Done\! |
| Parenthetical "(note)" | \(note\) |
| Hashtag "#topic" | \#topic |
Formatting inside formatting
When nesting, the inner delimiter must also be escaped:
- Bold italic:
*_bold italic_*-- the_inside*...*does NOT need escaping - But literal
_inside bold:*score\_value*-- MUST escape
Frequent mistakes
- Forgetting to escape
.in URLs used as plain text (not inside[](...)) - Forgetting to escape
!at end of sentences - Forgetting to escape
-in bulleted lists (use\-or switch to HTML<li>) - Unescaped
()in regular text (Telegram interprets them as link syntax)
When to Use
- Publishing announcements, updates, or newsletters to a Telegram channel
- Posting formatted content (code snippets, tables, lists) to channels
- Sending content with images or documents to channels
- Any message that needs careful MarkdownV2 formatting
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

