feishu-cli-messaging
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinese飞书即时消息
Feishu Instant Messaging
加载工作流后,将其中 、、、 相对路径按该
所在目录解析;执行脚本时使用解析后的实际路径,不要依赖当前 shell 目录。
references/scripts/templates/examples/workflow.mdAfter loading the workflow, resolve the relative paths of , , , and based on the directory where this is located; use the resolved actual path when executing scripts, and do not rely on the current shell directory.
references/scripts/templates/examples/workflow.md路由
Routing
| 意图 | 读取文件 |
|---|---|
| 发送、回复、转发、加急、flag、资源下载 | |
| 历史消息、详情、Reaction、Pin、撤回、群和成员 | |
| 设计和生成 V2 interactive 卡片 JSON | |
| 订阅和消费实时事件 | |
发送交互卡片时先读取 card 构造 JSON,再读取 msg 发送。搜索历史消息关键词时读取
。
../feishu-cli-platform/references/workflows/search/workflow.md| Intent | File to Read |
|---|---|
| Send, reply, forward, urgent messaging, flag, resource download | |
| Historical messages, details, Reaction, Pin, recall, groups and members | |
| Design and generate V2 interactive card JSON | |
| Subscribe to and consume real-time events | |
When sending interactive cards, first read the card construction JSON, then read the msg to send. When searching keywords in historical messages, read .
../feishu-cli-platform/references/workflows/search/workflow.md执行规则
Execution Rules
- 发送前确认接收者类型和 ID;不要把 email、open_id、chat_id 混用。
- 群发、加急和删除消息有外部影响,先展示目标和数量。
- 与
msg send共用内容快捷参数;本地图片、文件、Opus 音频、MP4 视频会先上传, 任一文件缺失、格式非法或上传失败都会阻止提交消息。msg reply同时适用于两条命令。--upload-images - 进入既有话题必须使用 ;
msg reply <om_xxx>仅用于话题查询/转发,不能作为omt_xxx的接收者。普通消息群开启新话题时才加msg send。--reply-in-thread - 发送与回复重试都使用同一 ;媒体上传可能重做,但服务端幂等键防止 可见消息重复。只有命令返回非空
--idempotency-key才判定成功。message_id - 外部群 232033 的排错读取 。
references/workflows/chat/references/external-chat.md - 卡片草稿与发送候选分开校验;发送前必须运行 card workflow 的
,不得发送含占位符、示例 ID、假链接或未接通回调按钮的卡片。
lint_card.py --strict - 用户点名卡片风格时使用 card workflow 内置的 19 个预设;使用本地头图或图标素材时,
lint 与实际的 /
msg send都传msg reply,不要固化跨租户--upload-images。img_key
- Confirm the recipient type and ID before sending; do not mix up email, open_id, and chat_id.
- Group messaging, urgent messaging, and message deletion have external impacts; display the targets and quantities first.
- and
msg sendshare content shortcut parameters; local images, files, Opus audio, and MP4 videos will be uploaded first. Any missing file, illegal format, or upload failure will prevent message submission.msg replyapplies to both commands.--upload-images - To enter an existing thread, must use ;
msg reply <om_xxx>is only used for thread query/forwarding and cannot be used as the recipient ofomt_xxx. Addmsg sendonly when starting a new thread in a regular message group.--reply-in-thread - Use the same for retries of sending and replying; media uploads may be redone, but the server-side idempotency key prevents duplicate visible messages. Success is only determined when the command returns a non-empty
--idempotency-key.message_id - For troubleshooting external group 232033, read .
references/workflows/chat/references/external-chat.md - Validate card drafts and sending candidates separately; before sending, must run from the card workflow, and do not send cards containing placeholders, sample IDs, fake links, or unconnected callback buttons.
lint_card.py --strict - Use the 19 built-in presets in the card workflow when the user specifies a card style; when using local header images or icon materials, pass for both lint and actual
--upload-images/msg send, and do not hardcode cross-tenantmsg reply.img_key