Skip to content

feat(feishu): add native update prompt cards#21911

Closed
heathley wants to merge 1 commit into
NousResearch:mainfrom
heathley:feat/feishu-update-prompt
Closed

feat(feishu): add native update prompt cards#21911
heathley wants to merge 1 commit into
NousResearch:mainfrom
heathley:feat/feishu-update-prompt

Conversation

@heathley

@heathley heathley commented May 8, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add native Feishu send_update_prompt support so gateway /update prompts use interactive Yes / No cards instead of plain-text fallback
  • handle card callbacks with adapter-owned resolution, including duplicate/resolved prompts, unauthorized clicks, and callback scheduling failures
  • persist update answers to Hermes's .update_response file and resolve the card inline
  • add update prompt card behavior and resolution flow to the Feishu messaging docs

What changed

  • added update prompt state tracking to the Feishu adapter
  • added Feishu card builders for update prompt and resolved states
  • added callback handling for hermes_update_prompt_action
  • added safe scheduling failure handling in the shared loop submission path
  • added authorization checks for interactive operators based on the existing Feishu allowlists/admin config
  • added update prompt card behavior and resolution flow to the Feishu messaging docs

Tests

Ran:

  • scripts/run_tests.sh tests/gateway/test_feishu_approval_buttons.py -q

Passing coverage includes:

  • send_update_prompt sends an interactive card
  • prompt state is stored after send
  • not-connected send path returns a failure result
  • Feishu send exception / timeout returns a failure result
  • update prompt callback returns a resolved Yes card
  • update prompt callback returns a resolved No card
  • missing update_prompt_id is ignored safely
  • already-resolved prompt callbacks return no card and do not reschedule work
  • callback scheduling failure returns no card
  • unauthorized operator clicks return no card and do not schedule work
  • resolver writes .update_response
  • resolver overwrites an existing .update_response file atomically
  • unknown prompt IDs are dropped silently

Notes

  • this keeps the existing Feishu approval flow pattern: interactive send, synchronous callback intercept, inline resolved card response, and async resolver side effects
  • authorization reuses the existing FEISHU_ALLOWED_USERS and Feishu admin config; no new config is required

JZKK720 pushed a commit to JZKK720/hermes-agent that referenced this pull request May 11, 2026
rmulligan pushed a commit to rmulligan/hermes-agent that referenced this pull request May 11, 2026
JinyuID pushed a commit to JinyuID/hermes-agent that referenced this pull request May 11, 2026
jsboige pushed a commit to jsboige/hermes-agent that referenced this pull request May 14, 2026
Egavasyug pushed a commit to Egavasyug/hermes-agent that referenced this pull request May 25, 2026
gweeteve pushed a commit to gweeteve/hermes-agent that referenced this pull request Jun 2, 2026
Egavasyug pushed a commit to Egavasyug/hermes-agent that referenced this pull request Jun 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant