Conversation
- Move hardcoded Tenor API key to config (TENOR_API_KEY) - Fix restrict_chat_member arg order in wordfilter, join_captcha (permissions as 3rd arg, opts as 4th); replace deprecated permission names with modern granular permissions - Fix UTF-8 iteration in flip.lua and aesthetic.lua using proper codepoint pattern instead of byte-level iteration - Replace blocking socket.sleep with copas.pause in purge plugin; batch message deletion using delete_messages API (groups of 100) - Fix callback_query handler creating empty chat context for inline buttons; now creates minimal valid context with sender's ID and private type - Fix config parser stripping inline # comments from quoted .env values - Implement SpamWatch API integration in blocklist middleware with Redis caching (was dead code stub)
- about.lua: use BOT_ADMINS[1] for owner ID instead of hardcoded value - help.lua: read CHANNEL_URL, SUPPORT_URL, GITHUB_URL, DEV_URL from config with current values as defaults - main.lua: register bot command menu on startup via set_my_commands, with separate admin-scoped command list for group administrators - id.lua: add premium status, profile photo count, bot flag, forum status, linked chat, hidden members, and anti-spam fields - .env.example: add new optional config keys for bot links
Add handler functions and api.run() wiring for: - chat_join_request: approve/decline join requests via plugins - chat_member: member status changes (promoted, left, etc.) - my_chat_member: bot's own status changes (added/removed/promoted) - message_reaction: emoji reaction changes on messages - poll: poll state changes (closed, etc.) - poll_answer: individual user votes on polls - chat_boost / removed_chat_boost: boost/unboost events - message_reaction_count: anonymous reaction counts Each handler uses a lightweight context builder (no full middleware pipeline) and dispatches to plugin hooks following the same pcall + error logging pattern as existing handlers. Also fixes callback_query handler to create valid chat context for inline button callbacks (was creating empty chat object).
- unpinall: unpin all messages via api.unpin_all_chat_messages - chatinfo: /settitle and /setdescription for chat metadata - customtitle: set admin custom titles (16 char limit) - slowmode: control slow mode delay (off/10s/30s/1m/5m/15m/1h) - topic: forum topic management (create/close/reopen/delete/rename) - joinrequest: configurable join request policy (auto-approve, auto-reject, manual with approve/reject buttons); hooks into on_chat_join_request router event - chatpermissions: inline keyboard UI to toggle default chat permissions with live updates via set_chat_permissions
- poll: create polls and quizzes via /poll and /quiz with pipe-separated options; uses native Telegram poll API with quiz mode support - react: reply to messages with /react <emoji> to set reactions via set_message_reaction API; auto-deletes command message - boosts: view user boost count in chat, hooks on_chat_boost to send notification when chat receives a new boost - bulkops: /forward and /copy commands to forward/copy replied messages to target chats using forward_messages/copy_messages API
Rate limiting: - Add Redis-based rate limiting for callback queries (5/3s per user) with toast notification on rate limit hit - Add Redis-based rate limiting for inline queries (3/2s per user) with silent drop on rate limit hit Opts-based migration (priority plugins): - help.lua: migrate all send_message/edit_message_text calls from positional args to opts table format - about.lua: migrate send_message to opts - id.lua: migrate send_message to opts - wordfilter.lua: migrate send_message calls to opts - join_captcha.lua: migrate send_message to opts - gif.lua: migrate send_message to opts This eliminates deprecation warnings from the telegram-bot-lua compat layer for these high-traffic plugins.
…ization - Add async HTTP module (src/core/http.lua) for non-blocking plugin requests - Replace all inline SQL with PostgreSQL stored procedures - Add 13 new plugins: autodelete, customcaptcha, slowmode, topic, poll, reactions, qr, bookmark, growth, inline, paste, rss, schedule - Modernize all API calls to opts-based pattern - Expand router with 8 new event hooks (reactions, polls, boosts, etc.) - Add migration 006 for import procedures - Add docker-compose.matticate.yml for second bot instance - Update docs, rockspec, and plugin counts for v2.2
feat(v2.2): async HTTP, stored procedures, 13 new plugins
fix(content): configurable links, command menu, enhanced /id
# Conflicts: # src/plugins/admin/join_captcha.lua # src/plugins/admin/purge.lua # src/plugins/admin/wordfilter.lua
fix(core): resolve multiple bugs across plugins and middleware
# Conflicts: # src/core/router.lua
feat(router): handle 9 new Telegram update types
# Conflicts: # src/core/router.lua # src/plugins/admin/init.lua # src/plugins/admin/slowmode.lua # src/plugins/admin/topic.lua
# Conflicts: # src/core/router.lua # src/plugins/admin/init.lua # src/plugins/fun/init.lua # src/plugins/utility/init.lua
# Conflicts: # src/core/router.lua # src/plugins/admin/join_captcha.lua # src/plugins/utility/help.lua
- Remove duplicate stub handler functions in router.lua - Remove undefined on_message_reaction_count reference - Replace unused variables (code, status, err) with _ in 18 plugins - Remove unused PERMANENT_PLUGINS variable from loader.lua - Fix global assignment _ in database.lua - Break long line in customcaptcha.lua
fix(lint): resolve all luacheck warnings across codebase
# Conflicts: # src/core/router.lua
# Conflicts: # src/core/router.lua
feat(admin): add 7 new admin plugins
# Conflicts: # src/plugins/admin/init.lua
feat(plugins): add poll, react, boosts, and bulk ops
feat(framework): rate limiting and opts-based API migration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Release v2.2.0 — merging develop into main.
See release notes for full changelog.
Highlights