html-telegram-bot-api
Version:
Now you can write Telegram bots in HTML.
36 lines (31 loc) • 988 B
HTML
<html>
<head>
<meta charset="utf-8">
<title>html-telegram-bot-api</title>
</head>
<body data-tg-root>
<!-- Replace the value below with the API token you receive from Bot Father -->
<div data-tg-token>254259451:AA5cAlGQj51K9AD37v_522HC-5lFgB</div>
<div data-tg-commands>
<div data-tg-command="/start">
<div data-tg-method="sendMessage">
<div data-tg-param="text">Start</div>
</div>
</div>
<div data-tg-command="/help">
<div data-tg-method="sendMessage">
<div data-tg-param="text">Help1</div>
</div>
<!-- Shortcut -->
<div data-tg-method="sendMessage">Help2</div>
</div>
<div data-tg-command="/.*" data-tg-regex>
<div data-tg-method="sendMessage">Received your command.</div>
</div>
<div data-tg-command="/echo (.+)" data-tg-regex>
<div data-tg-method="sendMessage">$1</div>
</div>
</div>
</body>
</html>