get_mitigations
Retrieve threat mitigation strategies from the Devici platform with paginated results to manage security controls effectively.
Instructions
Get mitigations from Devici with pagination
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| page | No |
Implementation Reference
- src/devici_mcp_server/server.py:171-176 (handler)The MCP tool handler for the 'get_mitigations' tool. It is registered via the @mcp.tool() decorator and delegates to the API client to fetch paginated mitigations from the Devici API.@mcp.tool() async def get_mitigations(limit: int = 20, page: int = 0) -> str: """Get mitigations from Devici with pagination""" async with create_client_from_env() as client: result = await client.get_mitigations(limit=limit, page=page) return str(result)
- The API client helper function that implements the core logic for retrieving mitigations via HTTP GET request to the Devici API endpoint with pagination parameters.async def get_mitigations(self, limit: int = 20, page: int = 0) -> Dict[str, Any]: """Get all mitigations.""" params = {"limit": limit, "page": page} return await self._make_request("GET", "/mitigations/", params=params)