Agent skill

Telegram Mini App

by davila7 in davila7/claude-code-templates

Expert in building Telegram Mini Apps (TWA) - web apps that run inside Telegram with native-like experience.

MITAuto-check passedBackend & APIs

Install Telegram Mini App

skills CLI
$ npx skills add davila7/claude-code-templates --skill telegram-mini-app -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install davila7/claude-code-templates telegram-mini-app --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/davila7/claude-code-templates.git skills-src && mkdir -p .claude/skills && cp -r skills-src/cli-tool/components/skills/enterprise-communication/telegram-mini-app .claude/skills/telegram-mini-app && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
telegram-mini-app
GitHub stars
32k
Used in
4 other repos
Token cost
~1.5k tokens
SKILL.md length
122 words
Files
1
Skills in repo
477
Repo updated
First seen
Licence
MIT

At a glance

Expert in building Telegram Mini Apps (TWA) - web apps that run inside Telegram with native-like experience.

  • : telegram mini app
  • SKILL.md covers Capabilities and Patterns
  • Calls npm; reaches t.me and telegram.org
  • Telegram web app

What it does

Telegram Mini App is an agent skill from davila7/claude-code-templates. Expert in building Telegram Mini Apps (TWA) - web apps that run inside Telegram with native-like experience. Covers the TON ecosystem, Telegram Web App API, payments, user authentication, and building viral mini apps that monetize. Use when: telegram mini app, TWA, telegram web app, TON app, mini app.

Its SKILL.md is about 1.5k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Backend & APIs. It works with Telegram. The repository describes itself as: CLI tool for configuring and monitoring Claude Code. The licence is MIT.

When your agent uses it

  • : telegram mini app
  • Telegram web app

Example prompts

  • “/telegram-mini-app”

Requirements

  • Python 3
  • Node.js

What it can do on your machine

Read from SKILL.md and the folder at commit 14680ec. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npm

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • t.me
    • telegram.org

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Telegram Mini App loads about 1.5k tokens when it runs. Until then it costs about 80 tokens; SKILL.md has 122 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~80
When it runs · the whole SKILL.md, loaded when a task matches
~1.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from davila7/claude-code-templates at commit 14680ec, republished under its MIT licence (© davila7). 122 words, ~1,539 tokens.

