telegram-bot: Skill for Cursor

.cursor/skills/add-telegram-api-action/SKILL.md

add-telegram-api-action is a skill for Cursor from vendelieu/telegram-bot. It costs 61 tokens per session (1,019 once invoked), scanned A, original, Apache-2.0.

A guide for adding a new method to a Kotlin Telegram Bot API library. It covers the method's options, return type, action class, and support for required or optional parameters.

In plain words
What is it for?
Use it to add methods such as sending media or retrieving bot data, define optional parameters, handle file uploads, and expose the method through the library.
Why use it?
It provides the implementation path needed to keep a new library method aligned with Telegram's official API. It also helps place reusable options and media handling in the right parts of the codebase.

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-api-action/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-api-action

README.md
[![agentmods](https://agentmods.dev/badge/skills/vendelieu/telegram-bot/add-telegram-api-action/github.svg)](https://agentmods.dev/skills/vendelieu/telegram-bot/add-telegram-api-action)
Your own site
<a href="https://agentmods.dev/skills/vendelieu/telegram-bot/add-telegram-api-action"><img src="https://agentmods.dev/badge/skills/vendelieu/telegram-bot/add-telegram-api-action/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-api-action

Your own site · 80×15
<a href="https://agentmods.dev/skills/vendelieu/telegram-bot/add-telegram-api-action"><img src="https://agentmods.dev/badge/skills/vendelieu/telegram-bot/add-telegram-api-action.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 61 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,019 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.00061 $0.01019
Opus 5.5 $0.00024 $0.00408
Sonnet 5.5 $0.00012 $0.00204
Haiku 4.5 $0.00006 $0.00102

Measured 2mo ago against content hash 026e757e2a71, 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-api-action 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-api-action/SKILL.md · 84 lines

How it starts

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

Add Telegram API Action

Workflow

1. Determine Action Type

  • Requires chat_id? -> Action (or MediaAction for media)
  • No chat context? -> SimpleAction (e.g. getMe, getUpdates, setWebhook)

2. Check Telegram API Spec

Consult core.telegram.org/bots/api for:

  • Method name (snake_case)
  • Required vs optional parameters
  • Return type

3. Create Options Class (if optional params)

  • Place in telegram-bot/src/commonMain/kotlin/eu/vendeli/tgbot/types/options/
  • data class implementing Options + mixins (OptionsCommon, OptionsParseMode, MediaSpoiler, ForumProps, etc.)
  • All optional params: var prop: Type? = null
  • Add @Serializable
  • Mixin interfaces: Put optional params into separate mixin interfaces in IOptions.kt when they can be reused by other Options classes. Add a new interface (e.g. interface MyProp : Options { var myParam: Type? }) only when the param is shared; single-use params stay in the data class.

4. Create Action Class

Place in appropriate package under telegram-bot/src/commonMain/kotlin/eu/vendeli/tgbot/api/:

  • media/ - photo, video, document, etc.
  • message/ - sendMessage, editMessage, etc.
  • answer/ - answerCallbackQuery, answerInlineQuery
  • botactions/ - getMe, setWebhook, etc.
  • chat/ - getChat, banChatMember, etc.

Required:

  • @TgAPI on class
  • @TgAPI.Name("methodName") on method when Kotlin name differs from API
  • override val method, returnType, options (if OptionsFeature)

Features (add as needed):

  • OptionsFeature - optional params via options { }
  • MarkupFeature - reply_markup
  • CaptionFeature - caption, caption_entities (media)
  • EntitiesFeature - entities (text)
  • BusinessActionExt - chat-based actions
  • InlineActionExt - inline message actions

Parameter handling:

  • Simple (String, Long, Int, Boolean): parameters["key"] = value.toJsonElement()
  • Complex objects: value.encodeWith(MyType.serializer())
  • Lists: list.encodeWith(ListSerializer(ItemType.serializer()))
  • Polymorphic ID (chat/user: Long or String): value.encodeWith(DynamicLookupSerializer)
  • Enums: value.encodeWith(EnumType.serializer())
  • Required media: handleImplicitFile(file, "paramName") in init
  • Optional media in Options (thumbnail): handleImplicitFile(options::thumbnail) in override val beforeReq
  • Complex types with nested ImplicitFile (InputProfilePhoto, InputStoryContent): transform in beforeReq, then encodeWith(Serializer)

Read the full file on GitHub · 84 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 · 84 lines · 61 tokens per session scan A 026e757e2a71

Subscribe to this mod's changes

add-telegram-api-action is a skill published in the GitHub repository vendelieu/telegram-bot (249 stars, last pushed yesterday), licensed Apache-2.0. It adds 61 tokens to every session and 1,019 once invoked, about $0.0002 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-api-action compared with skills from other repositories

add-telegram-api-action next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
add-telegram-api-actionvendelieu/telegram-botSkill249yesterdayApache-2.0A61Cursor
kotlin-backend-conventionsTencentBlueKing/bk-ciSkill2.5kyesterdaynoneA71Claude Code, Codex
backend-microservice-developmentTencentBlueKing/bk-ciSkill2.5kyesterdaynoneA62Claude Code, Codex
ktorHeapy/kortexSkill74d agoApache-2.0A57Claude Code, Codex
Cursor rules for Kotlin development with Ktor integrationAmariahAK/atlarix-skillsSkill21mo agoApache-2.0A9Claude Code, Codex
Cursor rules for Kotlin Springboot Best PracticesAmariahAK/atlarix-skillsSkill21mo agoApache-2.0A8Claude Code, Codex
at_client_skills-sdkatsign-foundation/at_client_sdkSkill1.4kyesterdayBSD-3-ClauseA220Claude Code