Skip to main content

inbox-poll

Overview

Run a single poll cycle of the email inbox gateway. Connects to IMAP, fetches unread emails, authenticates senders against an allowlist, routes messages by subject keyword, validates attachments, dispatches to configured Python callables, and sends notification emails. Designed for cron scheduling. For continuous operation, use inbox-daemon which wraps this command in a polling loop.

Usage

python main.py inbox-poll [OPTIONS]

Options

OptionDescriptionDefault
-c, --configPath to inbox routes YAML configconfig/inbox/routes.yaml
--dry-runPreview processing without dispatching or sendingfalse
--validate-configValidate config without pollingfalse

Prerequisites

  • Repo: content-conductor
  • Install: pip install -r requirements.txt from repo root
  • Environment: INBOX_IMAP_HOST, INBOX_IMAP_USER, INBOX_IMAP_PASSWORD, INBOX_SMTP_HOST, INBOX_SMTP_USER, INBOX_SMTP_PASSWORD

Examples

Run a single poll cycle

python main.py inbox-poll

Dry run to preview

python main.py inbox-poll --dry-run

Validate route config only

python main.py inbox-poll --validate-config

Continuous daemon mode

python main.py inbox-daemon --interval 30
  • cc md2mail -- convert markdown to email clipboard