Admin Logging
Track all admin and bot actions with detailed logs. Know exactly what happened, when, and by whom.
Overview
The logging system records all moderation actions to a database. Logs can be filtered by admin, target user, action type, or timeframe.
You can also configure logs to be sent to a dedicated channel for real-time monitoring.
What Gets Logged
Moderation Actions
- • kick
- • ban
- • unban
- • mute
- • unmute
- • warn
Automated Actions
- • link_blocked
- • media_blocked
- • content_filtered
- • flood_detected
- • verification_timeout
Log Entry Structure
| Field | Description |
|---|---|
| id | Unique log entry ID |
| group_id | Group where action occurred |
| admin_id | Admin/bot that performed action |
| target_id | User action was performed on (optional) |
| action | Action type (kick, ban, warn, etc.) |
| reason | Reason/details for the action |
| timestamp | UTC timestamp of action |
Query Options
Recent Logs
Get the most recent N logs for the group (default: 10).
Logs by Admin
Filter logs by the admin who performed the action.
Logs by Target
Find all actions taken against a specific user.
Logs by Action
Filter by action type (e.g., all bans, all warnings).
Logs by Timeframe
Get all logs from the last N hours (default: 24 hours).
Mini App Access
Open /app → Logs
The LogsView in the Mini App shows a paginated list of admin actions with filters for timeframe and action type. Each entry shows the action, admin, target, reason, and timestamp.
Bot Commands
/logsView recent admin logs/logs @userView logs for specific user/logs exportExport logs as file