Skip to main content
Glama
IQAIcom
by IQAIcom

GET_WIKI

Retrieve detailed information about a specific wiki from IQ.wiki by its unique ID using the MCP server for AI assistants and applications.

Instructions

Get details about a specific wiki from IQ.wiki by ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe ID of the wiki to retrieve

Implementation Reference

  • The main handler function for the GET_WIKI tool. It instantiates GetWikiService, calls its execute method with the provided wiki ID, formats the result, and handles any errors gracefully.
    execute: async (params: GetWikiParams) => {
    	try {
    		const service = new GetWikiService();
    		const wiki = await service.execute(params.id);
    
    		return service.format(wiki);
    	} catch (error) {
    		if (error instanceof Error) {
    			console.log(`Error in GET_WIKI tool: ${error.message}`);
    			return `Error retrieving wiki: ${error.message}`;
    		}
    		return "An unknown error occurred while fetching wiki data";
    	}
    },
  • Zod schema defining the required input parameter 'id' (string, non-empty) for the GET_WIKI tool.
    const getWikiParams = z.object({
    	id: z.string().min(1).describe("The ID of the wiki to retrieve"),
    });
  • src/index.ts:17-17 (registration)
    Registers the GET_WIKI tool (imported as getWikiTool) with the FastMCP server instance.
    server.addTool(getWikiTool);
  • src/index.ts:6-6 (registration)
    Imports the GET_WIKI tool definition from src/tools/get-wiki.js for registration.
    import { getWikiTool } from "./tools/get-wiki.js";
  • Supporting service class for GET_WIKI that executes a GraphQL query using WIKI_QUERY to fetch wiki details by ID and formats the output into a readable string.
    export class GetWikiService {
    	async execute(id: string) {
    		try {
    			const response = await client.request(WIKI_QUERY, {
    				id,
    			});
    
    			if (!response.wiki) {
    				throw new Error("Wiki Not found");
    			}
    			return response.wiki;
    		} catch (error: any) {
    			throw new Error(error.message);
    		}
    	}
    	format(wiki: any) {
    		const formattedWiki = dedent`
    			šŸ“œ Wiki Details
    			- Title: ${wiki.title}
    			- Summary: ${wiki.summary}
    
    			šŸ”— Source: ${IQ_BASE_URL}/${wiki.id}
    			šŸ”— Transaction: https://polygonscan.com/tx/${wiki.transactionHash}
    		`;
    
    		return formattedWiki;
    	}
    }
Behavior2/5

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

With no annotations provided, the description carries full burden but only states the basic operation. It lacks behavioral details such as error handling (e.g., what happens if the ID is invalid), authentication requirements, rate limits, or response format, which are critical for a read operation without structured annotations.

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 that directly states the tool's function without unnecessary words. It is front-loaded and appropriately sized for its purpose, earning full marks for conciseness.

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?

Given the lack of annotations and output schema, the description is incomplete. It doesn't explain what 'details' are returned, error conditions, or other contextual aspects needed for effective use, making it inadequate for a tool with no structured behavioral data.

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?

The schema description coverage is 100%, with the parameter 'id' fully documented in the schema. The description adds no additional meaning beyond what the schema provides (e.g., no examples or constraints), so it meets the baseline for high schema coverage without compensating value.

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 action ('Get details') and resource ('specific wiki from IQ.wiki by ID'), making the purpose unambiguous. However, it doesn't explicitly differentiate from sibling tools like GET_USER_CREATED_WIKIS or SEARCH_WIKI, which prevents a perfect score.

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 is provided about when to use this tool versus alternatives like SEARCH_WIKI or the user-specific wiki tools. The description implies usage when you have a specific wiki ID, but it doesn't clarify scenarios or exclusions, leaving the agent to infer context.

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/IQAIcom/mcp-iqwiki'

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