list_wiki_nodes
List all wiki nodes in a specified space. Optionally filter by parent node to retrieve children of a specific node.
Instructions
[Official API] List nodes in a Wiki space.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| space_id | Yes | Wiki space ID | |
| parent_node_token | No | Parent node token (optional) |
Implementation Reference
- src/tools/wiki.js:124-126 (handler)Handler function that executes the list_wiki_nodes tool logic. Delegates to ctx.getOfficialClient().listWikiNodes(args.space_id, { parentNodeToken: args.parent_node_token }).
async list_wiki_nodes(args, ctx) { return json(await ctx.getOfficialClient().listWikiNodes(args.space_id, { parentNodeToken: args.parent_node_token })); }, - src/tools/wiki.js:20-31 (schema)Input schema definition for the list_wiki_nodes tool, registering the name, description, input properties (space_id required, parent_node_token optional).
{ name: 'list_wiki_nodes', description: '[Official API] List nodes in a Wiki space.', inputSchema: { type: 'object', properties: { space_id: { type: 'string', description: 'Wiki space ID' }, parent_node_token: { type: 'string', description: 'Parent node token (optional)' }, }, required: ['space_id'], }, }, - src/clients/official/wiki.js:53-70 (helper)Client-side implementation that actually calls the Feishu API (UAT-first) to list wiki nodes in a space. Accepts spaceId, optional parentNodeToken and pageToken for pagination.
async listWikiNodes(spaceId, { parentNodeToken, pageToken } = {}) { // UAT-first (v1.3.7): bot identity hits 131006 "wiki space permission // denied" for spaces it wasn't explicitly invited to, even when the user // has access. listWikiSpaces is already UAT-first; this matches. const queryParams = { page_size: '50' }; if (parentNodeToken) queryParams.parent_node_token = parentNodeToken; if (pageToken) queryParams.page_token = pageToken; const sdkParams = { page_size: 50 }; if (parentNodeToken) sdkParams.parent_node_token = parentNodeToken; if (pageToken) sdkParams.page_token = pageToken; const res = await this._asUserOrApp({ uatPath: `/open-apis/wiki/v2/spaces/${encodeURIComponent(spaceId)}/nodes`, query: queryParams, sdkFn: () => this.client.wiki.spaceNode.list({ path: { space_id: spaceId }, params: sdkParams }), label: 'listWikiNodes', }); return { items: res.data.items || [], hasMore: res.data.has_more, viaUser: !!res._viaUser }; }, - src/tools/wiki.js:191-191 (registration)Module exports the schemas and handlers for registration by the MCP server framework.
module.exports = { schemas, handlers };