yuque_create_toc_node
Add title or link nodes to Yuque repository table of contents by specifying parent nodes, position, and type for organizing knowledge base structure.
Instructions
Create a TITLE or LINK node in the repository TOC tree.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| repoId | No | Yuque repository ID. | |
| repoNamespace | No | Yuque repository namespace. | |
| title | Yes | Node title. | |
| nodeType | No | Node type. | |
| url | No | Optional URL when nodeType is LINK. | |
| parentUuid | No | Target parent UUID. | |
| targetUuid | No | Alias of parentUuid. | |
| actionMode | No | TOC action mode. | |
| position | No | Insert position. |
Implementation Reference
- src/tools.js:445-445 (handler)The handler for 'yuque_create_toc_node' which calls client.createTocNode(args).
yuque_create_toc_node: async (args, client) => jsonText(await client.createTocNode(args)), - src/tools.js:213-230 (registration)The schema and registration definition for 'yuque_create_toc_node'.
{ name: "yuque_create_toc_node", description: "Create a TITLE or LINK node in the repository TOC tree.", inputSchema: { type: "object", properties: { ...repoRefSchema(), title: schemaProperty("string", "Node title.", { minLength: 1 }), nodeType: schemaProperty("string", "Node type.", { enum: ["TITLE", "LINK"] }), url: schemaProperty("string", "Optional URL when nodeType is LINK."), parentUuid: schemaProperty("string", "Target parent UUID."), targetUuid: schemaProperty("string", "Alias of parentUuid."), actionMode: schemaProperty("string", "TOC action mode.", { enum: ["child", "sibling"] }), position: schemaProperty("string", "Insert position.", { enum: ["append", "prepend"] }) }, required: ["title"] } },