Skip to main content
Glama

yuque_import_file

Import local Markdown or HTML files into a Yuque repository, choosing direct, upload_assets, or embed_assets mode to handle document assets and paths.

Instructions

Import a local Markdown/HTML file into Yuque. 3 modes: direct / upload_assets / embed_assets. 详见 references/api/extended_api.md

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNoImport mode: direct / upload_assets / embed_assets (default: direct)
slugNoDocument slug, auto-generated if omitted
pathsYesDirectory paths, e.g. ["导入/技术文档"]. 1-5 paths (required)
titleNoDocument title, defaults to filename without extension
formatNoContent format: markdown / html, defaults to markdown
book_idYesTarget repository ID or namespace (required)
file_pathYesLocal file path (required, .md or .html)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It never states that this is a mutating/write operation, whether an existing doc with the same slug is overwritten or a new one created, permission requirements, or asset-upload side effects. A bare pointer to a reference file does not disclose these traits inline.

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?

Two short sentences, front-loaded with the core action before the mode enumeration. The Chinese reference pointer ('详见 references/api/extended_api.md') is terse but assumes the reader resolves it, slightly undercutting self-contained concision.

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

Completeness2/5

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

For a 7-parameter write tool with no annotations and no output schema, this is thin. The distinction between upload_assets and embed_assets (a real behavioral difference affecting where assets live) is left entirely to an external file, so an agent cannot confidently pick a mode or predict side effects from the definition alone.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents all 7 parameters, including mode, format, slug, and paths. The description repeats the mode values but adds no syntax, defaults, or constraints beyond what the schema provides; baseline 3 applies.

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

Purpose4/5

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

States a specific verb and resource: 'Import a local Markdown/HTML file into Yuque.' This clearly separates it from the sibling yuque_import_url, which handles remote URLs. The three modes are named but not explained, so the purpose is clear while mode selection remains opaque.

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

Usage Guidelines2/5

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

No guidance on when to use this tool versus yuque_import_url, yuque_upload_attachment, or yuque_create_doc. Listing '3 modes: direct / upload_assets / embed_assets' names options without saying which conditions select each one, leaving the agent to guess.

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