{
  "ConnectionStrings": {
    "DefaultConnection": "Host=mailarchiver_postgres_1;Database=mailarchiver;Username=mailarchiver;Password=mailarchiver"
  },
  "Authentication": {
    "Username": "admin",
    "Password": "secure123!",
    "SessionTimeoutMinutes": 60,
    "CookieName": "MailArchiverAuth",
    "CookieSameSite": "Strict"
  },
  "OAuth": {
    "Enabled": false,
    "Authority": "",
    "ClientId": "",
    "ClientSecret": null,
    "ClientScopes": [
      "openid",
      "profile",
      "email"
    ],
    "DisablePasswordLogin": false,
    "AutoRedirect": false,
    "AutoApproveUsers": false,
    "AdminEmails": []
  },
  "MailSync": {
    "IntervalMinutes": 15,
    "TimeoutMinutes": 120,
    "ConnectionTimeoutSeconds": 300,
    "CommandTimeoutSeconds": 600,
    "AlwaysForceFullSync": false,
    "IgnoreSelfSignedCert": false
  },
  "BatchRestore": {
    "AsyncThreshold": 50,
    "MaxSyncEmails": 150,
    "MaxAsyncEmails": 50000,
    "SessionTimeoutMinutes": 30,
    "DefaultBatchSize": 50
  },
  "Selection": {
    "MaxSelectableEmails": 250
  },
  "View": {
    "DefaultToPlainText": true,
    "BlockExternalResources": true
  },
  "BatchOperation": {
    "BatchSize": 50,
    "PauseBetweenEmailsMs": 50,
    "PauseBetweenBatchesMs": 200
  },
  "TimeZone": {
    "DisplayTimeZoneId": "Etc/UCT"
  },
  "DatabaseMaintenance": {
    "Enabled": true,
    "DailyExecutionTime": "02:00",
    "TimeoutMinutes": 30
  },
  "Upload": {
    "MaxFileSizeGB": 10,
    "KeepAliveTimeoutHours": 4,
    "RequestHeadersTimeoutHours": 2,
    "Notes": "Optimized for large file uploads up to 10GB"
  },
  "Npgsql": {
    "CommandTimeout": 900
  },
  "Logging": {
    "LogLevel": {
      "Default": "Information",
      "Microsoft.AspNetCore": "Warning",
      "Microsoft.EntityFrameworkCore.Database.Command": "Warning"
    }
  },
  "AllowedHosts": "*"
}
