Settings

AI provider, email templates, property defaults, and automation thresholds

AI Provider

Selects which API is used for inbox classification and automation tasks. Provider, model, and key are stored in the database — never hardcoded.

A
Anthropic
Claude models
OpenAI
GPT models
OpenRouter
100+ models
Select a provider above
Override only if using a proxy or self-hosted endpoint

Current Configuration

Loading…

Email Classification AI (optional override)

Configure a separate, cheaper model for email classification. Uses a 3-tier pipeline: rules first (free), then AI on headers only, then AI on body snippet. If not set, falls back to the global AI settings above.

OCR Configuration (Mistral)

Configure Mistral for document OCR. Used by the AI Ingest pipeline to extract text from PDFs and images.

Override only if using a proxy or self-hosted endpoint

OneDrive Connection (document backup)

Mirror uploaded documents to a OneDrive folder for offline access. Optional — R2 is the source of truth.

Checking...

Gmail Connection

Connect the 9255WAlameda@thebakkens.net Gmail account for sending automated emails and ingesting inbox messages.

Checking...

How It Works

  1. Click Connect Gmail to start the Google OAuth flow
  2. Sign in with 9255WAlameda@thebakkens.net
  3. Grant permission for send + read access
  4. The refresh token is stored in the database (not browser)
  5. The worker uses it to send automated emails and ingest the inbox

Requires GMAIL_CLIENT_ID and GMAIL_CLIENT_SECRET to be set as worker secrets. The OAuth flow stores a refresh token in D1, which takes priority over the wrangler secret.

Email Templates

Customize the body of automated tenant emails. Use {{variable}} placeholders — each template lists available variables below the editor. Blank = use built-in default.

Variables: {{unit_number}} {{effective_date}}
Variables: {{first_name}} {{unit_number}} {{end_date}} {{effective_date}} {{term}}
Available variables (full body override only): {{tenant_name}}   {{unit_number}}   {{building_name}}   {{end_date}}   {{renewal_notice_days}}   {{renewal_option_periods}}
Available variables: {{tenant_name}}   {{unit_number}}   {{building_name}}   {{end_date}}   {{days_left}}
Available variables: {{tenant_name}}   {{unit_number}}   {{building_name}}   {{current_rent}}   {{new_rent}}   {{effective_date}}   {{days_until}}
Available variables: {{tenant_name}}   {{unit_number}}   {{building_name}}   {{year}}   {{cam_amount}}   {{cam_method}}   {{cam_rate}}   {{sqft}}
Available variables: {{tenant_name}}   {{unit_number}}   {{building_name}}   {{expiry_date}}   {{days_left}}   {{liability_min}}   {{umbrella_min}}

Landlord & Property Information

These values are used when generating lease documents.

Lease Defaults

Automation Thresholds

Configure when automations trigger. Leave blank to use defaults.

Deadline Rules

Rules that generate service tickets when tenant deadlines are approaching. Toggle active/inactive or edit rule parameters.

Loading…