22-ai-00/dsh-enhanced--plugins-lark-channel ↗★ 2
@dsh-enhanced/lark-channel
A thin Feishu/Lark WebSocket adapter for the durable DSH assistant-delivery core.
安装
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:22-ai-00/dsh-enhanced#bb3fb924f1bdb946901614b8b848ac3a1d60c642&path:plugins/lark-channel说明文档
阅读完整 README ↗最小配置
不使用向导时,可在 profile patch 中配置:
config:
enabled: true
account: personal-bot
tenant: personal
appId: cli_0123456789abcdef
credentialHandle: lark-app-secret
credentialPurpose: connect
credentialLeaseMs: 86400000
# Calendar API stays unavailable unless every ID is explicitly listed.
allowedCalendarIds: []
domain: feishu
requireMentionInGroups: true
showProgress: true
progressDetails: direct
statusReactions: true
imageDownloadTimeoutMs: 30000
userQuestionTtlMs: 86400000
credentialHandle 应由 @dsh-enhanced/credentials-keychain 提供,并只允许 consumer dsh-enhanced-lark-channel、purpose connect。兼容部署可改用 appSecretEnv,两者只能选一个;配置不接受 appSecret 等明文字段。
Calendar v4 读取默认关闭;每页响应上限为 1 MiB,超限请求失败且不推进事件游标。只有同时满足以下条件时,连接器才会读取一个页面:该 ID 位于 allowedCalendarIds、应用已被授予并发布 calendar:calendar:readonly、调用方已通过自身的 owner/Policy 授权。event-triggers 使用此窄桥观察一个预先选定的日历;它不能列出日历,不能取得 app secret 或 tenant token,也不能凭 credentialPurpose: connect 自动取得 Calendar 范围。使用官方向导更新应用范围时运行 dsh-lark-setup --create-app --calendar-readonly,然后由操作员把实际授权的 exact Calendar ID 填入 allowedCalendarIds。
userQuestionTtlMs 默认 24 小时,范围为 1 分钟至 7 天;它限制当前进程内等待飞书回答的时长。过期、取消、Host 已在其他端结算或 adapter 注销都会撤销这次即时等待,不会把后到消息变成新的问题回答;短暂 WebSocket 重连不会主动丢弃仍有效的卡片。
飞书应用至少需要机器人身份读取、单聊/群内 @ 消息接收、机器人发消息、im.message.receive_v1;Get/DONE 需要 im:message.reactions:write_only,图片需要 im:resource,审批、模型选择和用户问题卡片需要 card.action.trigger。事件与回调使用 WebSocket 长连接,不需要公网 callback URL。