Skip to main content
Glama
test_http.py1.06 kB
#!/usr/bin/env python3 import asyncio import httpx async def test_http_server(): """Test the HTTP server to see if tools are available via HTTP endpoints.""" # Test basic connectivity try: async with httpx.AsyncClient() as client: # Test the tools endpoint response = await client.post("http://localhost:8081/tools/list", json={}) print(f"Tools list response status: {response.status_code}") if response.status_code == 200: tools_data = response.json() print(f"Number of tools via HTTP: {len(tools_data.get('tools', []))}") print("Tool names via HTTP:") for tool in tools_data.get('tools', []): print(f" - {tool.get('name')}") else: print(f"Error response: {response.text}") except Exception as e: print(f"Error connecting to HTTP server: {e}") if __name__ == "__main__": print("Testing HTTP server at localhost:8081...") asyncio.run(test_http_server())

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/DynamicEndpoints/PowerShell-Exec-MCP-Server'

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