Download SKILL.mdSave it as .claude/skills/telegram-mini-app/SKILL.md (or your agent's skills folder).
name
telegram-mini-app
description
Expert in building Telegram Mini Apps (TWA) - web apps that run inside Telegram with native-like experience. Covers the TON ecosystem, Telegram Web App API, payments, user authentication, and building viral mini apps that monetize. Use when: telegram mini app, TWA, telegram web app, TON app, mini app.
source
vibeship-spawner-skills (Apache 2.0)

Telegram Mini App

Role: Telegram Mini App Architect

You build apps where 800M+ Telegram users already are. You understand the Mini App ecosystem is exploding - games, DeFi, utilities, social apps. You know TON blockchain and how to monetize with crypto. You design for the Telegram UX paradigm, not traditional web.

Capabilities

  • Telegram Web App API
  • Mini App architecture
  • TON Connect integration
  • In-app payments
  • User authentication via Telegram
  • Mini App UX patterns
  • Viral Mini App mechanics
  • TON blockchain integration

Patterns

Mini App Setup

Getting started with Telegram Mini Apps

When to use: When starting a new Mini App

javascript
## Mini App Setup

### Basic Structure
```html
<!DOCTYPE html>
<html>
<head>
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <script src="https://telegram.org/js/telegram-web-app.js"></script>
</head>
<body>
  <script>
    const tg = window.Telegram.WebApp;
    tg.ready();
    tg.expand();

    // User data
    const user = tg.initDataUnsafe.user;
    console.log(user.first_name, user.id);
  </script>
</body>
</html>
React Setup
jsx
// hooks/useTelegram.js
export function useTelegram() {
  const tg = window.Telegram?.WebApp;

  return {
    tg,
    user: tg?.initDataUnsafe?.user,
    queryId: tg?.initDataUnsafe?.query_id,
    expand: () => tg?.expand(),
    close: () => tg?.close(),
    ready: () => tg?.ready(),
  };
}

// App.jsx
function App() {
  const { tg, user, expand, ready } = useTelegram();

  useEffect(() => {
    ready();
    expand();
  }, []);

  return <div>Hello, {user?.first_name}</div>;
}
Bot Integration
javascript
// Bot sends Mini App
bot.command('app', (ctx) => {
  ctx.reply('Open the app:', {
    reply_markup: {
      inline_keyboard: [[
        { text: '🚀 Open App', web_app: { url: 'https://your-app.com' } }
      ]]
    }
  });
});

### TON Connect Integration

Wallet connection for TON blockchain

**When to use**: When building Web3 Mini Apps

```python
## TON Connect Integration

### Setup
```bash
npm install @tonconnect/ui-react
React Integration
jsx
import { TonConnectUIProvider, TonConnectButton } from '@tonconnect/ui-react';

// Wrap app
function App() {
  return (
    <TonConnectUIProvider manifestUrl="https://your-app.com/tonconnect-manifest.json">
      <MainApp />
    </TonConnectUIProvider>
  );
}

// Use in components
function WalletSection() {
  return (
    <TonConnectButton />
  );
}
Manifest File
json
{
  "url": "https://your-app.com",
  "name": "Your Mini App",
  "iconUrl": "https://your-app.com/icon.png"
}
Send TON Transaction
jsx
import { useTonConnectUI } from '@tonconnect/ui-react';

function PaymentButton({ amount, to }) {
  const [tonConnectUI] = useTonConnectUI();

  const handlePay = async () => {
    const transaction = {
      validUntil: Math.floor(Date.now() / 1000) + 60,
      messages: [{
        address: to,
        amount: (amount * 1e9).toString(), // TON to nanoton
      }]
    };

    await tonConnectUI.sendTransaction(transaction);
  };

  return <button onClick={handlePay}>Pay {amount} TON</button>;
}

### Mini App Monetization

Making money from Mini Apps

**When to use**: When planning Mini App revenue

```javascript
## Mini App Monetization

### Revenue Streams
| Model | Example | Potential |
|-------|---------|-----------|
| TON payments | Premium features | High |
| In-app purchases | Virtual goods | High |
| Ads (Telegram Ads) | Display ads | Medium |
| Referral | Share to earn | Medium |
| NFT sales | Digital collectibles | High |

### Telegram Stars (New!)
```javascript
// In your bot
bot.command('premium', (ctx) => {
  ctx.replyWithInvoice({
    title: 'Premium Access',
    description: 'Unlock all features',
    payload: 'premium',
    provider_token: '', // Empty for Stars
    currency: 'XTR', // Telegram Stars
    prices: [{ label: 'Premium', amount: 100 }], // 100 Stars
  });
});
Viral Mechanics
jsx
// Referral system
function ReferralShare() {
  const { tg, user } = useTelegram();
  const referralLink = `https://t.me/your_bot?start=ref_${user.id}`;

  const share = () => {
    tg.openTelegramLink(
      `https://t.me/share/url?url=${encodeURIComponent(referralLink)}&text=Check this out!`
    );
  };

  return <button onClick={share}>Invite Friends (+10 coins)</button>;
}
Gamification for Retention
  • Daily rewards
  • Streak bonuses
  • Leaderboards
  • Achievement badges
  • Referral bonuses

## Anti-Patterns

### ❌ Ignoring Telegram Theme

**Why bad**: Feels foreign in Telegram.
Bad user experience.
Jarring transitions.
Users don't trust it.

**Instead**: Use tg.themeParams.
Match Telegram colors.
Use native-feeling UI.
Test in both light/dark.

### ❌ Desktop-First Mini App

**Why bad**: 95% of Telegram is mobile.
Touch targets too small.
Doesn't fit in Telegram UI.
Scrolling issues.

**Instead**: Mobile-first always.
Test on real phones.
Touch-friendly buttons.
Fit within Telegram frame.

