lark-whiteboard
open.feishu.cn
Query and edit Lark (Feishu) whiteboards: export images/SVG, read node structure, and update with Mermaid, PlantUML, or SVG.
What is lark-whiteboard?
lark-whiteboard is a skill for coding agents that enables querying and editing whiteboards in Lark (Feishu) cloud documents. It supports exporting whiteboards as preview images or SVG vectors, reading raw node JSON, extracting Mermaid/PlantUML code, and updating whiteboard content using multiple input formats including Mermaid, PlantUML, SVG, and the native OpenAPI format. Authentication and permissions are handled via a shared lark-shared skill dependency.
- Export whiteboard content as a preview image or SVG vector graphic
- Read raw whiteboard node structure as JSON
- Extract or check existing Mermaid/PlantUML code embedded in a whiteboard
- Update whiteboard content using Mermaid, PlantUML, SVG, or native OpenAPI raw format
- Support targeted node edits (text, color) via raw JSON round-trip
- Operate as user identity by default, with optional bot identity for uploads
How to install lark-whiteboard
npx skills add null --skill lark-whiteboard- lark-cli must be installed and available in PATH
- npx and @larksuite/whiteboard-cli@^0.2.12 must be accessible
- lark-shared SKILL.md must be read first for authentication and permission setup
- Appropriate Lark user or bot credentials configured via lark-shared
How to use lark-whiteboard
- 1.Install the skill: npx skills add null --skill lark-whiteboard
- 2.Ensure lark-cli is available by running lark-cli --version
- 3.Ensure whiteboard-cli is available by running npx -y @larksuite/whiteboard-cli@^0.2.12 -v
- 4.Read lark-shared/SKILL.md to configure authentication before any whiteboard operation
- 5.To view or export a whiteboard, use the +query shortcut with --output_as image, svg, code, or raw
- 6.To update a whiteboard, use the +update shortcut with --input_format set to mermaid, plantuml, svg, or raw
- 7.For complex diagram creation, follow the Creation Workflow in lark-whiteboard-workflow.md
- 8.For modifying existing whiteboards, follow the Modification Workflow in lark-whiteboard-workflow.md
Use cases
- Exporting a Lark whiteboard diagram as an image for sharing or documentation
- Programmatically updating an architecture or flow diagram on a whiteboard using Mermaid code
- Inspecting the raw node structure of a whiteboard to make precise edits
- Checking whether a whiteboard was originally created from code (Mermaid/PlantUML)
- Creating or redrawing complex diagrams (architecture, flowcharts, org charts) on a whiteboard
- Developers automating Lark whiteboard content via coding agents
- Teams that maintain diagrams-as-code (Mermaid/PlantUML) synced to Lark whiteboards
- Engineers who need to export whiteboard snapshots programmatically
- Anyone using Claude Code or Cursor to interact with Lark cloud document whiteboards
lark-whiteboard FAQ
No. Document content editing is handled by the lark-doc skill. This skill only covers whiteboard operations.
No. Creating a whiteboard inside a document is handled by lark-doc via lark-doc-whiteboard.md references.
Mermaid, PlantUML, SVG, and the native OpenAPI raw JSON format are all supported via the +update shortcut.
All whiteboard operations default to --as user. Bot identity (--as bot) is only used when uploading as an application.
Yes. Use +query --output_as raw to get the node JSON, edit it manually, then apply changes with +update --input_format raw.
Full instructions (SKILL.md)
Source of truth, from open.feishu.cn.
name: lark-whiteboard version: 1.0.0 description: > 飞书画板:查询和编辑飞书云文档中的画板。支持导出画板为预览图片、导出原始节点结构、使用多种格式更新画板内容。 当用户需要查看画板内容、导出画板图片、编辑画板时使用此 skill。不负责:飞书云文档内容编辑(lark-doc)、文档内嵌电子表格/Base(lark-sheets / lark-base)。 metadata: requires: bins: ["lark-cli"] cliHelp: "lark-cli whiteboard --help"
[!IMPORTANT]
- 运行
lark-cli --version,确认可用,无需询问用户。- 运行
npx -y @larksuite/whiteboard-cli@^0.2.12 -v,确认可用,无需询问用户。
CRITICAL — 开始前 MUST 先用 Read 工具读取 ../lark-shared/SKILL.md,其中包含认证、权限处理
快速决策
身份:画板操作默认使用 --as user。仅当需要以应用身份上传时使用 --as bot。
| 用户需求 | 行动 |
|---|---|
| 查看画板内容 / 导出图片 / 导出 SVG 矢量图 | +query --output_as image/svg |
| 获取画板的 Mermaid/PlantUML 代码 | +query --output_as code |
| 检查画板是否由代码绘制 | +query --output_as code |
| 仅微调节点文字/颜色 | +query --output_as raw → 手动改 JSON → +update --input_format raw |
| 用户已提供 Mermaid/PlantUML/SVG 代码,或明确指定用该格式 | 自己生成/使用代码 → +update --input_format mermaid/plantuml/svg |
| 新建/创作复杂图表(架构/流程/组织等) | → § 创作 Workflow |
| 修改/重绘已有画板 | → § 修改 Workflow |
Shortcuts
| Shortcut | 说明 |
|---|---|
+query | 查询画板,导出为预览图片、SVG 矢量图、代码或原始节点结构。 |
+update | 更新画板,支持 PlantUML、Mermaid、SVG 或 OpenAPI 原生格式 |
不在本 skill 范围
- 文档内容编辑 → lark-doc lark-doc
- 在文档中创建画板 → lark-doc-whiteboard.md
- 表格 / Base 操作 → lark-sheets / lark-base
Related skills
More from open.feishu.cn and the wider catalog.
lark-approval
Query, process, and initiate Lark approval tasks via CLI — search definitions, manage instances, and handle approvals.
lark-doc
Read, create, and edit Feishu cloud documents (Docx/Wiki) with content manipulation and media handling.
lark-base
Operate Feishu Multidimensional Tables (Base): create tables, manage fields, records, views, formulas, forms, dashboards, workflows, and permissions.
lark-calendar
Manage Lark calendar events and meeting rooms: view, create, update, search events, check availability, and book rooms.
lark-drive
Manage Feishu Drive files and folders: upload, download, organize, and import local documents.
lark-contact
Resolve Lark/Feishu names & emails to open_id, or look up user details by open_id