Feishu doc

From cklxx/elephant.ai · View interactive version

Feishu doc is an AI agent skill from the GitHub repository cklxx/elephant.ai. When 飞书云文档 needs creating, reading, or updating → CRUD docs with Lark-flavored Markdown syntax.

How to use this skill

Skill file

Feishu Doc Skill

快速索引

文档操作

| 用户意图 | module | tool_action | 必填参数 |

|---------|--------|-------------|---------|

| 创建文档 | doc | create | 可空(建议 title) |

| 读取文档 | doc | read | document_id |

| 读取文档内容 | doc | read_content | document_id |

| 写入 Markdown | doc | write_markdown | document_id, content(或 markdown) |

| 列出文档块 | doc | list_blocks | document_id |

| 更新文本块 | doc | update_block_text | document_id, block_id, content |

Wiki 操作

| 用户意图 | module | tool_action | 必填参数 |

|---------|--------|-------------|---------|

| 列出知识空间 | wiki | list_spaces | - |

| 列出节点 | wiki | list_nodes | space_id |

| 创建节点 | wiki | create_node | space_id, title |

| 获取节点 | wiki | get_node | space_id, node_token |

调用示例

创建文档

python3 skills/feishu-cli/run.py '{
  "action": "tool",
  "module": "doc",
  "tool_action": "create",
  "title": "Q1 工作总结",
  "folder_token": "fldcnXXXX"
}'

读取文档内容

python3 skills/feishu-cli/run.py '{
  "action": "tool",
  "module": "doc",
  "tool_action": "read_content",
  "document_id": "doccnXXXX"
}'

写入 Markdown 内容

python3 skills/feishu-cli/run.py '{
  "action": "tool",
  "module": "doc",
  "tool_action": "write_markdown",
  "document_id": "doccnXXXX",
  "content": "## 概述\n\n本季度完成了以下关键目标:\n\n1. 项目 A 上线\n2. 性能优化 30%"
}'

Wiki 操作

# 列出知识空间
python3 skills/feishu-cli/run.py '{"action":"tool","module":"wiki","tool_action":"list_spaces"}'

# 列出节点
python3 skills/feishu-cli/run.py '{"action":"tool","module":"wiki","tool_action":"list_nodes","space_id":"7xxx"}'

核心约束

文档 ID 来源

Lark Markdown 与标准 Markdown 差异

飞书文档支持的 Markdown 是 Lark 风味,与标准 GFM 有一些差异:

权限与默认行为

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.