### ❌ No Loading States

**Why bad**: Users think it's broken.
Poor perceived performance.
High exit rate.
Confusion.

**Instead**: Show skeleton UI.
Loading indicators.
Progressive loading.
Optimistic updates.

## ⚠️ Sharp Edges

| Issue | Severity | Solution |
|-------|----------|----------|
| Not validating initData from Telegram | high | ## Validating initData |
| TON Connect not working on mobile | high | ## TON Connect Mobile Issues |
| Mini App feels slow and janky | medium | ## Mini App Performance |
| Custom buttons instead of MainButton | medium | ## Using MainButton Properly |

## Related Skills

Works well with: `telegram-bot-builder`, `frontend`, `blockchain-defi`, `viral-generator-builder`

© davila7, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in cli-tool/components/skills/enterprise-communication/telegram-mini-app of davila7/claude-code-templates.

Open the folder on GitHubat commit 14680ec

Used in 4 other repositories

We found 6 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 4 other GitHub owners. This page covers the copy in davila7/claude-code-templates, which our catalogue first saw on October 7, 2026.

Compare with similar skills

Telegram Mini App next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Telegram Mini App compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Telegram Mini App this skilldavila7/claude-code-templates32k4 repos~1.5kAutomated safety check: PassMIT
LangBot EBA Adapter Developmentlangbot-app/LangBot18k—~4kAutomated safety check: PassApache-2.0
Tlgrtlgrcli/tlgr1931 repos~1.5kAutomated safety check: PassMIT
Fatecattradecatlabs/fatecat202—~1.7kAutomated safety check: NotesMIT
Add Channel Connect Buttonnovuhq/novu40k—~1.6kAutomated safety check: PassCustom licence
Better Notifybetter-notify/better-notify313—~783Automated safety check: PassMIT

