Skip to content

Latest commit

 

History

History
35 lines (24 loc) · 1.19 KB

README.md

File metadata and controls

35 lines (24 loc) · 1.19 KB

👶 Comic-Bot : A Telegram Bot (WIP)👷

Comic-Bot is a simple bot to interact with your favorite web comic.

It has very limited capabilities and only supports Xkcd comic.

Prerequisite

Get Bot Token by following instruction in Telegram Website

How to Start

There are 2 ways to start:

  1. Run clj -M:main $TELEGRAM_BOT_TOKEN in shell where TELEGRAM_BOT_TOKEN is Telegram Bot API key.
  2. Alternative: set enviroment variable TELEGRAM_BOT_TOKEN with Telegram Bot API key then run clj -M:main.

List of Commands

Try interacting with bot by send chat message to contact ComicBot in Telegram:

  1. /hi to see welcome message
  2. /latest to get latest Xkcd comic strip

Under the hood

  • Comic-Bot uses clj-http to poll any new recognized message and respond accordingly.
  • Test runner uses kaocha. Run all test by bin/kaocha.

How it works

Diagram

TODO

  • Print bot status
  • reply message/picture asynchronously
  • add tests

Disclaimer

Xkcd is owned by Randall Munroe.