Wiki.js MCP Server
Provides tools for interacting with a Wiki.js instance's API, enabling AI assistants to search, retrieve, create, update, delete, and list Wiki.js pages, search and retrieve users, and list user groups.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Wiki.js MCP Server
A Model Context Protocol (MCP) server that provides seamless integration between Claude Desktop and Wiki.js instances. This server enables AI assistants to interact with Wiki.js through a standardized protocol, allowing for comprehensive page management, user operations, and content search capabilities.
π Features
π Page Management: Create, read, update, and delete Wiki.js pages
π₯ User Operations: Search and retrieve user information
π Group Management: List and manage user groups
π Content Search: Search pages by title or content
π SSL Support: Configurable SSL certificate handling
β‘ Type Safety: Full TypeScript implementation with comprehensive type definitions
π MCP Protocol: Standard Model Context Protocol implementation
Related MCP server: mcp-server-ispace-wiki
π Prerequisites
Node.js 18+
npm or yarn
Wiki.js instance with API access
Valid Wiki.js API token
π οΈ Installation
1. Clone and Setup
git clone <repository-url>
cd mcp-wikijs
npm install2. Environment Configuration
cp .env.example .envEdit the .env file:
WIKIJS_URL=https://your-wiki.example.com
WIKIJS_API_TOKEN=your_api_token_here
NODE_TLS_REJECT_UNAUTHORIZED=0 # Only for self-signed certificates3. Build the Project
npm run build4. Test Connection
node examples/test-connection.jsβοΈ Configuration
Environment Variables
Variable | Description | Required | Default |
| Base URL of your Wiki.js instance | β Yes | - |
| API token for authentication | β Yes | - |
| SSL certificate validation (0=disabled, 1=enabled) | β No | 1 |
Claude Desktop Integration
Add the following configuration to your Claude Desktop config file (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
"mcpServers": {
"wikijs": {
"command": "node",
"args": ["/absolute/path/to/mcp-wikijs/dist/index.js"],
"env": {
"WIKIJS_URL": "https://your-wiki.example.com",
"WIKIJS_API_TOKEN": "your_api_token_here"
}
}
}
}π§ Usage
Available MCP Tools
π Page Operations
Tool | Description | Parameters |
| Search for pages by title or content |
|
| Retrieve a specific page |
|
| Create a new page |
|
| Update an existing page |
|
| Delete a page |
|
| List all pages with pagination |
|
π₯ User Operations
Tool | Description | Parameters |
| Search for users |
|
| Get user information by ID |
|
π Group Operations
Tool | Description | Parameters |
| List all user groups | None |
Example Usage with WikiJsClient
const { WikiJsClient } = require('./dist/wikijs-client');
const client = new WikiJsClient({
baseUrl: process.env.WIKIJS_URL,
apiToken: process.env.WIKIJS_API_TOKEN
});
// Create a new page
const newPage = await client.createPage({
title: 'My New Page',
content: '# Welcome\n\nThis is my new page content.',
path: 'my-new-page',
description: 'A sample page created via API',
tags: ['documentation', 'api']
});
// Search for pages
const searchResults = await client.searchPages({
query: 'documentation',
limit: 10
});
// Get a specific page
const page = await client.getPage({ path: 'my-new-page' });
// Update a page
const updatedPage = await client.updatePage({
id: page.id,
title: 'Updated Page Title',
content: '# Updated Content\n\nThis page has been updated.'
});
// List all pages
const allPages = await client.listPages({ limit: 50, offset: 0 });
// Search users
const users = await client.searchUsers({ query: 'admin', limit: 5 });
// List groups
const groups = await client.listGroups();π Project Structure
mcp-wikijs/
βββ π src/
β βββ π index.ts # MCP server implementation
β βββ π wikijs-client.ts # Wiki.js API client
βββ π dist/ # Compiled JavaScript
βββ π examples/ # Usage examples and tests
β βββ π test-connection.js
β βββ π usage-example.js
β βββ π claude-desktop-config.json
βββ π docs/ # Documentation
β βββ π journal.md # Development journal
βββ π .env.example # Environment template
βββ π package.json # Dependencies and scripts
βββ π tsconfig.json # TypeScript configuration
βββ π README.md # This fileπ API Reference
WikiJsClient Class
Constructor
new WikiJsClient(config: WikiJsConfig)Parameters:
config.baseUrl: Wiki.js instance URLconfig.apiToken: API authentication token
Page Methods
searchPages(params: SearchPagesParams)
interface SearchPagesParams {
query: string; // Search query string
limit?: number; // Maximum results (default: 10)
}getPage(params: GetPageParams)
interface GetPageParams {
id?: number; // Page ID (optional)
path?: string; // Page path (optional)
// Note: Either id or path must be provided
}createPage(params: CreatePageParams)
interface CreatePageParams {
title: string; // Page title
content: string; // Page content in markdown
path: string; // URL slug
description?: string; // Page description
tags?: string[]; // Array of tags
isPublished?: boolean; // Published status (default: true)
isPrivate?: boolean; // Private status (default: false)
locale?: string; // Page locale (default: 'en')
editor?: string; // Editor type (default: 'markdown')
}updatePage(params: UpdatePageParams)
interface UpdatePageParams {
id: number; // Page ID to update
title?: string; // New title
content?: string; // New content
description?: string; // New description
tags?: string[]; // New tags
isPublished?: boolean; // Published status
isPrivate?: boolean; // Private status
}deletePage(params: DeletePageParams)
interface DeletePageParams {
id: number; // Page ID to delete
}listPages(params: ListPagesParams)
interface ListPagesParams {
limit?: number; // Maximum pages (default: 50)
offset?: number; // Skip pages (default: 0)
}User Methods
searchUsers(params: SearchUsersParams)
interface SearchUsersParams {
query: string; // Search query
limit?: number; // Maximum results (default: 10)
}getUser(params: GetUserParams)
interface GetUserParams {
id: number; // User ID
}listGroups()
No parameters required
Returns array of user groups
π§ͺ Development
Building
npm run buildTesting
# Test connection
node examples/test-connection.js
# Run usage examples
node examples/usage-example.js
# Type checking
npx tsc --noEmitRunning the MCP Server
# Start the MCP server
node dist/index.js
# The server will run on stdio and wait for MCP protocol messagesπ Troubleshooting
Common Issues
SSL Certificate Errors
Error: self signed certificateSolution: Set NODE_TLS_REJECT_UNAUTHORIZED=0 in your .env file for self-signed certificates (development only).
Authentication Failures
Wiki.js API Error: 401 - UnauthorizedSolution:
Verify your API token is valid
Check that the token has sufficient permissions
Ensure the Wiki.js API endpoint is accessible
GraphQL Errors
Wiki.js API Error: 400 - Bad RequestSolution:
Ensure Wiki.js version compatibility
Check API token permissions for specific operations
Verify GraphQL query syntax
Module Loading Errors
ERR_MODULE_NOT_FOUNDSolution:
Run
npm installto ensure all dependencies are installedVerify Node.js version (18+ required)
Check that the project has been built with
npm run build
Debug Mode
Enable debug logging:
DEBUG=wikijs-mcp:* node dist/index.jsSchema Validation Issues
If you encounter MCP schema validation errors:
Ensure
zod-to-json-schemais installedVerify all tool definitions use
zodToJsonSchema()conversionCheck that JSON Schema format is properly applied
π€ Contributing
Fork the repository
Create a feature branch (
git checkout -b feature/amazing-feature)Make your changes
Add tests if applicable
Commit your changes (
git commit -m 'Add amazing feature')Push to the branch (
git push origin feature/amazing-feature)Open a Pull Request
Development Guidelines
Follow TypeScript best practices
Maintain comprehensive type definitions
Update documentation for new features
Add tests for new functionality
Follow existing code style and patterns
π License
MIT License - see LICENSE file for details.
π Support
For issues and questions:
π Check the troubleshooting section
π Review existing GitHub issues
π Create a new issue with detailed information
π Check the development journal for recent changes
π Acknowledgments
Model Context Protocol for the MCP specification
Wiki.js for the excellent wiki platform
Anthropic for Claude Desktop integration
Status: β
Production Ready
Last Updated: August 8, 2025
Version: 1.0.0
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
This server cannot be deployed
Maintenance
Related MCP Connectors
Shared project wiki for AI agents: read and write pages, next actions, and activity logs over MCP.
Read and write your team's shared, AI-readable wiki from any MCP client.
Hosted markdown project wikis your team's AI assistants read, search, and update over MCP.
Enable Large Language Model clients to interact seamlessly with any MediaWiki wiki. Perform actionβ¦
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to search, retrieve, and optionally edit pages in a WikiJS knowledge base via the Model Context Protocol.26 npm1MIT

mcp-server-ispace-wikiofficial
AlicenseAqualityDmaintenanceEnables AI assistants to perform CRUD operations, search, batch operations, and commenting on iSpace Wiki documents.32MIT- AlicenseNot gradedqualityBmaintenanceEnables AI agents to read, search, and write to a public wiki knowledge base via MCP.1MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to turn conversations into a searchable personal wiki, read and organize pages, and propose edits such as merges, translations, and fact-checks as reviewable changesets.3MIT