Skip to content

kaushikjadhav01/SmartSpend

Repository files navigation

SmartSpend

MIT license GitHub GitHub contributors DOI Platform Python CI


About SmartSpend

SmartSpend 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
  • Set limits for your daily/montly/yearly expenses
  • Search the best deals for your purchase
  • Share/Settle your expense with other users

Additions:

  • Fixed several bugs related to parsing and tracking.
  • Refactored old code to suit updated structure.
  • Moved away from Travis to GitHub actions for rolling builds.
  • Feature -> Upgrade backend to use Mongo DB for better storage and access.
    • Supports cloud based central storage as well as locally hosted database.
    • Allows for free extensions since the data is stored in Object model.
  • Feature -> Add 'share' feature to share expense with other telegram users.
    • Sends a notification message to the other user indicating the added expense.
    • Added persistent storage for future tracking and settlement of balances.
  • Feature -> Add 'limit' faeture to work as an alarm when spending exceed preset limits.
    • Users can create limits on a daily, monthly, and yearly basis.
    • When user adds an expense, all three limits are checked.

Demo

ezgif-7-8b0f47b17890.mp4

New Functionality

smart_spend.1.mp4

Installation guide

The below instructions can be followed in order to set-up this bot at your end in a span of few minutes! Let's get started:

  1. This installation guide assumes that you have already installed Python (Python3 would be preferred)

  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. Create a new collection in MongoDB Cloud Atlas. In the directory where this repo has been cloned, create a .env file with format like .env.sample in this repo and replace XXXX with the actual bot name, tokens and api hash and MongoDB URLs:

  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. Navigate to the directory containing the "code.py" file and run the following command:

  python code.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!

--------------------------------------------------------------------------------------------------

Title:'SmartSpend'

Version: '1.0'

Description: 'An easy to use Telegram Bot to track everyday expenses'

Authors:'Kaushik, Surya, Pradyumna, Harshitha, Aditi'

--------------------------------------------------------------------------------------------------

About

No description, website, or topics provided.

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages