diff --git a/swarm-common/obsidian-vault/will/will-shared-zap/Infrastructure/Automation/n8n Implementation Handoff.md b/swarm-common/obsidian-vault/will/will-shared-zap/Infrastructure/Automation/n8n Implementation Handoff.md index 6a082c6..8e6bed3 100644 --- a/swarm-common/obsidian-vault/will/will-shared-zap/Infrastructure/Automation/n8n Implementation Handoff.md +++ b/swarm-common/obsidian-vault/will/will-shared-zap/Infrastructure/Automation/n8n Implementation Handoff.md @@ -82,14 +82,17 @@ Last verified on 2026-05-13: ### Gmail Inbox Monitor + Obsidian Notes - Workflow ID: `whtdorf7yJMVYeHm` -- Status: active with warning -- Current issue: - - n8n startup logs still show a Gmail Trigger warning: `undefined`. +- Status: active, OAuth trigger replaced with IMAP fallback on 2026-05-13 +- Current behavior: + - Original Gmail OAuth trigger failed because the stored Google OAuth client secret is invalid; refresh returns `invalid_client`. + - The workflow now uses n8n `Email Trigger (IMAP)` against Gmail with the Hermes Gmail app-password credential `Gmail IMAP (Hermes App Password)`. + - Fetches unseen INBOX mail, marks processed mail read, and tracks last message ID. + - Local LLM and Obsidian REST calls use Docker bridge gateway `172.19.0.1` from inside the n8n container. + - Workflow export succeeds and no new `Gmail Trigger` warning appeared immediately after activation. - Remaining implementation: - - Inspect the Gmail Trigger node and credential state in the n8n UI/API. - - Confirm whether the trigger is actually receiving new mail. - - If the trigger is flaky, replace it with scheduled Gmail API polling or IMAP polling. - - Add the same triage classes and draft-reply behavior as the IMAP flow. + - Observe the next real Gmail ingestion event and confirm Telegram/Obsidian output shape. + - Re-authorize Google OAuth only if Gmail API-specific features are needed later; otherwise keep IMAP fallback. + - Add the same expanded triage classes and draft-reply behavior as the IMAP flow. ### Calendar to Obsidian Notes @@ -276,9 +279,9 @@ Recommended implementation: ## Recommended next order of work -1. Fix Gmail Trigger warning. - - Goal: no startup warning and confirmed Gmail ingestion. - - Fallback: replace trigger with scheduled polling. +1. Observe Gmail IMAP fallback. + - Goal: confirm the next real Gmail ingestion produces the expected Telegram digest and Obsidian note. + - If output shape is wrong, adjust the shared triage/formatting nodes; do not return to the broken OAuth trigger unless Google OAuth is re-authorized. 2. Add Docker health-state enrichment to Swarm Health Watchdog. - Prefer safe host-side helper over raw Docker socket mount.