Skip to content

feat: add admin report callback for join requests#30

Open
TheOnlyOne001 wants to merge 1 commit into
birlug:mainfrom
TheOnlyOne001:codex/admin-report-spammer-button
Open

feat: add admin report callback for join requests#30
TheOnlyOne001 wants to merge 1 commit into
birlug:mainfrom
TheOnlyOne001:codex/admin-report-spammer-button

Conversation

@TheOnlyOne001
Copy link
Copy Markdown

Summary

  • Add a Report inline button to join-request challenge messages
  • Verify the tapping user is a group admin with getChatMember before accepting a report
  • Persist each report as an append-only Cloudflare KV record keyed by chat, reported user, timestamp, and reporter for future export
  • Answer callback queries for success, non-admin taps, and admin verification failures

Notes

Telegram inline keyboards are rendered the same way for every viewer in a group, so the bot cannot make a button visually appear only for admins. This PR enforces the admin-only requirement at the bot/API boundary before writing anything to KV.

Fixes #26

Validation

  • cargo fmt --all -- --check
  • cargo check
  • cargo test
  • cargo check --target wasm32-unknown-unknown
  • git diff --check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

admin "report" button to flag spammers

1 participant