Skip to main content
Glama

get_all_pages

Retrieve all pages from a WikiJS knowledge base using the MCP server, enabling efficient content management and integration with AI assistants for seamless access to stored information.

Instructions

Get all pages in WikiJS

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The createTool function that defines the handler for the 'get_all_pages' tool. It calls wikiClient.getAllPages(), formats the result as JSON text, or returns an error message.
    export const createTool = (wikiClient: WikiJSClient): ToolCallback<typeof PARAMETERS> => {
    	return async () => {
    		try {
    			const result = await wikiClient.getAllPages();
    
    			return {
    				content: [
    					{
    						type: 'text',
    						text: JSON.stringify(result, null, 2)
    					}
    				]
    			};
    		} catch (error) {
    			const errorMessage = error instanceof Error ? error.message : String(error);
    			return {
    				content: [
    					{
    						type: 'text',
    						text: `Error getting page by ID: ${errorMessage}`
    					}
    				],
    				isError: true
    			};
    		}
    	}
    }
  • The input parameters schema for the 'get_all_pages' tool (empty object).
    export const PARAMETERS = {};
  • src/mcp/index.ts:61-66 (registration)
    Registration of the 'get_all_pages' tool on the MCP server using server.tool() with name, description, parameters, and the created handler function.
    server.tool(
        'get_all_pages',
        'Get all pages in WikiJS',
        GET_ALL_PAGES_TOOL_PARAMETERS,
        createGetAllPagesTool(this.wikiClient)
    );
  • The WikiJSClient.getAllPages helper method invoked by the tool handler, which calls the GraphQL SDK to fetch all pages.
    async getAllPages({limit, locale, tags}: {limit?: number, locale?: string, tags?: string[]} = {}) {
      const result = await this.sdk.GetAllPages({ limit, locale, tags });
      return result.pages?.list || [];
    }
Behavior2/5

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

No annotations are provided, so the description carries full burden. It states the action but lacks behavioral details such as whether this is a read-only operation, potential performance impacts, pagination, or return format. The description is minimal and doesn't disclose key traits beyond the basic action.

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

Conciseness5/5

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

The description is a single, efficient sentence with no wasted words, clearly front-loading the purpose. It's appropriately sized for a simple tool with no parameters.

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

Completeness3/5

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

Given the tool's simplicity (0 params, no output schema), the description is minimally complete but lacks depth. Without annotations or output schema, it should ideally mention behavioral aspects like read-only nature or result format, but it's adequate for basic understanding.

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

Parameters4/5

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

There are 0 parameters, and schema description coverage is 100%, so no parameter documentation is needed. The description doesn't add param info, but with no params, this is acceptable, aligning with the baseline for zero parameters.

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?

The description clearly states the verb ('Get') and resource ('all pages in WikiJS'), making the purpose specific and understandable. It distinguishes from siblings by indicating it retrieves all pages rather than specific ones by ID/path or via search, though it doesn't explicitly name alternatives.

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

Usage Guidelines3/5

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

The description implies usage for retrieving all pages, but doesn't explicitly state when to use this vs. siblings like get_page_by_id or search_pages. No guidance on exclusions or prerequisites is provided, leaving usage context inferred rather than clearly defined.

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

Related 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/RicardoCenci/wikijs-mcp'

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