Search documentation of phoenix_kit

# mix phoenix_kit.email.stats (phoenix_kit v1.6.19)

View Source

Mix task to display comprehensive email system statistics.

## Usage

    # Show default stats (last 30 days)
    mix phoenix_kit.email.stats

    # Show stats for specific date range
    mix phoenix_kit.email.stats --from 2025-01-01 --to 2025-01-31

    # Show stats for specific campaign
    mix phoenix_kit.email.stats --campaign welcome-series

    # Show detailed breakdown
    mix phoenix_kit.email.stats --detailed

## Options

    --from DATE           Start date (YYYY-MM-DD format)
    --to DATE             End date (YYYY-MM-DD format)
    --campaign ID         Show stats for specific campaign
    --detailed            Show detailed breakdown by provider/template
    --format FORMAT       Output format: table (default), csv, json

## Examples

    # Last 7 days summary
    mix phoenix_kit.email.stats --from $(date -d '7 days ago' '+%Y-%m-%d')

    # Export campaign stats to CSV
    mix phoenix_kit.email.stats --campaign newsletter --format csv > campaign_stats.csv

    # Detailed breakdown with provider performance
    mix phoenix_kit.email.stats --detailed