Skip to main content
Glama
mantle-bearer

fastapi-mcp-server

discover_fastapi_project

Scan a project directory to identify FastAPI apps, APIRouters, and Pydantic models, returning a structured catalog with import target strings.

Instructions

Automatically scan a project directory to discover all FastAPI apps, APIRouters, and Pydantic models.

Args: project_dir: Optional path to the project root directory. Defaults to current working directory.

Returns: A structured catalog listing all discovered apps, routers, and models with import target strings.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_dirNo
Behavior4/5

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

With no annotations present, the description carries the full transparency burden. It clearly states that the tool automatically scans a directory and returns a structured catalog with import target strings, which goes beyond the minimal schema. It does not mention potential performance costs or failure modes, but the core behavior is adequately disclosed.

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 compact and well-structured with Summary, Args, and Returns sections. Each sentence adds meaningful information without redundancy or filler.

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

Completeness4/5

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

Given the tool's complexity, the lack of an output schema, and the absence of annotations, the description provides a solid high-level contract: input path, default behavior, and returned content. It stops short of giving the exact catalog structure, but it is sufficient for an agent to decide whether and how to invoke the tool.

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

Parameters5/5

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

The schema only defines project_dir as an optional string or null, but the description adds full semantic meaning: it is a path to the project root and defaults to the current working directory. This fully compensates for the 0% schema description coverage.

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

Purpose5/5

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

The description uses specific verbs and resources: 'scan a project directory to discover all FastAPI apps, APIRouters, and Pydantic models.' This clearly separates it from siblings like get_openapi_schema or list_registered_routes, which operate on schemas or routes rather than discovering the project's structural components.

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

Usage Guidelines3/5

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

The intended use is implied by the description: call this when you need a project-wide catalog of FastAPI apps, routers, and models. However, it does not explicitly state when to prefer this over sibling tools, nor does it mention any exclusions or prerequisite conditions.

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

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/mantle-bearer/fastapi-mcp-server'

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