Skip to main content
Glama

doc_create_blocks

Inserts child blocks under a specified block in Feishu documents. Use block_type definitions to add paragraphs, headings, lists, code, quotes, dividers, and other content.

Instructions

在飞书文档指定块下插入子块。

支持的 block_type 及对应字段名: 2=文本段落(text) 示例: {"block_type":2,"text":{"elements":[{"text_run":{"content":"段落文本"}}]}} 3=H1(heading1) 示例: {"block_type":3,"heading1":{"elements":[{"text_run":{"content":"一级标题"}}]}} 4=H2(heading2) 示例: {"block_type":4,"heading2":{"elements":[{"text_run":{"content":"二级标题"}}]}} 5=H3(heading3), 6=H4(heading4), 7=H5(heading5), 8=H6(heading6), 9=H7(heading7) — 格式同上 11=无序列表(bullet) 示例: {"block_type":11,"bullet":{"elements":[{"text_run":{"content":"列表项"}}]}} 12=有序列表(ordered) 示例: {"block_type":12,"ordered":{"elements":[{"text_run":{"content":"步骤一"}}]}} 14=代码块(code) 示例: {"block_type":14,"code":{"elements":[{"text_run":{"content":"print('hi')"}}],"style":{"language":49}}} 15=引用(quote) 示例: {"block_type":15,"quote":{"elements":[{"text_run":{"content":"引用文本"}}]}} 34=高亮块(callout) 示例: {"block_type":34,"callout":{"elements":[{"text_run":{"content":"提示内容"}}]}} 22=分割线(divider) 示例: {"block_type":22,"divider":{}}

文本样式(text_element_style): bold=加粗, italic=斜体, underline=下划线, strikethrough=删除线, inline_code=行内代码 示例: {"text_run":{"content":"加粗文字","text_element_style":{"bold":true}}}

注意: elements 数组中可包含多个 text_run 实现混合样式。每种块的字段名必须与 block_type 对应(如 block_type=4 用 heading2, block_type=11 用 bullet)。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
indexNo插入位置(0-based),不填则追加到末尾
block_idYes父块 ID(通常用文档根块 ID,即 document_id)
childrenYes要插入的块数组,每个元素为飞书 Block 对象(含 block_type 及对应内容字段)
document_idYes文档 ID
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It provides extensive detail on block_type mappings, field name correspondence, examples, and styling options. It does not disclose potential errors or permissions, but the core behavior is well covered.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long but well-organized with line breaks and examples. Every section adds value, though it could be slightly trimmed. It is front-loaded with the main purpose and then details.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex tool with nested children and multiple block types, the description covers the key mappings and examples. It lacks some edge cases like error handling but is sufficiently complete for typical use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Even with 100% schema coverage, the description significantly adds meaning beyond the schema. It explains the children structure with block_type examples, field names, and style syntax, which is essential for constructing valid payloads.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool inserts child blocks under a specified block in Feishu docs, using a specific verb and resource. It differentiates from sibling tools like doc_update_block and doc_delete_blocks by focusing on creation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage context for creating doc blocks and distinguishes from update/delete siblings, but does not explicitly mention when not to use or alternative tools. Clear context for insertion is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/akakenle/feishu-wiki-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server