INNER CODE UNIT · Python

index

marc-shade/world-intel-mcp · src/world_intel_mcp/dashboard/app.py:316

async def index(request):
    """Serve the dashboard HTML page (reloads on each request during dev)."""
    html_path = Path(__file__).parent / "index.html"
    return HTMLResponse(html_path.read_text())


async def api_overview(request):
    """REST endpoint — full snapshot of all intelligence domains."""
    data = await _fetch_overview()
    return JSONResponse(data, headers={"Access-Control-Allow-Origin": "*"})


async def api_stream(request):
    """SSE endpoint — progressive: emits each source as it completes."""

    async def event_generator():
        while True:
            try:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…