We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Beefsupreme21/mcp-hackathon'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
test_mcp.pyβ’1.13 KiB
#!/usr/bin/env python3
"""
Test script to verify the Strava MCP server setup
"""
import asyncio
from strava_mcp import app
async def test_mcp():
"""Test the MCP server functionality"""
print("π§ͺ Testing Strava MCP Server...")
try:
# Test the tool function directly
print("\nπ Testing get_strava_activities function...")
result = await app.call_tool("get_strava_activities", {"limit": 2})
print("β Function executed successfully!")
print(f"π Output type: {type(result)}")
print("\nπ Sample output:")
print("-" * 50)
print(result)
print("-" * 50)
print("\nπ All tests passed! MCP server is ready to run.")
print("\nπ‘ Next steps:")
print(" 1. Run: python run_server.py")
print(" 2. Connect with an MCP client")
print(" 3. Call get_strava_activities tool")
except Exception as e:
print(f"β Test failed: {e}")
return False
return True
if __name__ == "__main__":
success = asyncio.run(test_mcp())
if not success:
exit(1)