mayros analytics
Manage opt-in usage analytics. View the current analytics status and force-flush buffered events. Analytics is disabled by default and requires explicit opt-in via configuration.
Subcommands
analytics status
Show the current analytics status including:
- Enabled/disabled state
- Privacy mode (anonymous or identified)
- Endpoint (remote delivery URL or local-only)
- Buffer size (number of buffered events)
- Failure count (consecutive delivery failures)
analytics flush
Force-flush all buffered events immediately. Reports the number of events flushed. If a remote endpoint is configured, events are delivered via POST request.
Configuration
Analytics is controlled by the analytics section in mayros.toml:
| Key | Description |
|---|---|
enabled | Enable analytics collection (default: false) |
privacyMode | anonymous (hashes session IDs) or identified |
endpoint | Remote endpoint URL for event delivery (optional) |
maxBufferSize | Maximum events to buffer before flushing |
flushIntervalMs | Flush interval in milliseconds |
eventTtlMs | Time-to-live for buffered events |
Analytics can also be disabled system-wide by setting MAYROS_ANALYTICS_DISABLED=1.
Examples
bashmayros analytics status mayros analytics flush
Related
- Architecture — system overview and extension model