{"id":17030507,"url":"https://github.com/barreeeiroo/barrepolicev1","last_synced_at":"2026-04-29T20:11:19.284Z","repository":{"id":104836069,"uuid":"84210761","full_name":"barreeeiroo/BarrePoliceV1","owner":"barreeeiroo","description":"BarrePolice V1 - Check BarrePoliceV2","archived":false,"fork":false,"pushed_at":"2017-07-20T12:22:32.000Z","size":1812,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-22T20:31:04.754Z","etag":null,"topics":["administration","bot","chat","lua","plugins","redis","telegram","telegram-bot"],"latest_commit_sha":null,"homepage":"https://github.com/Barreeeiroo/BarrePolice","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/barreeeiroo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-03-07T14:48:50.000Z","updated_at":"2023-09-08T17:21:55.000Z","dependencies_parsed_at":null,"dependency_job_id":"5d30fa74-1626-435f-9780-1552a868be7f","html_url":"https://github.com/barreeeiroo/BarrePoliceV1","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/barreeeiroo/BarrePoliceV1","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barreeeiroo%2FBarrePoliceV1","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barreeeiroo%2FBarrePoliceV1/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barreeeiroo%2FBarrePoliceV1/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barreeeiroo%2FBarrePoliceV1/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/barreeeiroo","download_url":"https://codeload.github.com/barreeeiroo/BarrePoliceV1/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/barreeeiroo%2FBarrePoliceV1/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32441734,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T18:12:22.909Z","status":"ssl_error","status_checked_at":"2026-04-29T18:11:33.322Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["administration","bot","chat","lua","plugins","redis","telegram","telegram-bot"],"created_at":"2024-10-14T08:07:11.970Z","updated_at":"2026-04-29T20:11:19.267Z","avatar_url":"https://github.com/barreeeiroo.png","language":"Lua","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BarrePolice\n\n## Short introduction\n\nThis bot has been created to help people administrate their groups, and includes many useful tools.\n\nBarre Police was born as an **GroupButler** [v3.1](https://github.com/topkecleon/otouto/tree/26c1299374af130bbf8457af904cb4ea450caa51) ([`@mokubot`](https://telegram.me/mokubot)), but it has been turned into an administration bot.\n\n#### Barre Police on Telegram:\n\n- [`@BarrePolice_Bot`](https://telegram.me/BarrePolice_Bot)\n    - **_branch_**: `master`\n    - **_channel_**: [`@Barreeeiroo_Ch`](https://telegram.me/Barreeeiroo_Ch)\n\n* * *\n\n## Setup\nList of required packages:\n- `libreadline-dev`\n- `redis-server`\n- `lua5.2`\n- `liblua5.2dev`\n- `libssl-dev`\n- `git`\n- `make`\n- `unzip`\n- `curl`\n- `libcurl4-gnutls-dev`\n\nYou will need some other Lua modules too, which can be (and should be) installed through the Lua package manager LuaRocks.\n\n**Installation**\n\nYou can easily install Group Butler by running the following commands:\n\n```bash\n# Tested on Ubuntu 16.04\n\n$ wget https://raw.githubusercontent.com/RememberTheAir/GroupButler/master/install.sh\n$ bash install.sh\n$ sudo chmod +x launch.sh\n```\n\nor\n\n```bash\n# Tested on Ubuntu 14.04, 15.04 and 16.04, Debian 7, Linux Mint 17.2\n\n$ sudo apt-get update\n$ sudo apt-get upgrade\n$ sudo apt-get install libreadline-dev libssl-dev lua5.2 liblua5.2-dev git make unzip redis-server curl libcurl4-gnutls-dev\n\n# We are going now to install LuaRocks and the required Lua modules\n\n$ wget http://luarocks.org/releases/luarocks-2.2.2.tar.gz\n$ tar zxpf luarocks-2.2.2.tar.gz\n$ cd luarocks-2.2.2\n$ ./configure; sudo make bootstrap\n$ sudo luarocks install luasec\n$ sudo luarocks install luasocket\n$ sudo luarocks install redis-lua\n$ sudo luarocks install lua-term\n$ sudo luarocks install serpent\n$ sudo luarocks install dkjson\n$ sudo luarocks install Lua-cURL\n$ cd ..\n\n# Clone the repository and give the launch script permissions to be executed\n# If you want to clone the beta branch, use git clone with the [-b beta] option\n\n$ git clone https://github.com/RememberTheAir/GroupButler.git\n$ cd GroupButler\n$ sudo chmod 777 launch.sh\n$ sudo chmod +x launch.sh\n```\n\nOther things to check before running the bot:\n\n**First of all, take a look at your bot settings:**\n\n\u003e • Make sure privacy is disabled (more info can be found by heading to the [official Bots FAQ page](https://core.telegram.org/bots/faq#what-messages-will-my-bot-get)). Send `/setprivacy` to [@BotFather](http://telegram.me/BotFather) to check the current status of this setting.\n\n**Before you do anything else, open config.lua (in a text editor) and make the following changes:**\n\n\u003e • Set `bot_api_key` to the authentication token that you received from [`@BotFather`](http://telegram.me/BotFather).\n\u003e\n\u003e • Insert your numerical Telegram ID into the `superadmins` table. Other superadmins can be added too. It is important that you insert the numerical ID and NOT a string.\n\u003e\n\u003e • Set your `log.chat` (the ID of the chat where the bot will send all the bad requests received from Telegram) and your `log.admin` (the ID of the user that will receive execution errors).\n\nBefore you start the bot, you have to start the Redis process.\n```bash\n# Start Redis\n\n$ sudo service redis-server start\n```\n\n## Starting the process\n\nTo start the bot, run `./launch.sh`. To stop the bot, press Control \u003ckbd\u003eCTRL\u003c/kbd\u003e+\u003ckbd\u003eC\u003c/kbd\u003e twice.\n\nYou may also start the bot with `lua bot.lua`, however it will not restart automatically.\n\n* * *\n## Something that you should known before run the bot\n\n  * You can change some settings of the bot. All the settings are placed in `config.lua`, in the `bot_settings` table\n    * `cache_time.adminlist`: the permanence in seconds of the adminlist in the cache. The bot caches the adminlist to avoid to hit Telegram limits\n    * `notify_bug`: if `true`, the bot will send a message that notifies that a bug has occured to the current user, when a plugin is executed and an error happens\n    * `log_api_errors`: if `true`, the bot will send in the `log_chat` (`config.lua`) all the relevant errors returned by an api request toward Telegram\n    * `stream_commands`: if `true`, when an update triggers a plugin, the match will be printed on the console\n  * There are some other useful fields that can be filled in `config.lua`\n    * `db`: the selected Redis database (if you are running Redis with the default config, the available databases are 16). The database will be selected on each start/reload. Default: 2\n  * Other things that may be useful\n    * Administrators commands start for `$`. They are not documented, look at the triggers of `plugins/admin.lua` plugin for the whole list\n    * If the main function of a plugin returns `true`, the bot will continue to try to match the message text with the missing triggers of the `plugins` table\n    * You can send yourself a backup of the zipped bot folder with the `$backup` command\n    * The Telegram Bot API has some undocumented \"weird behaviors\" that you may notice while using this bot\n       * In supergroups, the `kickChatMember` method returns always a positive response if the `user_id` has been part of the group at least once, it doesn't matter if the user is not in the group when you use this method\n       * In supergroups, the `unbanChatMember` method returns always a positive response if the `user_id` has been part of the group at least once, it doesn't matter if the user is not in the group or is not in the group blacklist\n\n\n## Some notes about the database\n\n*Everything* is stored on Redis, and the fastest way to edit your database is via the [Redis CLI](http://redis.io/topics/rediscli).\n\nYou can find a backup of your Redis database in `/etc/redis/dump.rdb`. The name of this file and the frequency of saves are dependent on your redis configuration file.\n\n* * *\n\n## Translators\nIf you want to help translate the bot, follow the instructions below. Parts of Group Butler use tools from [gettext](https://www.gnu.org/software/gettext/). However we don't use binary format `*.mo` for the sake of simplicity. The bot manually parses the `*.po` files in the `locales` directory.\n\nIf you want to improve an existing translation, run this command in the root\ndirectoy with the bot: `./launch.sh update-locale \u003cname\u003e` where \u0026lt;name\u0026gt;\nis two letters of your chosen locale. Further edit the file\n`locales/\u003cname\u003e.po`, make sure that the translation is done correctly and send\nus your translation.\n\nWe recommend [Poedit](https://poedit.net/) as editor of `*.po` files. You must\nspecify information about yourself in the settings; put your link to Telegram\naccount in the field Email if you have it.\n\nIf you want to create new locale, run `./launch.sh create-locale \u003cname\u003e`. This\ncommand create the file `locales/\u003cname\u003e.po` with untranslated strings. You can\nalso use Poedit to translate the bot. List of avaible locales see in [gettext\nmanual](https://www.gnu.org/software/gettext/manual/gettext.html#Language-Codes).\nAfter add your new locale in the file `config.lua`.\n\n* * *\n\n## Pull requests\n\nWe are still launching the bot for public use. Please, _be patient_\n\n* * *\n\n## Credits\n\n[RememberTheAir](https://github.com/RememberTheAir), for the original [GroupButler](https://github.com/RememberTheAir/GroupButler)\n\n[Topkecleon](https://github.com/topkecleon), for the original [otouto](https://github.com/topkecleon/otouto)\n\n[Wrxck](https://github.com/wrxck), for the [Mattata](https://github.com/wrxck/mattata) and lots of amazing plugins\n\n[Iman Daneshi](https://github.com/imandaneshi) and [Tiago Danin](https://github.com/TiagoDanin), for [Jack-telegram-bot](https://github.com/Imandaneshi/jack-telegram-bot)\n\n[Cosmonawt](https://github.com/cosmonawt), for his [Lua library](https://github.com/cosmonawt/lua-telegram-bot) for the Bot API\n\n[Yago Pérez](https://github.com/yagop) for his [telegram-bot](https://github.com/yagop/telegram-bot)\n\nThe [Werewolf](https://github.com/parabola949/Werewolf) guys, for aiding the spread of the bot\n\nLucas Montuano, for helping me a lot in the debugging of the bot\n\nAll the Admins of our [discussion groups](https://telegram.me/gbgroups) about Group Butler\n\nAll the people who reported bugs and suggested new stuffs\n\nIcons made by [Roundicons](http://www.flaticon.com/authors/roundicons) from [Flaticon](https://flaticon.com) is licensed by [Creative Commons BY 3.0](http://creativecommons.org/licenses/by/3.0/)\n\nLe Laide\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbarreeeiroo%2Fbarrepolicev1","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbarreeeiroo%2Fbarrepolicev1","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbarreeeiroo%2Fbarrepolicev1/lists"}