Skip to main content
Glama

adv_get_status

Retrieve comprehensive server status including session management capabilities, active sessions, and cache statistics for security monitoring and vulnerability detection.

Instructions

Get comprehensive server status including session management capabilities, active sessions, and cache statistics

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Handler function that implements the logic for the 'adv_get_status' tool. It gathers server capabilities, security constraints, session management status, and returns a JSON-formatted status report.
    async def _handle_get_status( self, name: str, arguments: dict ) -> list[types.TextContent]: """Handle comprehensive status requests including session management.""" try: capabilities = self._scan_service.get_scan_capabilities() security_constraints = self._scan_service.get_security_constraints() status = { "server": "adversary", "capabilities": capabilities, "security_constraints": security_constraints, "status": "operational", "session_management": { "available": self._session_manager is not None, "active_sessions": 0, "cache_statistics": {}, }, } # Add session management information if available if self._session_manager: status["session_management"]["active_sessions"] = len( self._session_manager.list_active_sessions() ) status["session_management"][ "cache_statistics" ] = self._session_manager.get_cache_statistics() status["session_management"]["features"] = [ "context_aware_analysis", "project_context_caching", "multi_phase_analysis", "cross_file_analysis", "intelligent_cache_warming", ] return [ types.TextContent( type="text", text=json.dumps(status, indent=2, default=str) ) ] except Exception as e: logger.error(f"Status check failed: {e}") raise CleanAdversaryToolError(f"Status check failed: {str(e)}")
  • The tool dispatcher function decorated with @self.server.call_tool() that routes calls to 'adv_get_status' to its handler _handle_get_status.
    @self.server.call_tool() async def tool_dispatcher( name: str, arguments: dict ) -> list[types.TextContent]: """Dispatch MCP tool calls to the appropriate handler.""" if name == "adv_scan_file": return await self._handle_scan_file(name, arguments) elif name == "adv_scan_folder": return await self._handle_scan_folder(name, arguments) elif name == "adv_scan_code": return await self._handle_scan_code(name, arguments) elif name == "adv_get_status": return await self._handle_get_status(name, arguments) elif name == "adv_get_version": return await self._handle_get_version(name, arguments) elif name == "adv_mark_false_positive": return await self._handle_mark_false_positive(name, arguments) elif name == "adv_unmark_false_positive": return await self._handle_unmark_false_positive(name, arguments) else: raise ValueError(f"Unknown tool: {name}")
  • The Tool schema definition for 'adv_get_status' in the get_tools() method, specifying name, description, and empty input schema.
    name="adv_get_status", description="Get comprehensive server status including session management capabilities, active sessions, and cache statistics", inputSchema={"type": "object", "properties": {}}, ),

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/brettbergin/adversary-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server