Welcome to the KTU Bot! This Telegram bot helps students check their exam results, find latest KTU notifications and alert users when new notifications arrive.
Find the bot here
- Check Results: Use the
/result
command to fetch your exam results. - Download latest KTU notifications: Use the
/notifications
command to fetch KTU notifications and download them. - Subscribe to latest KTU notifications: Use the
/subscribe
command to recieve new notifications as they arrive. - Help: Get help using the
/help
command. - Live search notifications: Live search and find KTU notifications using inline queries
-
/start
: Start the bot and get a welcome message. -
/help
: Show a help message with available commands. -
/result
: Fetch your exam results. -
/notifications
: Find and download latest KTU notifications. -
/subscribe
: Subscribe to recieve latest KTU notifications as they arrive. -
/unsubscribe
: Unsubscribe from recieving KTU notifications. -
/cancel
: Cancel current process (only works when inside/notifications
or/result
wizard) -
/code
: See project source code
Use inline query to live search the notification you want to. No more pain of scrolling through the webpage for the notification.
eg: @ktu_results_bot calendar : This returns all the results that matches word "calendar" like Academic calendars etc.
-
Install Node.js and npm on your machine.
-
Clone the repository:
git clone https://github.com/devadathanmb/ktu-bot.git
-
Navigate to the project directory:
cd ktu-bot
-
Install dependencies:
npm install
-
Set up your Telegram bot token:
-
Create a new bot on Telegram using the BotFather.
-
Copy the bot token.
-
Create a
.env
file in the project root and add:BOT_TOKEN="your-telegram-bot-token"
See env.example file for example
-
-
Create a Firebase project and setup a Firestore database in Firebase console
-
Download the
serviceAccountKey.json
file,minify
it andbase64
encode it usingjq -r tostring serviceAccountKey.json | base64
-
Copy the
base64
encodedserviceAccountKey.json
string to.env
FIREBASE_SERVICE_ACCOUNT="base64 encoded string"
-
Set the
ENV_TYPE
variable toDEVELOPMENT
in.env
ENV_TYPE="DEVELOPMENT"
-
Build the bot:
npm run build
-
Start the bot:
npm run start
-
Install Docker and Docker Compose on your machine.
-
Clone the repository:
git clone https://github.com/devadathanmb/ktu-bot.git
-
Navigate to the project directory:
cd ktu-bot
-
Create a
.env
file in the project root and add:BOT_TOKEN="your-telegram-bot-token"
-
Create a Firebase project and setup a Firestore database in Firebase console
-
Download the
serviceAccountKey.json
file,minify
it andbase64
encode it usingjq -r tostring serviceAccountKey.json | base64
-
Copy the
base64
encodedserviceAccountKey.json
string to.env
FIREBASE_SERVICE_ACCOUNT="base64 encoded string"
-
Set the
ENV_TYPE
variable toDEVELOPMENT
in.env
ENV_TYPE="DEVELOPMENT"
-
Run the application using Docker Compose:
docker-compose up
The bot should now be running and accessible on Telegram.
If you encounter any issues, have feature suggestions, or want to contribute to the project, please feel free to fork and make a PR.
If you find any bugs or have feedback, please open an issue on GitHub.
This project is licensed under the GPL 3.0 License - see the LICENSE.md file for details.