health_check
Monitor and verify the operational status of the CSV Editor MCP server to ensure its functionality for data processing, analysis, and validation tasks.
Instructions
Check the health status of the CSV Editor.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/csv_editor/server.py:28-54 (handler)The main handler function for the 'health_check' tool. It is decorated with @mcp.tool, which also serves as the registration. Performs a health check by retrieving session manager stats and returns status information.@mcp.tool async def health_check(ctx: Context) -> Dict[str, Any]: """Check the health status of the CSV Editor.""" session_manager = get_session_manager() try: active_sessions = len(session_manager.sessions) if ctx: await ctx.info("Health check performed successfully") return { "success": True, "status": "healthy", "version": "1.0.0", "active_sessions": active_sessions, "max_sessions": session_manager.max_sessions, "session_ttl_minutes": session_manager.ttl_minutes, } except Exception as e: if ctx: await ctx.error(f"Health check failed: {str(e)}") return { "success": False, "status": "error", "error": str(e) }