GithubHelp home page GithubHelp logo

gopavasanth / vayumalinyabot Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 1.0 620 KB

If you send me your current location, I\'ll see if I can find any data on air pollution in your area. You can also send me the name of a place or an address that you are interested in and I\'ll see if I can find any data for you. Data comes from https://openaq.org/, a great platform for open air quality data. Recommended levels taken from WHO guideline http://www.who.int/. \n\n Please also try these commands /help /owner t.me/vayumalinyabot

Home Page: http://t.me/vayumalinyabot

License: MIT License

JavaScript 99.57% Procfile 0.43%

vayumalinyabot's Introduction

vayumalinyabot Bot

About

This is a Bot for the Telegram instant messaging service that sends you air quality data retrieved from openaq.org. It answers when you send it your current location or the name of a place that you want to know about.

Get started

This bots runs in Telegram. If you just want to try it out go to t.me/vayumalinyabot. If you want to run the bot on your own server download the code and run the npm start task. You will have to set up the following environment variables to make it run properly:

APP_URL public url where your server can be reached

GOOGLE_GEOCODING_API_KEY an api key for the google geocoding api (it might actually run without it but you will be restricted to a small number of calls per minute)

TELEGRAM_TOKEN the api token of your telegram bot.

Tech

This bot runs as a minimalistic node.js server that receives the Telegram messages send to it as POST requests. If a location is sent, it simply looks up the latest data for the given coordinates in a 25 km radius. If an address is sent, it fist calls the Google Maps Geocoding API (https://developers.google.com/maps/documentation/geocoding) to get the coordinates for the address. The bot returns only data more recent than 3 days and preferres measurements close to the given coordinates.

vayumalinyabot's People

Contributors

gopavasanth avatar gopavasanth-sap 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.