Skip to main content
Glama

doctor

Run six health checks on a BackGen project covering runtime, configuration, database, dependencies, file integrity, and ownership. Uses --fix to auto-resolve missing manifest entries and ownership issues.

Instructions

Runs 6 health check categories against a BackGen-generated project and returns a structured pass/fail report for each one. (1) Runtime — Node version >= 18, npm availability. (2) Configuration — .env exists, DATABASE_URL is set, all required env vars from installed plugins are present. (3) Database — Prisma schema / Drizzle config / Mongoose connection string is reachable. (4) Dependencies — package.json deps match installed node_modules, no missing peer deps. (5) File integrity — every file tracked in .backgenrc.json exists on disk with the correct ownership classification (framework vs user). (6) Ownership — all files are properly classified as framework/shared/user, no orphaned plugins. Run this tool BEFORE telling the user that a project is ready to use. Use --fix to auto-resolve missing manifest entries and file ownership issues.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fixNoAuto-fix issues where possible. When true, doctor will regenerate missing manifest entries, fix ownership classifications, and restore tracked files that are missing from disk. Safe to enable — never touches user-owned files (only framework and shared files).
dirNoAbsolute or relative path to the BackGen-generated project to diagnose. Defaults to the current working directory. Example: '/home/user/projects/my-api'.
Behavior4/5

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

No annotations are provided, so the description carries full burden. It discloses that the tool is non-destructive to user-owned files, stating 'never touches user-owned files — only framework and shared files.' It also explains what --fix does. This is good transparency, though it could mention if any side effects exist beyond the listed fixes.

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

Conciseness4/5

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

The description is moderately long but well-organized with a numbered list of the 6 checks. The first sentence provides a summary. It is front-loaded and each sentence adds information, though a few minor redundancies exist (e.g., repeated mention of 'ownership').

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 (6 categories) and no output schema, the description covers the input parameters, the checks performed, and the --fix behavior. It does not detail the output format beyond 'structured pass/fail report', which is a minor gap. Overall, it provides sufficient context for an AI agent to use the tool correctly.

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

Parameters4/5

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

Schema coverage is 100%, and the description adds value beyond the schema. For the 'fix' parameter, it clarifies safety ('Safe to enable — never touches user-owned files'). For 'dir', it provides an example path. This helps the agent understand parameter semantics beyond the basic descriptions.

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 explicitly states the tool runs 6 health check categories and returns a structured pass/fail report. It lists each category in detail, making the purpose crystal clear. The tool's name 'doctor' is vague, but the description provides a specific verb and resource, and it is clearly distinguished from sibling tools like 'init_project' or 'generate_resource'.

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

Usage Guidelines4/5

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

The description advises to run this tool before telling the user a project is ready, providing clear context on when to use it. It also mentions the --fix flag for auto-resolving issues. However, it does not explicitly state when not to use it or mention any alternatives, though the sibling tools are unrelated.

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/IbrahimKhaled19/BackGen'

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