Skip to main content
Glama
index-stdio.ts1.49 kB
#!/usr/bin/env node /** * MCP DinCoder Server - STDIO Transport Entry Point * * This is the main entry point for running the server with stdio transport. * Used when installed via npm and run through npx or Claude Code. */ import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js'; import { createServer } from './server/createServer.js'; async function main() { try { // Create the MCP server const server = createServer({ name: 'DinCoder', version: '0.1.6', capabilities: { tools: true, resources: false, prompts: false, }, }); // Create stdio transport const transport = new StdioServerTransport(); // Connect server to transport await server.connect(transport); // Log to stderr (stdout is used for communication) console.error('MCP DinCoder Server started (stdio transport)'); console.error('Ready to receive requests...'); // Handle graceful shutdown process.on('SIGINT', async () => { console.error('\nShutting down...'); await server.close(); process.exit(0); }); process.on('SIGTERM', async () => { console.error('\nShutting down...'); await server.close(); process.exit(0); }); } catch (error) { console.error('Failed to start server:', error); process.exit(1); } } // Always run when this file is executed (needed for npx compatibility) main().catch(console.error); export { main };

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/flight505/MCP_DinCoder'

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