get_mitigations
Retrieve paginated mitigation data from the Devici API to manage threat modeling resources efficiently. Specify page and limit for targeted results.
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)MCP tool handler function that executes the get_mitigations tool logic by calling the API client.@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)
- API client helper method that performs the HTTP request to fetch mitigations from the Devici API.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)
- src/devici_mcp_server/server.py:171-171 (registration)Registration of the get_mitigations tool using the FastMCP decorator.@mcp.tool()