Skip to main content
Glama

MCP Learning Project

by BerdTan
simple_restart.pyโ€ข2.07 kB
#!/usr/bin/env python3 """ Simple Restart Script for MCP Servers """ import subprocess import time import sys def stop_servers(): """Stop running servers using taskkill.""" print("๐Ÿ›‘ Stopping existing servers...") try: # Kill Python processes that might be our servers subprocess.run(['taskkill', '/f', '/im', 'python.exe'], capture_output=True, text=True) print("โœ… Stopped Python processes") except FileNotFoundError: print("โš ๏ธ taskkill not available") # Wait for cleanup time.sleep(2) def start_enhanced_harness(): """Start the enhanced MCP harness.""" print("\n๐Ÿš€ Starting Enhanced MCP Harness...") try: # Start the enhanced harness in background subprocess.Popen([sys.executable, 'enhanced_mcp_harness.py']) print("โœ… Enhanced MCP Harness started on localhost:8000") # Wait a moment time.sleep(3) # Start the enhanced web interface in background print("\n๐ŸŒ Starting Enhanced Web Interface...") subprocess.Popen([sys.executable, 'enhanced_web_interface.py']) print("โœ… Enhanced Web Interface started on localhost:3003") print("\n๐ŸŽ‰ All servers started successfully!") print("\n๐Ÿ“‹ Available URLs:") print(" โ€ข Enhanced Web Interface: http://localhost:3003") print(" โ€ข MCP Server: localhost:8000") print("\n๐Ÿ’ก You can now:") print(" โ€ข Open http://localhost:3003 in your browser") print(" โ€ข Test with: py -3 test_client.py") except Exception as e: print(f"โŒ Error starting servers: {e}") def main(): """Main function.""" print("๐Ÿ”„ Simple MCP Server Restart") print("=" * 30) # Stop servers stop_servers() # Start enhanced harness start_enhanced_harness() print("\nโœ… Restart completed!") if __name__ == "__main__": main()

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/BerdTan/mcpharness'

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