Skip to main content
Glama
server.ts961 B
/* eslint-disable n/no-missing-import */ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js'; /* eslint-enable n/no-missing-import */ import { createRequire } from 'node:module'; import { registerAllTools } from './tools/index.js'; import { registerAllResources } from './resources/index.js'; // https://github.com/nodejs/node/issues/51347#issuecomment-2111337854 const packageInfo = createRequire( import.meta.url )( '../package.json' ) as { version: string }; const SERVER_NAME: string = 'mediawiki-mcp-server'; const SERVER_VERSION: string = packageInfo.version; export const createServer = (): McpServer => { const server = new McpServer( { name: SERVER_NAME, version: SERVER_VERSION }, { capabilities: { resources: { listChanged: true } } } ); registerAllTools( server ); registerAllResources( server ); return server; }; export const USER_AGENT: string = `${ SERVER_NAME }/${ SERVER_VERSION }`;

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/ProfessionalWiki/MediaWiki-MCP-Server'

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