telegram-bot: Skill for Cursor

.cursor/skills/add-telegram-update-field/SKILL.md

add-telegram-update-field is a skill for Cursor from vendelieu/telegram-bot. It costs 80 tokens per session (879 once invoked), scanned A, original, Apache-2.0.

A guide for adding a new kind of Telegram update throughout a Kotlin bot library. An update is an event from Telegram, such as a message, reaction, or chat change.

In plain words
What is it for?
Use it to support a new Telegram event by adding its data field, event type, processed-update class, conversion logic, and mappings used by generated handlers.
Why use it?
Adding a field in only one place can leave deserialization, typed handlers, or generated code unable to recognize the event. This guide lists the connected files that must be updated.

Skill for Cursor

Written for Cursor: installed under .cursor/.

This is vendelieu/telegram-bot's own configuration. It tells Cursor how to work on telegram-bot itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything telegram-bot configures →

Reuse

Borrowing it

Nothing to install: this file belongs to vendelieu/telegram-bot. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/vendelieu/telegram-bot/master/.cursor/skills/add-telegram-update-field/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/vendelieu/telegram-bot

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for add-telegram-update-field

README.md
[![agentmods](https://agentmods.dev/badge/skills/vendelieu/telegram-bot/add-telegram-update-field/github.svg)](https://agentmods.dev/skills/vendelieu/telegram-bot/add-telegram-update-field)
Your own site
<a href="https://agentmods.dev/skills/vendelieu/telegram-bot/add-telegram-update-field"><img src="https://agentmods.dev/badge/skills/vendelieu/telegram-bot/add-telegram-update-field/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for add-telegram-update-field

Your own site · 80×15
<a href="https://agentmods.dev/skills/vendelieu/telegram-bot/add-telegram-update-field"><img src="https://agentmods.dev/badge/skills/vendelieu/telegram-bot/add-telegram-update-field.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 80 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 879 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00080 $0.00879
Opus 5.5 $0.00032 $0.00352
Sonnet 5.5 $0.00016 $0.00176
Haiku 4.5 $0.00008 $0.00088

Measured 2mo ago against content hash 228d5df5246a, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

add-telegram-update-field scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/skills/add-telegram-update-field/SKILL.md · 61 lines

How it starts

The opening of the file, as written. The whole thing — 61 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Add Telegram Update Field

Workflow

1. Add Field to Update

  • In Update.kt: add val myField: MyType? = null (camelCase, nullable)
  • Add import for the payload type if needed

2. Add UpdateType Entry

  • In UpdateType.kt: add enum entry with @SerialName("snake_case") matching Telegram API (e.g. MY_FIELD)

3. Add ProcessedUpdate Subclass

  • In ProcessedUpdate.kt: add data class MyFieldUpdate(...) : ProcessedUpdate(...)
  • Use @Serializable(MyFieldUpdate.Companion::class) and internal companion object : UpdateSerializer<MyFieldUpdate>()
  • Implement UserReference when the update has a user; ChatReference when it has a chat; TextReference when it has text

4. Add processUpdate Clause

  • In ProcessUpdate.kt: add myField != null -> MyFieldUpdate(updateId, this, myField)
  • Add import for the new ProcessedUpdate subclass
  • Place clause in a logical order (group with similar update types)

5. Update KSP Module

  • In TypeConstants.kt: add val myFieldUpdateClass: TypeName = MyFieldUpdate::class.asTypeName()
  • In TypeMapper.kt: add TypeConstants.myFieldUpdateClass to MyFieldUpdate::class to updateTypeMap

6. Regenerate FunctionalDSLUtils

  • Run ./gradlew prepareRelease (or full build)
  • api-sentinel KSP regenerates FunctionalDSLUtils.kt from UpdateType.entries; no manual edits needed

Handling: The new onXxx DSL function enables bot.setFunctionality { onXxx { ... } }. Both functional DSL and annotation approach (@UpdateHandler) use the same ActivityRegistry and ProcessingPipeline; see telegram-bot-handling.mdc.

Read the full file on GitHub · 61 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 61 lines · 80 tokens per session scan A 228d5df5246a

Subscribe to this mod's changes

add-telegram-update-field is a skill published in the GitHub repository vendelieu/telegram-bot (249 stars, last pushed yesterday), licensed Apache-2.0. It adds 80 tokens to every session and 879 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

add-telegram-update-field compared with skills from other repositories

add-telegram-update-field next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
add-telegram-update-fieldvendelieu/telegram-botSkill249yesterdayApache-2.0A80Cursor
kotlin-tooling-agp9-migrationKotlin/kotlin-agent-skillsSkill1.1k7d agoApache-2.0A105Claude Code, Codex
compose-animationschrisbanes/skillsSkill1.1kyesterdayApache-2.0A64Claude Code
compose-focus-navigationchrisbanes/skillsSkill1.1kyesterdayApache-2.0A41Claude Code
kotlin-tooling-immutable-collections-0-5-x-migrationKotlin/kotlin-agent-skillsSkill1.1k7d agoApache-2.0A192Claude Code, Codex
kotlin-tooling-native-build-performanceKotlin/kotlin-agent-skillsSkill1.1k7d agoApache-2.0A96Claude Code, Codex
kotlin-tooling-java-to-kotlinKotlin/kotlin-agent-skillsSkill1.1k7d agoApache-2.0A100Claude Code, Codex