Skip to main content
Glama
jamiesonio

DefectDojo MCP Server

by jamiesonio

list_products

Retrieve and filter products in DefectDojo using pagination for efficient vulnerability management. Supports parameters like name, product type, limit, and offset for customizable queries.

Instructions

List all products with optional filtering and pagination support

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNo
nameNo
offsetNo
prod_typeNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The core handler function that implements the logic for listing DefectDojo products with optional filters (name, product type), pagination (limit, offset), using the DefectDojo client.
    async def list_products(name: Optional[str] = None, prod_type: Optional[int] = None,
                           limit: int = 50, offset: int = 0) -> Dict[str, Any]:
        """List all products with optional filtering and pagination.
    
        Args:
            name: Optional name filter (partial match)
            prod_type: Optional product type ID filter
            limit: Maximum number of products to return per page (default: 50)
            offset: Number of records to skip (default: 0)
    
        Returns:
            Dictionary with status, data/error, and pagination metadata
        """
        filters = {"limit": limit}
        # Use __icontains for case-insensitive partial match if API supports it
        if name:
            filters["name"] = name # Or name__icontains if supported
        if prod_type:
            filters["prod_type"] = prod_type
        if offset:
            filters["offset"] = offset
    
        client = get_client()
        result = await client.get_products(filters)
    
        if "error" in result:
            return {"status": "error", "error": result["error"], "details": result.get("details", "")}
    
        return {"status": "success", "data": result}
  • Primary registration of the list_products tool using the central FastMCP instance in tools.py.
        name="list_products",
        description="List all products with optional filtering and pagination support"
    )(list_products)
  • Module-specific registration function for the list_products tool in products_tools.py.
    def register_tools(mcp):
        """Register product-related tools with the MCP server instance."""
        mcp.tool(name="list_products", description="List all products with optional filtering and pagination support")(list_products)
  • Import of the list_products handler from products_tools.py into the central tools.py.
    from .products_tools import list_products
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden for behavioral disclosure. While it mentions filtering and pagination support, it doesn't describe important behaviors like whether this is a read-only operation, what permissions are required, rate limits, response format, or what happens when no products match filters. The description is insufficient for a tool with 4 parameters and no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core purpose ('List all products') and adds key capabilities. Every word earns its place with no redundancy or unnecessary elaboration.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 4 parameters with 0% schema coverage and no annotations, but with an output schema present, the description provides basic purpose but lacks sufficient detail about parameter usage, behavioral constraints, and operational context. The output schema reduces the need to describe return values, but the description should do more to compensate for the complete lack of schema descriptions and annotations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate. It mentions 'optional filtering and pagination support' which hints at the purpose of some parameters, but doesn't explain what 'prod_type' represents, what format 'name' filtering uses, or the relationship between limit/offset parameters. The description adds minimal value beyond the bare parameter names in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('List') and resource ('products'), making the purpose immediately understandable. It distinguishes from siblings by focusing on product listing rather than engagement/finding operations, though it doesn't explicitly contrast with specific product-related alternatives that might exist.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description mentions 'optional filtering and pagination support' which provides some context about when to use parameters, but offers no guidance on when to choose this tool versus alternatives like search_findings or other product-specific tools. No explicit when/when-not statements or sibling comparisons are provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Related Tools

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/jamiesonio/defectdojo-mcp'

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