mcp-workflow-server-enhanced
Version:
Enhanced MCP Workflow Server with smart problem routing, comprehensive validation, guide compliance, and robust error handling. Intelligently routes to appropriate AI functions based on problem type.
42 lines (32 loc) • 1.02 kB
text/typescript
/**
* MCP Workflow Server CLI
*
* Command-line interface for running the MCP Workflow Server
*/
import { MCPWorkflowServer } from './server.js';
async function main() {
try {
console.log('Starting MCP Workflow Server...');
const server = new MCPWorkflowServer();
await server.start();
console.log('MCP Workflow Server is running and ready to accept connections.');
console.log('Use Ctrl+C to stop the server.');
// Handle graceful shutdown
process.on('SIGINT', () => {
console.log('\nShutting down MCP Workflow Server...');
process.exit(0);
});
process.on('SIGTERM', () => {
console.log('\nShutting down MCP Workflow Server...');
process.exit(0);
});
} catch (error) {
console.error('Failed to start MCP Workflow Server:', error);
process.exit(1);
}
}
// Only run if this file is executed directly
if (import.meta.url === `file://${process.argv[1]}`) {
main().catch(console.error);
}