Giter Club home page Giter Club logo

imynzul / telegram-bot-web-app Goto Github PK

View Code? Open in Web Editor NEW
2.0 0.0 0.0 80 KB

Telegram-messenger bot that is able to give info about main european capitals - the general info about the city and which places to visit. Is able to get city name from the user's message and gibe info about this city. All the cities and information is being kept in the database. Also there api methods to add, edit and remove cirty/info from the database.

Java 100.00%
javaee java database sql mysql spring mvc springboot hibernate maven

telegram-bot-web-app's Introduction

Telegram Bot app&Api Web-service

Telegram Bot gives user all the main information about most popular european capitals. It reads the name of the city from the user's message and tells some general info about the city. Works with database where info is being kept. With api web-service you are able to add, edit and remove cities and info from the database.

INSTALLATION

Download zip archive with the files. Please make sure the release file is unpacked under a Web-accessible directory. You shall see the following files and directories:

  .mvn               maven wrapper
  api                api web-service
  datasource         database 
  tgbot              telegram-bot app
  .gitignore         list-ignore source
  mnvw               maven wrapper doc
  mvnw.cmd           maven wrapper executable file
  pom.xml            config file
  README.md          this file

REQUIREMENTS

The minimum requirements - next should be installed on your PC:

  • Google Chrome
  • MySQL
  • JDK 1.8+

QUICK START

To start up the telegram bot you need - On command line, you need to type in the following commands from the project root:

   1. mvnw clean install
   2. java -jar tgbot\target\tgbot-0.1-jar-with-dependencies.jar

Telegram Bot name: @CityInfoTestBot

Telegram Bot token: 639836817:AAFGrwA9j0nT8B6kv0sUPAOzErQoUmF32hI

To start up the API service you need:

  • If you have already started up the telegram bot below, all you need. On command line, you need to type in the following commands from the project root:

     1. java -jar api\target\api-exec.jar
    
  • If you haven't started up the telegram bot, you need to do next. On command line, you need to type in the following commands from the project root:

     1. mvnw clean install 
     2. java -jar api\target\api-exec.jar
    

WHAT's NEXT

To test the bot - log into telegram app, find bot by it's name and press start-button to join the conversation

Api Methods:

/api/getall - return list of all the cities and their info

/api/save - save new city and info to the DB

/api/update - update info about the existing city in the database

/api/delete - delete city and it's info from the database

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.