Code Monkey home page Code Monkey logo

telegram-expense-bot's Introduction

#TODO https://github.com/gbrian/bibot

https://medium.com/@fasihxkhatib/a-bot-to-keep-track-of-your-expenses-b7b1c7e71b00

https://github.com/python-telegram-bot/python-telegram-bot

https://www.codementor.io/garethdwyer/building-a-telegram-bot-using-python-part-1-goi5fncay

https://github.com/python-telegram-bot/python-telegram-bot/wiki/Code-snippets

https://hackernoon.com/serverless-telegram-bot-on-aws-lambda-851204d4236c

telegram-expense-bot

This is a bot for the Telegram messaging app using their bot platform. The code is open-source and consequently anybody could set up an own instance of the bot. To learn how to do so, see this section. The official hosted version is available as @ExpenseBot. To learn more about this bot, please refer to this blog article or just send the bot a message with the /help command.

What does it do?

This bot’s purpose is to help people manage their daily expenses and keep track of their financial situation. Users can add expenses from wherever they are using a few simple commands from within the chat and have an eye on how much they have spent in a month or a day. This obviates the need for confusing Excel spreadsheets or paper notes.

How to host it myself?

Prerequisites

In order to host this bot on your own, you need a few things.

  • Server to run the bot on (since the bot uses the long polling method to get updates instead of the web-hook one, you don't need HTTPS certificates or ports to be exposed)
  • Node.js (preferbly at the latest version)
  • A MongoDB database (you can use mlab.com to get a free, hosted MongoDB)
  • A bot token, which you get from registering a new bot to the @BotFather

Configuration

To configure your bot, clone this repository and then edit config.json file.

  • DB_URL: your MongoDB's complete URL including hostname, port, username, password and database name (if using mlab, you can simply copy this from their website)
  • DB_COLLECTION: the name of the database collection where your data should be stored, e.g. "expenses_live"
  • BOT_TOKEN: the token you got from the BotFather
  • BOT_NAME: the bot's name, e.g. "ExpenseBot" in my case
  • BOT_TELEGRAM_USERNAME: the bot's actual unique Telegram username, e.g. "@ExpenseBot" in my case (note that this can differ from the BOT_NAME, which is not unique)

Run

$ npm start

License

MIT @ Ferdinand Mütsch

telegram-expense-bot's People

Contributors

kduy avatar muety avatar

Watchers

James Cloos avatar  avatar

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.