Similar skills

  • Guides building, migrating and testing LangBot messaging-platform adapters for the Event-Based Agents layout, with unified event and message conversion.

    18k GitHub stars~4k tokensUpdated yesterday
    Backend & APIsAuto-check passed
  • Tlgr

    tlgrcli/tlgr

    Read and act on a personal Telegram account from the terminal with the tlgr CLI (MTProto user account, not a bot).

    193 GitHub starsUsed in 1 repo~1.5k tokens
    Backend & APIsAuto-check passed
  • Fatecat

    tradecatlabs/fatecat

    FateCat 执行型测算基础设施 skill:安装并校验当前仓库,执行生产化 capability,输出 JSON / Markdown,启动 Web / API / Telegram 交付层,并在发布前运行仓库卫生与生产就绪门禁。Use when 用户要求测算、排盘、生成报告、启动 Web/API/Bot、验收 skill、导出 bundle、检查生产可用性。

    202 GitHub stars~1.7k tokensUpdated 1 mo ago
    Backend & APIsAuto-check: notes
  • Build a new channel Connect button (e.g. An agent skill from novuhq/novu.

    40k GitHub stars~1.6k tokensUpdated yesterday
    Backend & APIsAuto-check passed
  • Better Notify

    better-notify/better-notify

    End-to-end typed notification infrastructure for Node.js — typed catalog of email, SMS, push, web push, WhatsApp, Slack, Discord, Telegram, and GitHub notifications with provider-agnostic transports.

    313 GitHub stars~783 tokensUpdated 1 mo ago
    Backend & APIsAuto-check passed
  • Fomo Agent

    cvxv666/fomo-robinhood-radar

    FOMO Robinhood Radar — a research watchlist of Robinhood Chain memecoin traders discovered through fomo.family.

    127 GitHub stars~3k tokensUpdated 2 days ago
    Backend & APIsAuto-check: warnings

More from davila7/claude-code-templates

All 477 skills in this repo
  • Perplexity Web Search

    davila7/claude-code-templates

    Runs web-grounded searches through Perplexity's Sonar models over OpenRouter for current events, recent literature and cited facts beyond the model's training cutoff.

    32k GitHub starsUsed in 12 repos~3.5k tokens
    Auto-check: notes
  • Neuropixels Data Analysis

    davila7/claude-code-templates

    Analyzes Neuropixels recordings from SpikeGLX or Open Ephys through preprocessing, drift correction, Kilosort4 spike sorting, quality metrics and curation.

    32k GitHub starsUsed in 10 repos~2.8k tokens
    Auto-check passed
  • Scientific Venue Templates

    davila7/claude-code-templates

    Supplies LaTeX templates and formatting rules for journals, conferences, posters, and grant proposals, then can check a draft against them.

    32k GitHub starsUsed in 9 repos~5.1k tokens
    Auto-check: notes
  • Brand Voice Content Creator

    davila7/claude-code-templates

    Analyzes a brand's existing writing to lock in a consistent voice, then builds SEO blog posts and platform-specific social content around it.

    32k GitHub starsUsed in 3 repos~1.9k tokens
    Auto-check passed
  • CAPA Officer

    davila7/claude-code-templates

    Guides corrective and preventive action (CAPA) work in a quality management system, from initiation and root cause analysis through effectiveness verification.

    32k GitHub starsUsed in 1 repo~2k tokens
    Auto-check passed
  • Fda Consultant Specialist

    davila7/claude-code-templates

    Senior FDA consultant and specialist for medical device companies including HIPAA compliance and requirement management.

    32k GitHub starsUsed in 1 repo~2.7k tokens
    Auto-check passed

Works with

Categories

Questions about Telegram Mini App

What does Telegram Mini App do?

Expert in building Telegram Mini Apps (TWA) - web apps that run inside Telegram with native-like experience. Telegram Mini App is an agent skill from davila7/claude-code-templates. Expert in building Telegram Mini Apps (TWA) - web apps that run inside Telegram with native-like experience.

When should I use Telegram Mini App?

Telegram Mini App fits situations like: : telegram mini app; telegram web app.

How do I install Telegram Mini App in Claude Code?

Run `npx skills add davila7/claude-code-templates --skill telegram-mini-app -a claude-code`. Or copy the skill folder (cli-tool/components/skills/enterprise-communication/telegram-mini-app in davila7/claude-code-templates) into .claude/skills/telegram-mini-app in your project. Claude Code loads it when a task matches its description.

How do I install Telegram Mini App in Codex?

Run `npx skills add davila7/claude-code-templates --skill telegram-mini-app -a codex`. Or copy the skill folder (cli-tool/components/skills/enterprise-communication/telegram-mini-app in davila7/claude-code-templates) into .agents/skills/telegram-mini-app in your project. Codex loads it when a task matches its description.

Can I use Telegram Mini App in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add davila7/claude-code-templates --skill telegram-mini-app -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/telegram-mini-app, .gemini/skills/telegram-mini-app, .github/skills/telegram-mini-app and .opencode/skills/telegram-mini-app in your project.

What does Telegram Mini App need to run?

Going by SKILL.md and its folder, Telegram Mini App needs the command-line tools its instructions call (npm). Our summary lists: Python 3; Node.js.

Does Telegram Mini App access the network?

SKILL.md names 2 domains. In commands or code: t.me and telegram.org; the agent is likely to contact these when it follows the instructions. This is read from the text; nothing was executed.

Is Telegram Mini App safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Telegram Mini App use?

Telegram Mini App is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Telegram Mini App use?

About 1.5k tokens (SKILL.md is roughly 6.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Telegram Mini App?

Skills that share tags, products or a category with Telegram Mini App: LangBot EBA Adapter Development (langbot-app/LangBot, 18k stars), Tlgr (tlgrcli/tlgr, 193 stars), Fatecat (tradecatlabs/fatecat, 202 stars) and Add Channel Connect Button (novuhq/novu, 40k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Telegram Mini App?

davila7 (a GitHub user) maintains it in davila7/claude-code-templates, which has 32,463 GitHub stars. The repository holds 477 skills in this directory. The repository was last updated on October 8, 2026.

Source: davila7/claude-code-templates on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.