Skip to main content
Glama

list_countermeasures

Identify and filter countermeasures for a project by status and page size using the SD Elements MCP Server, enabling efficient security development lifecycle management.

Instructions

List countermeasures for a project

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
page_sizeNoNumber of results per page (optional)
project_idYesThe ID of the project
statusNoFilter by countermeasure status

Implementation Reference

  • The main handler function for the 'list_countermeasures' MCP tool. It is decorated with @mcp.tool(), which serves as both the implementation and registration. The function takes project_id and optional filters, queries the SD Elements API via api_client, and returns the result as formatted JSON.
    @mcp.tool() async def list_countermeasures(ctx: Context, project_id: int, status: Optional[str] = None, page_size: Optional[int] = None, risk_relevant: bool = True) -> str: """List all countermeasures for a project. Use this to see countermeasures associated with a project, not get_project which returns project details.""" global api_client if api_client is None: api_client = init_api_client() params = {} if status is not None: params["status"] = status if page_size is not None: params["page_size"] = page_size params["risk_relevant"] = str(risk_relevant).lower() result = api_client.list_countermeasures(project_id, params) return json.dumps(result, indent=2)

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/geoffwhittington/sde-mcp'

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