Diagnostics Flags
Diagnostics flags let you enable targeted debug logs without turning on verbose logging everywhere. Flags are opt-in and have no effect unless a subsystem checks them.
How it works
- Flags are strings (case-insensitive).
- You can enable flags in config or via an env override.
- Wildcards are supported:
telegram.*matchestelegram.http*enables all flags
Enable via config
json{ "diagnostics": { "flags": ["telegram.http"] } }
Multiple flags:
json{ "diagnostics": { "flags": ["telegram.http", "gateway.*"] } }
Restart the gateway after changing flags.
Env override (one-off)
bashMAYROS_DIAGNOSTICS=telegram.http,telegram.payload
Disable all flags:
bashMAYROS_DIAGNOSTICS=0
Where logs go
Flags emit logs into the standard diagnostics log file. By default:
/tmp/mayros/mayros-YYYY-MM-DD.log
If you set logging.file, use that path instead. Logs are JSONL (one JSON object per line). Redaction still applies based on logging.redactSensitive.
Extract logs
Pick the latest log file:
bashls -t /tmp/mayros/mayros-*.log | head -n 1
Filter for Telegram HTTP diagnostics:
bashrg "telegram http error" /tmp/mayros/mayros-*.log
Or tail while reproducing:
bashtail -f /tmp/mayros/mayros-$(date +%F).log | rg "telegram http error"
For remote gateways, you can also use mayros logs --follow (see /cli/logs).
Notes
- If
logging.levelis set higher thanwarn, these logs may be suppressed. Defaultinfois fine. - Flags are safe to leave enabled; they only affect log volume for the specific subsystem.
- Use /logging to change log destinations, levels, and redaction.