← Back to Skills Marketplace
amd5

Feishu Repair

by c32 · GitHub ↗ · v2.0.0 · MIT-0
cross-platform ⚠ suspicious
88
Downloads
0
Stars
0
Active Installs
11
Versions
Install in OpenClaw
/install feishu-repair
Description
自动修复飞书-自动修复飞书群聊+自动修复会话 - 诊断 Gateway 连接、权限配置、消息投递问题
README (SKILL.md)

Feishu Repair — 飞书群聊+会话修复技能

版本: 1.9.0 创建日期: 2026-04-14 触发关键词: 修复飞书


📋 功能

自动诊断和修复 OpenClaw 飞书渠道的常见问题:

问题类型 诊断方式 修复方式
Gateway 未运行 systemctl 检查 自动重启 Gateway
飞书 WebSocket 断开 journalctl 日志 自动重启 Gateway
群聊权限丢失 检查 groupAllowFrom 自动恢复配置 + 强制重启 + 验证 + 发送消息到所有群聊和用户
用户权限丢失 检查 allowFrom 自动恢复配置 + 强制重启 + 验证 + 发送消息到所有群聊和用户
配置未生效 检查 config 强制重启 Gateway + 验证
消息不回复 综合诊断 输出修复报告 + 发送验证消息

📂 文件结构

skills/feishu-repair/
├── SKILL.md
├── skill.json
├── _meta.json
└── scripts/
    └── diagnose.js     # 诊断脚本

🔧 修复流程

诊断 → 修复 → 强制重启 Gateway → 验证 → 发消息确认
步骤 功能 说明
1️⃣ 诊断 检查 Gateway、飞书配置、日志错误 始终执行
2️⃣ 修复 从配置恢复丢失的权限 检测到问题
3️⃣ 强制重启 重启 Gateway 使配置生效 有修复操作时强制重启
4️⃣ 验证 配置 + 日志双重检查 重启后自动执行
5️⃣ 消息确认 遍历所有群聊和会话发送当前时间 验证通过后自动发送

修复策略

策略 触发条件 动作
配置恢复 权限丢失/配置异常 openclaw.jsonopenclaw.json.bak* 读取完整配置自动恢复
Gateway 状态检查 Gateway 未运行 自动重启 Gateway
WebSocket 重连 WS 断开日志 自动重启 Gateway
配置生效检查 配置变更未生效 自动重启 Gateway + 验证

配置读取优先级

  1. ~/.openclaw/openclaw.json(当前配置)
  2. ~/.openclaw/openclaw.json.bak(最新备份)
  3. ~/.openclaw/openclaw.json.bak.1(更早备份)

按顺序读取,找到第一个有飞书配置的文件即停止。从中提取 allowFromgroupAllowFromappId 等完整列表。


📊 配置来源

技能内不硬编码任何用户 ID、群聊 ID、App ID。

全部从用户的 openclaw.json 及其备份文件中动态读取。


⚠️ 注意事项

  • 检测到配置问题并修复后,强制重启 Gateway(不是提示手动)
  • 重启完成后,自动验证修复结果(配置 + 日志双重检查)
  • 验证通过后,自动在飞书所有群聊(groupAllowFrom)和会话(allowFrom)发送当前时间,确认消息功能已恢复
  • 配置读取优先级:openclaw.json > openclaw.json.bak > openclaw.json.bak.1
  • 诊断结果输出详细报告
