Skip to main content

A telegram bot for keel.sh

Project description

keel-telegram-bot Build Status PyPI version

keel-telegram-bot is a telegram bot for Keel.

Features

  • Receive notifications (via Webhook)
  • List approvals
  • Approve pending approvals
  • Reject pending approvals
  • Delete archived approvals

How to use

Manual installation

Install

Install keel-telegram-bot using pip:

pip3 install keel-telegram-bot

Configuration

keel-telegram-bot uses container-app-conf to provide configuration via a YAML file as well as ENV variables. Have a look at the documentation about it.

See keel-telegram-bot_example.yaml for an example in this repo.

Run

Start the bot by using:

keel-telegram-bot

Docker

To run keel-telegram-bot using docker you can use the markusressel/keel-telegram-bot image from DockerHub:

sudo docker run -t \
    markusressel/keel-telegram-bot:latest

Configure the image using either environment variables, or mount the configuration file from your host system to /app/keel-telegram-bot.yaml.

Setup

This bot uses the REST api provided by Keel to interact with it and relies on the Webhook functionality to receive and forward notifications to telegram chats. On one hand keel-telegram-bot acts like the web interface, on the other hand it acts like a proxy, both combined into a single package.

To get the commands working simply provide all the necessary details of the configuration file.

To get notifications working you will have to provide the address of keel-telegram-bot to Keel using the WEBHOOK_ENDPOINT env variable. The simplest way to achieve this is by running both Keel and keel-telegram-bot on the same host and specifying http://localhost:5000/.

Contributing

GitHub is for social coding: if you want to write code, I encourage contributions through pull requests from forks of this repository. Create GitHub tickets for bugs and new features and comment on the ones that you are interested in.

License

keel-telegram-bot by Markus Ressel
Copyright (C) 2020  Markus Ressel

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

keel-telegram-bot-1.2.0.tar.gz (26.1 kB view details)

Uploaded Source

Built Distribution

keel_telegram_bot-1.2.0-py3-none-any.whl (30.8 kB view details)

Uploaded Python 3

File details

Details for the file keel-telegram-bot-1.2.0.tar.gz.

File metadata

  • Download URL: keel-telegram-bot-1.2.0.tar.gz
  • Upload date:
  • Size: 26.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for keel-telegram-bot-1.2.0.tar.gz
Algorithm Hash digest
SHA256 0443eb22b1d0b4995153e2f248c929e4eb0986f7c0ce86e1da4af3a543a2d66b
MD5 910a80a3260c9f71e8a431313479f18f
BLAKE2b-256 1295c4eb603b21ca8d48284d1198b3d263ef47a08e97e3497b14c66b9a0fa554

See more details on using hashes here.

File details

Details for the file keel_telegram_bot-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: keel_telegram_bot-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 30.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.8.2

File hashes

Hashes for keel_telegram_bot-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 36caee5dc955b15a1f625b2f7d4aa3d1db973a361c48b337459d9eb62d4e2fb7
MD5 00382b68e59a322937eacddfedcaa3bf
BLAKE2b-256 ff69c07e01bc24f6cdcf628bb7d95d6e1d208c8271fda0daa6f4ab944d89d92b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page