Skip to main content
Glama

db_setup_scan

Discover an instance's DB credentials from app config read-only over SSH and return redacted previews plus a staging token, so database tools can be set up without manual configuration.

Instructions

Discover an instance's DB credentials (from .env / DATABASE_URL / wp-config.php / docker env) to set up the db tools with no manual config. Reads the app config READ-ONLY over SSH on the box. Returns REDACTED previews + a staging token per candidate; the password is held server-side and never returned, so it can't leak into your context. Then call db_setup_save with the chosen token. Read-only.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourceNoWhere to scan: 'auto'/'ssh' read the box (default), 'local' reads search_path locally.auto
instance_idYesInstance ID or name. '<account>/<name>' picks the server of one provider account; custom servers are 'custom/<name>'.
search_pathNoOptional dir on the box to search (or a local .env path). Empty = scan common web roots.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.28.0
    • changedInput schema / properties / instance_id / description
      Previous value: -"Instance ID, name, or custom-server name."New value: +"Instance ID or name. '<account>/<name>' picks the server of one provider account; custom servers are 'custom/<name>'."
  2. First observedv1.0.0

TDQS

A4.3/5.0
Behavior5/5

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

No annotations are provided, so the description carries the full burden — and it delivers: read-only reads over SSH, redacted previews with a staging token, and the password held server-side and never returned to context. This discloses the security/auth model an agent needs before invoking a credential-discovery tool.

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?

Front-loaded with the core action and efficient overall, but 'read-only' is stated twice ('READS the app config READ-ONLY' and the trailing 'Read-only.'), which is mild redundancy.

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?

With no annotations and no output schema, the description compensates by describing what is returned (redacted previews + staging token) and the security model. It is largely self-sufficient, though return-value detail could be marginally richer.

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

Parameters3/5

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

Schema description coverage is 100%, so all three parameters are already documented in the schema, which sets the baseline at 3. The description's mention of sources and web roots roughly mirrors the source/search_path params without adding format or syntax detail beyond the schema.

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?

States a specific verb and resource ('Discover an instance's DB credentials') plus the credential sources (.env / DATABASE_URL / wp-config.php / docker env), and routes to the sibling db_setup_save. An agent can distinguish it from setup-adjacent siblings without opening the schema.

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?

Gives clear workflow context ('to set up the db tools with no manual config') and an explicit next step ('Then call db_setup_save with the chosen token'). It does not state when NOT to use it or contrast against db_setup_remove, so it falls short of the full when/when-not/alternatives bar.

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