Telegram Miniapps

Use when building or auditing a Telegram Mini App — a web page opened inside Telegram — where the whole security model is one signed blob. Covers verifying initData on the server with HMAC-SHA256 and the "WebAppData" key derivation, why initDataUnsafe is named that, the auth_date freshness window, the Ed25519 signature path for a third party with no bot token, session exchange, sending results back to the bot with sendData and answerWebAppQuery, Stars payments inside the app, the viewport and safe-area fields a real device needs, and the SDK package whose name moved. Triggers - "mini app", "miniapp", "telegram web app", "initData", "initDataUnsafe", "WebAppData", "tma.js", "@telegram-apps/sdk", "мини-апп", "телеграм веб-апп", "валидация initData". Not for the bot behind it (telegram-bots) or user accounts (telegram-userbots).

ssheleg 8048e4f 5 files · 26.3 KB Updated

File contents

ssheleg/telegram-dev/tree/main/plugins/telegram-dev/skills/telegram-miniapps commit 8048e4f3d5

Frequently asked questions

npx skillmds@latest add ssheleg/telegram-miniapps