Usage Guidance
What to consider before installing or running this skill: - It will read ~/.openclaw/openclaw.json and backup files (which contain appId/appSecret and access lists). Those app secrets are sensitive — inspect the script and confirm you trust it before allowing access. - The script requires externally available tools that are not declared in metadata: openclaw CLI, systemctl/journalctl (systemd user service), curl, and sleep. Ensure these are present and that running them is acceptable in your environment. - The skill will modify live configuration (using 'openclaw config set') and forcibly restart the openclaw-gateway.service automatically. Back up current config and test in a non-production environment first. - It will iterate over allowFrom and groupAllowFrom and send messages to all listed chats/users to validate repairs. Consider privacy and inform impacted users/groups before running. - If you want to reduce risk: run the diagnose script manually in a dry-run or JSON-only mode first, review the output, and only allow fixes after confirming the proposed changes; or edit the script to add an explicit interactive confirmation step before any 'openclaw config set' or 'systemctl restart' call. - If you are unsure, ask the skill author for provenance or run the script in an isolated environment where it cannot reach the real Feishu API or restart production services.
Capability Analysis
Type: OpenClaw Skill Name: feishu-repair Version: 2.0.0 The skill performs automated diagnosis and repair of Feishu integrations by reading sensitive configuration files (including appId and appSecret), executing system commands via execSync, and interacting with external Feishu API endpoints. While these actions align with the stated purpose in SKILL.md, the script diagnose.js contains shell injection vulnerabilities due to unsanitized configuration values in execSync calls and possesses high-risk capabilities such as restarting systemd services and programmatically sending messages to all configured users and groups.
Capability Assessment
Purpose & Capability
The skill's stated purpose (diagnose and repair OpenClaw Feishu channel) matches the code: it reads ~/.openclaw/openclaw.json backups, sets channels.feishu.* via the openclaw CLI, restarts the openclaw-gateway.service, and calls Feishu APIs. However, the registry metadata declares no required binaries or env vars while the script actually depends on systemctl/journalctl, the openclaw CLI, curl, and a POSIX sleep — the missing declared dependencies is an inconsistency.
Instruction Scope
SKILL.md and the script instruct the agent to read the user's ~/.openclaw config and backups, edit live OpenClaw config via 'openclaw config set', force-restart the Gateway service, inspect journalctl logs, and send validation messages to all configured group/user targets. These actions are within the stated repair scope, but they involve reading sensitive credentials and proactively messaging all contacts — behaviour that impacts privacy and production systems and should be explicitly consented to.
Install Mechanism
There is no install spec (instruction-only plus an included script). No remote downloads or archive extraction occur during install. The runtime script will be executed by the agent when invoked; that is expected for an instruction-only skill.
Credentials
The skill does not declare environment variables but reads appId/appSecret and allowFrom/groupAllowFrom from local openclaw.json files. Accessing those credentials is necessary to obtain Feishu tenant_access_token and send validation messages, so the access is functionally justified — but these are sensitive secrets and the skill will transmit derived tokens to Feishu APIs and send messages on behalf of the app.
Persistence & Privilege
The skill will modify live OpenClaw configuration via 'openclaw config set' and will forcibly restart the user-level openclaw-gateway.service without further confirmation. While 'always' is false and it does not auto-enable itself, these are high-privilege actions with real operational impact; users should be aware it will change config and send messages to all targets.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install feishu-repair
  3. After installation, invoke the skill by name or use /feishu-repair
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v2.0.0
文档统一: 明确修复后强制重启 Gateway(非提示手动)+自动验证(配置+日志)+自动发送消息确认
v1.9.0
description 描述文本调整为用户指定格式
v1.8.0
文档修正: 统一版本号、修复描述冗余、重构修复流程表格格式
v1.7.0
修正: 遍历所有配置的群聊(groupAllowFrom)和用户(allowFrom),分别发送当前时间到对应的渠道,而非仅发第一个群聊
v1.6.0
新增: 验证通过后自动在飞书群聊发送当前时间消息,确认消息功能已恢复正常
v1.5.0
文档修正: 统一描述为自动重启 Gateway + 自动验证修复结果,移除'提示手动重启'等过时描述
v1.4.0
文档更新: 用户修改 SKILL.md 和 skill.json
v1.3.0
新增: 修复后自动重启 Gateway + 自动验证飞书修复情况(配置+日志双重检查)
v1.2.0
完全移除硬编码ID,用户ID/群聊ID/AppID全部从openclaw.json及备份文件动态读取,技能内不指定任何ID值
v1.1.0
从 openclaw.json.bak* 备份文件读取历史配置自动恢复 allowFrom/groupAllowFrom,不再硬编码用户/群聊ID
v1.0.0
新建: 飞书群聊+会话自动修复技能 - 诊断 Gateway 连接、权限配置(allowFrom/groupAllowFrom)、消息投递问题
Metadata
Slug feishu-repair
Version 2.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 11
Frequently Asked Questions

What is Feishu Repair?

自动修复飞书-自动修复飞书群聊+自动修复会话 - 诊断 Gateway 连接、权限配置、消息投递问题. It is an AI Agent Skill for Claude Code / OpenClaw, with 88 downloads so far.

How do I install Feishu Repair?

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

Is Feishu Repair free?

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

Which platforms does Feishu Repair support?

Feishu Repair is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Feishu Repair?

It is built and maintained by c32 (@amd5); the current version is v2.0.0.

💬 Comments