<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="Model Context Protocol Server - API Documentation">
<title>MCP Server - API Documentation</title>
<link rel="icon" type="image/svg+xml" href="data:image/svg+xml,%3Csvg width='164' height='153' viewBox='0 0 164 153' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M65.2457 0.787897C13.3337 8.3209 -16.2674 67.4239 9.40665 112.28C34.2726 155.722 94.2736 165.677 134.973 133.112C153.751 118.086 162.682 98.2899 163.187 70.5749C163.43 57.1739 164.11 58.4499 156.736 58.4679C149.362 58.4859 149.392 58.4969 148.822 55.7129C141.498 19.9819 103.783 -4.8041 65.2457 0.787897ZM73.3537 40.1069L73.4536 71.2589L43.0806 71.3029C26.3746 71.3259 11.8716 71.3809 10.8516 71.4249L8.99565 71.5029V70.0819C8.99565 54.2259 21.4706 32.5639 37.0526 21.3629C46.3896 14.6509 63.4437 8.5889 72.0816 8.9109L73.2536 8.9549L73.3537 40.1069ZM89.6597 9.9829C106.329 13.2159 121.93 23.0109 130.762 35.7859C134.695 41.4759 139.392 51.6239 140.078 55.9119L140.326 57.4639L136.673 57.7049C106.55 59.6859 80.8186 81.8239 75.0586 110.712C73.1076 120.497 72.9986 126.219 74.4706 141.338L74.7336 144.035L72.0406 143.763C59.9986 142.548 46.8546 137.437 37.0246 130.149L33.9586 127.875L34.8557 126.771C35.6497 125.795 58.7296 100.309 75.8746 81.4769L82.0426 74.7019V41.7789V8.8549L83.8987 9.0399C84.9187 9.1419 87.5117 9.5659 89.6597 9.9829ZM151.145 66.4299L154.817 66.6929L154.578 73.1749C153.385 105.482 135.395 129.841 105.279 139.924C97.3806 142.569 85.8516 144.461 87.1526 142.899C98.9776 128.7 100.287 127.163 108.412 117.947C119.057 105.874 132.043 90.0519 132.043 89.1569C132.043 87.0209 130.243 87.2949 127.081 89.9119C125.589 91.1469 122.447 93.7329 120.1 95.6589C111.789 102.477 103.031 111.739 89.2696 128.263L82.6286 136.237L82.3036 133.533C78.7606 104.04 95.5686 77.9219 123.84 68.9939C133.013 66.0979 138.855 65.5489 151.145 66.4299ZM66.4176 79.6959C66.4176 79.8249 64.6936 81.8029 62.5856 84.0909C60.4776 86.3789 52.6867 94.9309 45.2717 103.095C37.8567 111.259 30.8787 118.906 29.7647 120.087L27.7396 122.236L25.3987 119.697C16.3837 109.92 10.1166 95.9049 8.76364 82.4959L8.49864 79.8659L19.3916 79.7549C44.0896 79.5049 66.4176 79.4769 66.4176 79.6959Z' fill='%2300FF00'/%3E%3C/svg%3E">
<script src="https://cdn.jsdelivr.net/npm/@tailwindcss/browser@4"></script>
<style type="text/tailwindcss">
@theme {
--color-primary: #2563eb;
--color-secondary: #7c3aed;
--color-accent: #0891b2;
--color-success: #059669;
--color-warning: #d97706;
}
.card {
background: rgba(255, 255, 255, 0.03);
backdrop-filter: blur(8px);
border: 1px solid rgba(255, 255, 255, 0.08);
}
.card:hover {
background: rgba(255, 255, 255, 0.06);
border-color: rgba(255, 255, 255, 0.12);
}
.section-header {
border-bottom: 2px solid rgba(255, 255, 255, 0.1);
padding-bottom: 0.75rem;
margin-bottom: 1.5rem;
}
</style>
</head>
<body class="bg-gradient-to-br from-slate-900 via-indigo-950 to-slate-900 min-h-screen text-gray-100">
<div class="container mx-auto px-6 py-12 max-w-7xl">
<!-- Header -->
<header class="mb-12">
<h1 class="text-4xl md:text-5xl font-bold mb-3 text-center text-white">
Model Context Protocol Server
</h1>
<p class="text-lg md:text-xl text-center text-gray-300 max-w-3xl mx-auto">
API Documentation and Deployment Guide
</p>
</header>
<!-- API Endpoints -->
<section class="card rounded-xl p-8 mb-8">
<h2 class="text-2xl font-bold section-header text-white">
API Endpoints
</h2>
<div class="grid grid-cols-1 md:grid-cols-2 gap-4">
<div class="bg-slate-800/50 rounded-lg p-5 border border-slate-700 hover:border-slate-600 transition-colors">
<div class="flex items-center gap-3 mb-2">
<span class="bg-success text-white px-3 py-1 rounded text-xs font-semibold tracking-wide">GET</span>
<code class="text-cyan-400 font-mono text-sm">/health</code>
</div>
<p class="text-gray-400 text-sm">Health check endpoint for monitoring</p>
</div>
<div class="bg-slate-800/50 rounded-lg p-5 border border-slate-700 hover:border-slate-600 transition-colors">
<div class="flex items-center gap-3 mb-2">
<span class="bg-success text-white px-3 py-1 rounded text-xs font-semibold tracking-wide">GET</span>
<code class="text-cyan-400 font-mono text-sm">/info</code>
</div>
<p class="text-gray-400 text-sm">Server metadata and configuration</p>
</div>
<div class="bg-slate-800/50 rounded-lg p-5 border border-slate-700 hover:border-slate-600 transition-colors">
<div class="flex items-center gap-3 mb-2">
<span class="bg-success text-white px-3 py-1 rounded text-xs font-semibold tracking-wide">GET</span>
<code class="text-cyan-400 font-mono text-sm">/tools</code>
</div>
<p class="text-gray-400 text-sm">List all available MCP tools</p>
</div>
<div class="bg-slate-800/50 rounded-lg p-5 border border-slate-700 hover:border-slate-600 transition-colors">
<div class="flex items-center gap-3 mb-2">
<span class="bg-primary text-white px-3 py-1 rounded text-xs font-semibold tracking-wide">POST</span>
<code class="text-cyan-400 font-mono text-sm">/mcp</code>
</div>
<p class="text-gray-400 text-sm">Main MCP protocol endpoint</p>
</div>
</div>
</section>
<!-- MCP Tools -->
<section class="card rounded-xl p-8 mb-8">
<div class="flex items-center justify-between mb-6">
<h2 class="text-2xl font-bold text-white">MCP Tools</h2>
<span class="bg-indigo-600 text-white px-4 py-1.5 rounded-lg text-sm font-semibold">{{ tools_count }} Available</span>
</div>
<div class="border-t border-slate-700 pt-6">
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4">
{{ tools_html }}
</div>
</div>
</section>
<!-- Deployment Guide -->
<section class="card rounded-xl p-8 mb-8">
<h2 class="text-2xl font-bold section-header text-white">
Deployment Guide
</h2>
<!-- Local Development -->
<div class="mb-8">
<h3 class="text-xl font-semibold text-indigo-300 mb-4">Local Development</h3>
<div class="space-y-4">
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<h4 class="font-semibold text-base mb-2 text-white">1. Install Dependencies</h4>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">pip install -r requirements.txt</code>
</div>
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<h4 class="font-semibold text-base mb-2 text-white">2. Configure Environment</h4>
<p class="text-gray-400 text-sm mb-2">Set required environment variables:</p>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">export PORT=8000<br>export MONGODB_URI=your_connection_string</code>
</div>
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<h4 class="font-semibold text-base mb-2 text-white">3. Start Server</h4>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">python main.py</code>
</div>
</div>
</div>
<!-- Docker Deployment -->
<div class="mb-8">
<h3 class="text-xl font-semibold text-indigo-300 mb-4">Docker Deployment</h3>
<div class="space-y-4">
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<h4 class="font-semibold text-base mb-2 text-white">Standard Deployment</h4>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">docker compose up --build -d</code>
<p class="text-gray-400 text-sm mt-2">Builds and starts the service in detached mode</p>
</div>
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<h4 class="font-semibold text-base mb-2 text-white">Test-Driven Deployment</h4>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">./scripts/test-and-run.sh</code>
<p class="text-gray-400 text-sm mt-2">Runs automated tests before deployment. Deployment only proceeds if all tests pass.</p>
</div>
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<h4 class="font-semibold text-base mb-2 text-white">Manual Test Execution</h4>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">docker compose -f docker-compose.test.yml up --build --abort-on-container-exit</code>
<p class="text-gray-400 text-sm mt-2">Runs tests in isolated containers with automatic cleanup</p>
</div>
</div>
</div>
<!-- Testing -->
<div>
<h3 class="text-xl font-semibold text-indigo-300 mb-4">Testing</h3>
<div class="bg-slate-800/30 rounded-lg p-5 border border-slate-700">
<p class="text-gray-400 text-sm mb-3">Run the test suite locally:</p>
<code class="block bg-slate-950 text-gray-300 px-4 py-3 rounded text-sm font-mono">pytest -v</code>
<div class="mt-4 pt-4 border-t border-slate-700">
<p class="text-gray-400 text-sm mb-2">Test coverage includes:</p>
<ul class="list-disc list-inside text-gray-400 text-sm space-y-1">
<li>Server initialization and health checks</li>
<li>Tool registration and execution</li>
<li>API endpoint responses</li>
<li>Error handling and edge cases</li>
</ul>
</div>
</div>
</div>
</section>
<!-- Footer -->
<footer class="text-center text-gray-500 border-t border-slate-800 pt-8 mt-12">
<p class="text-sm">Built with FastMCP and Tailwind CSS</p>
</footer>
</div>
</body>
</html>