← Back to Skills Marketplace
blackswan-mohu

feishu-card-sender

by blackswan-mohu · GitHub ↗ · v1.0.1 · MIT-0
cross-platform ⚠ suspicious
316
Downloads
0
Stars
0
Active Installs
2
Versions
Install in OpenClaw
/install feishucard-sender
Description
发送飞书卡片消息(支持纯文本和图片)。使用 message 工具的 card 参数,需要配置飞书应用凭证(App ID + App Secret)。
README (SKILL.md)

feishu-card-sender

发送飞书卡片消息。

前置配置

在 USER.md 中配置飞书应用凭证:

- **Feishu App ID:** cli_xxx
- **Feishu App Secret:** xxx

权限要求

飞书开放平台 → 应用 → 权限管理 → 开通 im:message

使用方法

纯文本卡片

message
  action: send
  card: {"config":{"wide_screen_mode":true},"header":{"title":{"content":"标题","tag":"plain_text"},"template":"blue"},"elements":[{"tag":"div","text":{"content":"内容","tag":"lark_md"}}]}
  target: ou_xxx

带图片的卡片

步骤 1:上传图片获取 img_key

使用 scripts/upload_image.py 脚本:

python scripts/upload_image.py --image /path/to/image.jpg

返回 img_key

步骤 2:发送卡片

message
  action: send
  card: {"config":{"wide_screen_mode":true},"header":{"title":{"content":"标题","tag":"plain_text"},"template":"blue"},"elements":[{"tag":"img","img_key":"img_v3_xxx"},{"tag":"div","text":{"content":"内容","tag":"lark_md"}}]}
  target: ou_xxx

卡片格式

{
  "config": {"wide_screen_mode": true},
  "header": {
    "title": {"content": "标题", "tag": "plain_text"},
    "template": "blue"
  },
  "elements": [...]
}

header.template 颜色

blue | green | red | orange | grey | purple | warning | error

elements 常用元素

  • div - 文本块,支持 tag: "lark_md"(粗体/斜体/链接)
  • hr - 分割线
  • note - 备注脚注
  • img - 图片(需要 img_key)
  • action + button - 按钮组

注意事项

  1. 优先用 message 工具,不要用 feishu_im_bot_message(需要额外权限)
  2. 图片必须上传获取 img_key,不能用 URL
  3. 机器人只能发给好友或群聊,不能直接发给陌生人
  4. 其他"龙虾"要使用:需要配置相同的 app_id + app_secret

示例

示例 1:简单通知卡片

message
  action: send
  card: {"config":{"wide_screen_mode":true},"header":{"title":{"content":"通知","tag":"plain_text"},"template":"blue"},"elements":[{"tag":"div","text":{"content":"这是内容","tag":"plain_text"}}]}
  target: ou_xxx

示例 2:带图片和按钮

message
  action: send
  card: {"config":{"wide_screen_mode":true},"header":{"title":{"content":"产品介绍","tag":"plain_text"},"template":"green"},"elements":[{"tag":"img","img_key":"img_v3_xxx"},{"tag":"div","text":{"content":"**亮点**\
• 功能 1\
• 功能 2","tag":"lark_md"}},{"tag":"action","actions":[{"tag":"button","text":{"content":"查看详情","tag":"plain_text"},"type":"primary","url":"https://example.com"}]}]}
  target: ou_xxx
Usage Guidance
This skill's code and instructions match its stated purpose (upload images and send Feishu card messages), but the package metadata fails to declare the required Feishu credentials and the script's Python dependency. Before installing: 1) Verify the script source and review scripts/upload_image.py locally. 2) Provide FEISHU_APP_ID and FEISHU_APP_SECRET via environment variables (or pass them to the script) and avoid storing secrets in repo files like USER.md. 3) Ensure Python and the 'requests' package are available in the runtime. 4) Prefer creating a Feishu app with minimal permissions and rotate credentials if you decide to use this. If you need the skill to run in an automated/hosted agent, confirm where the agent stores env vars and whether that storage is secure.
Capability Analysis
Type: OpenClaw Skill Name: feishucard-sender Version: 1.0.1 The skill bundle provides legitimate functionality for sending Feishu (Lark) card messages and uploading images. The Python script `scripts/upload_image.py` interacts exclusively with official Feishu API endpoints (open.feishu.cn) to obtain access tokens and upload media. The instructions in `SKILL.md` are consistent with the code's purpose and do not contain any prompt-injection attacks or attempts to exfiltrate sensitive data beyond the intended platform.
Capability Assessment
Purpose & Capability
The SKILL.md and included script implement Feishu image upload and card sending as advertised. However the registry metadata declares no required environment variables or primary credential even though the skill clearly needs Feishu App ID and App Secret; that's an inconsistency between claimed requirements and actual needs.
Instruction Scope
Runtime instructions are scoped to sending cards and uploading images to Feishu. The SKILL.md and script only call Feishu Open API endpoints and read app credentials; they do not attempt to read unrelated system files or external endpoints. One small oddity: the doc tells the user to put credentials into a USER.md file (not included) while the script reads environment variables — the mapping is implied but not explicit.
Install Mechanism
This is instruction-only with no install spec (low risk). However a Python script is included that depends on the 'requests' library and a working Python runtime; those dependencies are not declared in the metadata or SKILL.md, so users might be missing required runtime components.
Credentials
The script expects FEISHU_APP_ID and FEISHU_APP_SECRET (it also accepts CLI flags). Those credentials are appropriate for the skill's purpose, but the skill registry metadata did not declare any required env vars or a primary credential. The omission of declared secrets is a mismatch that could cause accidental misconfiguration or secret placement in insecure locations (e.g., putting secrets into repo files).
Persistence & Privilege
The skill does not request persistent/always-on presence and does not modify other skill or system configurations. It is user-invocable only (default) and does not request elevated privileges.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install feishucard-sender
  3. After installation, invoke the skill by name or use /feishucard-sender
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.1
feishucard-sender 1.0.1 - No changes to the code or documentation were detected in this release. - All existing instructions and usage examples remain unchanged.
v1.0.0
Initial release with major simplification. - Reduced codebase to only one script: scripts/upload_image.py - Removed all template files, sample rules, callback handlers, and documentation specific to previous custom card features. - Updated documentation for new, simplified use focusing on sending Feishu cards with support for images and plain text. - Usage now requires uploading images via upload_image.py and configuring via standard message tools.
Metadata
Slug feishucard-sender
Version 1.0.1
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 2
Frequently Asked Questions

What is feishu-card-sender?

发送飞书卡片消息(支持纯文本和图片)。使用 message 工具的 card 参数,需要配置飞书应用凭证(App ID + App Secret)。 It is an AI Agent Skill for Claude Code / OpenClaw, with 316 downloads so far.

How do I install feishu-card-sender?

Run "/install feishucard-sender" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is feishu-card-sender free?

Yes, feishu-card-sender is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does feishu-card-sender support?

feishu-card-sender is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created feishu-card-sender?

It is built and maintained by blackswan-mohu (@blackswan-mohu); the current version is v1.0.1.

💬 Comments