Skip to content

Phase 3: unified webhook follow-ups #1172

Description

@chaodu-agent

Follow-up items from PR #1171 (unified webhook runtime)

Tracked items from group review — non-blocking improvements for the unified webhook path.

Tasks

  • Add GATEWAY_ALLOW_BOT_MESSAGES / GATEWAY_TRUSTED_BOT_IDS envprocess_gateway_event() currently drops all bot messages; multi-agent scenarios need trusted bot passthrough.
  • Wire Google Chat in unified mode — Currently google_chat: None with TODO; needs SA key parsing + JWT verifier initialization.
  • Deduplicate event processing logicprocess_gateway_event() and run_gateway_adapter() share filtering/dispatch logic that should be extracted into a shared helper.
  • Extract AppState::from_env() factory — Avoid unified/standalone config divergence by sharing initialization.
  • Document production-must-set env varsGATEWAY_ALLOW_ALL_CHANNELS, GATEWAY_ALLOW_ALL_USERS default fail-open; flag in Helm/deploy docs.
  • Add user-facing fallback when create_thread fails — Server-side tracing::warn added; user-facing message removed due to ordering issues on Telegram/LINE (warning appeared before reply). Needs a deferred-message approach to show after reply.
  • Log when audio attachment path/data both empty — Currently silent skip with no trace.

Context

cc @pahudnet

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions