An MCP server that provides tools to list and retrieve products from a FastAPI-backed product catalog with PostgreSQL storage.
This server has 2 tools with basic definitions. Both tools have action-verb names and descriptions, but critically lack parameter descriptions, output schemas are undocumented, and error handling is minimal. The list_products tool accepts no parameters but returns unspecified structured data. The get_product tool has an integer parameter with a description but no output schema documentation. Error handling is present (e.g., 'Product not found') but does not guide recovery. No pagination is implemented despite list_products potentially returning many results. The codebase shows direct use of in-memory `products_db` rather than proper database queries (though database.py and models.py exist, they are not integrated into mcp_server.py). Overall, this is a functional but incomplete tool definition that lacks several production-grade patterns.
Retrieve details of a specific product by its ID.
List all available products with their ID, name, price, and description.
Output schemas are not documented. Neither tool specifies what fields are returned or the structure of the response. LLMs cannot plan downstream tool calls or extract data without knowing the response shape.
list_products has no pagination (limit/offset parameters) and no documented result limits. Returning all products in memory could blow the context window if the catalog grows large. Best practice is to cap results at 20-50 and accept limit/offset.
get_product error handling is minimal. It returns {"error": "Product not found"} with no guidance on what the LLM should do next (e.g., 'Try list_products() to see available product IDs'). Error responses must guide recovery.
list_products description is 73 characters, acceptable but generic. It does not explain when to use this tool vs get_product, whether it returns a paginated list, or how many results to expect.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | F | 6 | 2026-07-28+ | v2 |
| 2026-03-09 | F | 41 | - | v1 |
The server uses an in-memory products_db list directly in mcp_server.py, but database.py defines a PostgreSQL connection. The MCP tools do not actually query the database, they operate on a Python list initialized elsewhere. This is architecturally inconsistent and will not work in a production environment where data must persist.