#!/bin/bash
# π§ͺ Quick MCP Test Script
# Run this to test your MCP server locally
cd /Users/eugenezhou/Code/medical-research-mcp-suite
echo "π₯ Testing Medical Research MCP Suite..."
echo ""
# Build the project first
echo "π¨ Building project..."
npm run build
if [ $? -ne 0 ]; then
echo "β Build failed"
exit 1
fi
echo "β
Build successful"
echo ""
# Test 1: List available tools
echo "π§ Test 1: Listing available tools..."
echo '{"method":"tools/list","params":{}}' | node dist/index.js
echo ""
echo "β
Tools list test complete"
echo ""
# Test 2: Search clinical trials
echo "π₯ Test 2: Searching clinical trials for diabetes..."
echo '{"method":"tools/call","params":{"name":"ct_search_trials","arguments":{"condition":"diabetes","pageSize":3}}}' | node dist/index.js
echo ""
echo "β
Clinical trials search test complete"
echo ""
# Test 3: Get specific study details
echo "π Test 3: Getting study details..."
echo '{"method":"tools/call","params":{"name":"ct_get_study","arguments":{"nctId":"NCT04373031"}}}' | node dist/index.js
echo ""
echo "β
Study details test complete"
echo ""
# Test 4: Search PubMed
echo "π Test 4: Searching PubMed literature..."
echo '{"method":"tools/call","params":{"name":"pm_search_papers","arguments":{"query":"diabetes metformin","maxResults":3}}}' | node dist/index.js
echo ""
echo "β
PubMed search test complete"
echo ""
# Test 5: Cross-API analysis (the magic!)
echo "π¬ Test 5: Cross-API comprehensive analysis..."
echo '{"method":"tools/call","params":{"name":"research_comprehensive_analysis","arguments":{"drugName":"metformin","condition":"diabetes","analysisDepth":"basic"}}}' | node dist/index.js
echo ""
echo "β
Cross-API analysis test complete"
echo ""
echo "π All tests completed successfully!"
echo ""
echo "Next steps:"
echo "1. Try more complex queries"
echo "2. Test with Claude Desktop integration"
echo "3. Deploy to Cloudflare for live demo"