Skip to content
feishu-docx logo

Feishu Docx Exporter

feishu-docx

Export Feishu/Lark cloud documents to Markdown. Supports docx, sheets, bitable, wiki, and batch wiki space export. Use this skill when you need to read, analyze, write, or reference content from Feishu knowledge base.

SKILL.md

Full skill instructions

Feishu Docx Exporter

Export Feishu/​Lark cloud documents to Markdown format for AI analysis.

Setup (One-time)

pip install feishu-docx
feishu-docx config set --app-id YOUR_APP_ID --app-secret YOUR_APP_SECRET

Token auto-refreshes. No user interaction required.

Export Documents

feishu-docx export "<FEISHU_URL>" -o ./​output

The exported Markdown file will be saved with the document's title as filename.

Supported Document Types

  • docx: Feishu cloud documents → Markdown with images
  • sheet: Spreadsheets → Markdown tables
  • bitable: Multidimensional tables → Markdown tables
  • wiki: Knowledge base nodes → Auto-resolved and exported

Command Reference

CommandDescription
feishu-docx export <URL>Export document to Markdown
feishu-docx create <TITLE>Create new document
feishu-docx write <URL>Append content to document
feishu-docx update <URL>Update specific block
feishu-docx export-wiki-space <URL>Batch export entire wiki space
feishu-docx export-workspace-schema <ID>Export bitable database schema
feishu-docx authOAuth authorization
feishu-docx config setSet credentials
feishu-docx config showShow current config
feishu-docx config clearClear token cache
feishu-docx tuiInteractive TUI interface

Examples

Export a wiki page

feishu-docx export "https://xxx.feishu.cn/​wiki/​ABC123" -o ./​docs

Export a document with custom filename

feishu-docx export "https://xxx.feishu.cn/​docx/​XYZ789" -o ./​docs -n meeting_notes

Read content directly (recommended for AI Agent)

# Output content to stdout instead of saving to file
feishu-docx export "https://xxx.feishu.cn/​wiki/​ABC123" --stdout
# or use short flag
feishu-docx export "https://xxx.feishu.cn/​wiki/​ABC123" -c

Export with Block IDs (for later updates)

# Include block IDs as HTML comments in the Markdown output
feishu-docx export "https://xxx.feishu.cn/​wiki/​ABC123" --with-block-ids
# or use short flag
feishu-docx export "https://xxx.feishu.cn/​wiki/​ABC123" -b

Batch Export Entire Wiki Space

# Export all documents in a wiki space (auto-extract space_id from URL)
feishu-docx export-wiki-space "https://xxx.feishu.cn/​wiki/​ABC123" -o ./​wiki_backup

# Specify depth limit
feishu-docx export-wiki-space "https://xxx.feishu.cn/​wiki/​ABC123" -o ./​docs --max-depth 3

# Export with Block IDs for later updates
feishu-docx export-wiki-space "https://xxx.feishu.cn/​wiki/​ABC123" -o ./​docs -b

Export Database Schema

# Export bitable/​workspace database schema as Markdown
feishu-docx export-workspace-schema <workspace_id>

# Specify output file
feishu-docx export-workspace-schema <workspace_id> -o ./​schema.md

Write Documents (CLI)

Create Document

# Create empty document
feishu-docx create "我的笔记"

# Create with Markdown content
feishu-docx create "会议记录" -c "# 会议纪要\n\n- 议题一\n- 议题二"

# Create from Markdown file
feishu-docx create "周报" -f ./​weekly_report.md

# Create in specific folder
feishu-docx create "笔记" --folder fldcnXXXXXX

如何获取 folder token:

  1. 在浏览器中打开目标文件夹
  2. 从 URL 中提取 token:https://xxx.feishu.cn/​drive/​folder/​fldcnXXXXXX
  3. fldcnXXXXXX 就是 folder token

Append Content to Existing Document

# Append Markdown content
feishu-docx write "https://xxx.feishu.cn/​docx/​xxx" -c "## 新章节\n\n内容"

# Append from file
feishu-docx write "https://xxx.feishu.cn/​docx/​xxx" -f ./​content.md

Update Specific Block

# Step 1: Export with Block IDs
feishu-docx export "https://xxx.feishu.cn/​docx/​xxx" -b -o ./

# Step 2: Find block ID from HTML comments
# <!-- block:blk123abc -->
# # Heading
# <!-- /​block -->

# Step 3: Update the specific block
feishu-docx update "https://xxx.feishu.cn/​docx/​xxx" -b blk123abc -c "新内容"

Tip for AI Agents: When you need to update a specific section:

  1. Export with -b to get block IDs
  2. Find the target block ID from HTML comments
  3. Use feishu-docx update with that block ID

Tips

  • Images auto-download to {doc_title}/ folder
  • Use --stdout or -c for direct content output (recommended for agents)
  • Use -b to export with block IDs for later updates
  • Token auto-refreshes, no re-auth needed
  • For Lark (overseas): add --lark flag

More skills from majiayu000

xiaohongshu logo
majiayu000/claude-arsenal

xiaohongshu

xiaohongshu

286 148
View
agent-task-conductor logo
majiayu000/claude-skill-registry

agent-task-conductor

Conduct multi-agent task orchestration and workflow coordination.

663 1
View
conductor-setup logo
majiayu000/claude-skill-registry

conductor-setup

Initialize project with Conductor artifacts (product definition,

663 1
View
animation-designer logo
majiayu000/claude-skill-registry

animation-designer

Expert in web animations, transitions, and motion design using Framer Motion and CSS

663 1
View
diagramming logo
majiayu000/claude-skill-registry

diagramming

Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...

663 1
View
h3-pg logo
majiayu000/claude-skill-registry-data

h3-pg

PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.

23 1
View
conductor-development logo
majiayu000/claude-skill-registry

conductor-development

Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...

663 1
View
conductor-status logo
majiayu000/claude-skill-registry

conductor-status

Display project status, active tracks, and next actions

663 1
View
dockerization logo
majiayu000/claude-skill-registry

dockerization

Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.

663 1
View

Popular AI tools

Kaiber logo
Video

Kaiber

Generate, edit, and beat-sync AI video with leading models in one workspace.

Paid
View
Vimcal logo
Productivity

Vimcal

The world's fastest calendar for remote work

Free
View

Transform Your Design with AI Designer by ImgCreator.ai

Freemium
View
Akool AI logo
Content & writing

Akool AI

Revolutionizing Video Production with AI-Powered Creativity

Paid
View

Extend an image past the frame and let AI fill the new aspect ratio.

Freemium
View
StarByFace logo
Security

StarByFace

Discover your celebrity doppelgänger with StarByFace!

Free
View
C

ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.

Freemium
View
Opus Clip logo
Coding & apps

Opus Clip

Opus.ai: Revolutionize Your Web Experience

Free
View