howl/.env.example

61 lines
1.8 KiB
Text
Raw Normal View History

# =============================================================
# Howl - M365 Email Management Daemon
# Copy this file to .env and fill in your values.
# =============================================================
# --- Microsoft Azure / Graph ---
AZURE_TENANT_ID=your-tenant-id
AZURE_CLIENT_ID=your-app-client-id
AZURE_CLIENT_SECRET=your-app-client-secret # Required for client_credentials mode only
# Auth mode: client_credentials (shared/app-only) or delegated (personal mailbox)
GRAPH_AUTH_MODE=client_credentials
# Path to MSAL token cache (delegated mode only — persists refresh token across restarts)
MSAL_TOKEN_CACHE_PATH=.msal_cache.bin
# Mailbox to monitor (UPN or shared mailbox address)
GRAPH_MAILBOX=shared@yourcompany.com
# Poll interval in seconds (default: 5 minutes)
GRAPH_POLL_INTERVAL_SECONDS=300
# Number of messages to fetch per poll cycle
GRAPH_BATCH_SIZE=50
# Max characters of email body sent to LLM (truncated beyond this)
GRAPH_MAX_BODY_CHARS=4000
# --- Anthropic ---
ANTHROPIC_API_KEY=sk-ant-your-key-here
ANTHROPIC_MODEL=claude-sonnet-4-6
ANTHROPIC_MAX_TOKENS=1024
# Confidence threshold: below this value → inbox_keep + requires_human_review
LLM_CONFIDENCE_THRESHOLD=0.60
# --- PostgreSQL ---
DATABASE_URL=postgresql+asyncpg://user:password@localhost:5432/howl
DATABASE_POOL_SIZE=5
DATABASE_POOL_MAX_OVERFLOW=10
# --- Processing ---
# Set to true to analyze emails but take no actions (safe for testing)
DRY_RUN=false
MAX_RETRY_COUNT=3
# Optional: Teams or Slack incoming webhook URL for escalation notifications
NOTIFICATION_WEBHOOK_URL=
# --- Mail Folder Names (Graph display names) ---
FOLDER_CUSTOMERS=Customers
FOLDER_VENDORS=Vendors
FOLDER_REVIEW=Needs Review
FOLDER_SPAM=Junk Email
FOLDER_ESCALATE=Escalate
# --- Logging ---
LOG_LEVEL=INFO
# json (structured, for production) or text (human-readable, for development)
LOG_FORMAT=json