mcpField
P
prowler-mcp

prowler-mcp

github.com/prowler-cloudDevelopment15.1k68 installsUpdated today
Repository

About prowler-mcp

prowler-mcp is a skill for developing Prowler's MCP server. It documents tool implementation and response-model conventions, with separate guidance for Prowler management, security catalog, and documentation search tools.

Key features

  1. 01Prowler tool implementation conventions
  2. 02Response model and API client guidance
  3. 03Automatic tool registration guidance
  4. 04Hub and Docs tool patterns
  5. 05Testing and QA checklist

Use cases

  1. 01Adding a Prowler management tool
  2. 02Implementing security catalog or docs tools
  3. 03Reviewing MCP tool changes and tests

MCP support

The skill describes a Prowler MCP server with three namespaced sub-servers: Prowler management tools, Prowler Hub security checks catalog, and Prowler Docs search.

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/prowler-cloud/prowler --skill prowler-mcp

After installing, type/prowler-mcpin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

assets/
base_tool.py
models.py
tool_implementation.py

Details

From the project README

Overview

The Prowler MCP Server uses three sub-servers with prefixed namespacing:

Sub-ServerPrefixAuthPurpose
Prowlerprowler_*RequiredProwler Cloud, Private Cloud & Local Server management tools
Prowler Hubprowler_hub_*NoSecurity checks catalog
Prowler Docsprowler_docs_*NoDocumentation search

For complete architecture, patterns, and examples, see docs/developer-guide/mcp-server.mdx.


Critical Rules (Prowler Tools Only)

Tool Implementation
  • ALWAYS: Extend BaseTool (auto-registered via tool_loader.py, only public methods from the class are exposed as a tool)
  • NEVER: Manually register BaseTool subclasses
  • NEVER: Import tools directly in server.py
Models
  • ALWAYS: Use MinimalSerializerMixin for responses
  • ALWAYS: Implement from_api_response() factory method
  • ALWAYS: Use two-tier models (Simplified for lists, Detailed for single items)
  • NEVER: Return raw API responses
API Client
  • ALWAYS: Use self.api_client singleton
  • ALWAYS: Use build_filter_params() for query parameters
  • NEVER: Create new httpx clients

Hub/Docs Tools

Use @mcp.tool() decorator directly—no BaseTool or models required.


Quick Reference: New Prowler Tool

  1. Create tool class in prowler_app/tools/ extending BaseTool
  2. Create models in prowler_app/models/ using MinimalSerializerMixin
  3. Tools auto-register via tool_loader.py

QA Checklist (Prowler Tools)

  • Tool docstrings describe LLM-relevant behavior
  • Models use MinimalSerializerMixin
  • API responses transformed to simplified models
  • Failures are raised, never returned. A returned error dict is reported as a success. Raise InvalidArgument for a bad argument, let ProwlerAPIError/ProwlerAPIUnreachable propagate, and raise ToolError without a from clause only for a sentence lib/errors.py cannot know (a resource name, a precondition, the next tool to call)
  • Parameters use Field() with descriptions
  • No hardcoded secrets
  • Tests added under mcp_server/tests/

Resources

Comments

Markdown supported