Code Monkey home page Code Monkey logo

slashbot's Introduction

💸 SlashBot

MIT license GitHub GitHub contributors DOI Platform codecov Actions Status github workflow Discord Lines of code Version GitHub issues GitHub closed issues


Demo Video

https://www.youtube.com/watch?v=uIHnW8YmrsU

About SlashBot

SlashBot is an easy-to-use Telegram Bot that assists you in recording your daily expenses on a local system without any hassle.
With simple commands, this bot allows you to:

  • Add/Record a new spending
  • Show the sum of your expenditure for the current day/month
  • Display your spending history
  • Clear/Erase all your records
  • Edit/Change any spending details if you wish to
  • Download your expenditure history in the CSV format
  • Visualize your spendings in the form of graphs/pie chart using the /chart option
  • Email the history CSV file to yourself
  • See the total daily/monthly expenditure in different currencies
  • Add/Delete members
  • Displays members
  • split bills across different
  • email splited bill to members involved
  • display splited bill
  • delete bills splited

Sample demos are shown below. They are run on a local machine.


⭐ Whats New

Release Version 1.3.1

  • Split a bill acrross different members using the /splitBill command
  • Email the bill splited to members involved using the /emailBill command
  • Display the bill history using the /viewSplitBill
  • Delete the bill by choosing the name of the bill by using /deleteBill
  • Details for testing requirements added in README.md
  • Add more test cases

Release Version 1.3.0

  • Add members using /addMember
  • Delete the member by choosing the name of the memebr by using /memberDelete
  • Display the members list by using the /memberList
  • Add more documentaions for the functions

🚀 Installation Guide

💻For developers

  1. Install Python, atleast Python3

  2. Clone this repository to your local system at a suitable directory/location of your choice

  3. Start a terminal session, and navigate to the directory where the repo has been cloned

  4. Run the following command to install the required dependencies:

  pip install -r requirements.txt
  1. Download and install the Telegram desktop application for your system from the following site: https://desktop.telegram.org/

  2. Once you login to your Telegram account, search for "BotFather" in Telegram. Click on "Start" --> enter the following command:

  /newbot
  1. Follow the instructions on screen and choose a name for your bot. Post this, select a username for your bot that ends with "bot" (as per the instructions on your Telegram screen)

  2. BotFather will now confirm the creation of your bot and provide a TOKEN to access the HTTP API - copy this token for future use.

  3. Search for "Edit the system environment variables" on your local computer. Click on Environment Variables and create a new System Variable called "API_TOKEN" and paste the token copied in step 8.

  4. In the Telegram app, search for your newly created bot by entering the username and open the same. Once this is done, go back to the terminal session. Make sure you export the PYTHONPATH variable to the main project folder

python src/bot.py
  1. A successful run will generate a message on your terminal that says "TeleBot: Started polling."
  2. Post this, navigate to your bot on Telegram, enter the "/start" or "/menu" command, and you are all set to track your expenses!

For more info on deployment(Heroku), check out the doc here

💻For testing with Pytest

  1. Some modules in testing require CHAT_ID environment variable to be set.
  2. This is the specific ID that is maintained for your chat with the Bot.
  3. While running the bot.py , get this id from line 72 and set it in your system environment variables.
  4. This should ensure effective running of all tests.

💁 Sample Demos

Add member

  1. Enter the /addMember command
  2. Enter the new new member name
  3. Enter the member email address

Delete member

  1. Enter the /memberDelete command
  2. Chose the name of the member

View memberList

  1. Enter the /memberList command

Split a bill

  1. Enter the /splitBill command
  2. Enter name of the bill
  3. Enter amount of the bill
  4. Chose Creditor
  5. Chose Debtors

View the splited bill

  1. Enter the /viewSplitBill command

Email the splited bill

  1. Enter the /emailBill command

Delete a splited bill

  1. Enter the /deleteBill command
  2. Chose the name of the bill to delete

Clear Bill history

I want to send myself an email for the monthly expenditure

  1. Enter the /clearBill› command

📄 License

This project is licensed under the terms of the MIT license. Please check License for more details.

Score Card


https://github.com/token1029/slashbot/blob/main/proj2/proj2rubric.md

✨ Contributors


Weizhi Gao


Fucheng Guo


Zikang Wang


Dongming Wu

📲 Support

For any support, email us at [email protected]

slashbot's People

Contributors

kingan1 avatar mtkumar123 avatar radhikaraman20 avatar sunidhihegde avatar annie0467 avatar ashwindasr avatar prakruthisomashekar avatar deekay2310 avatar pratikdevnani avatar themrshubh avatar snparab1704 avatar rakeshavm avatar renjiniravath avatar token1029 avatar kingbanshou avatar rohansinha96 avatar rahil1304 avatar itaru-shin avatar moksh98 avatar weizhigao avatar

Forkers

nidhaypancholi

slashbot's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.