Skip to main content
Glama

List databases

databases
Read-onlyIdempotent

List every DB on a connection's server and show which is current, so you can select one when none is set or switch for later calls.

Instructions

List the databases on a connection's server and which one is current. Use it when a connection has no database selected, or to work in another database (pass database to later calls); to list tables inside a database use tables instead. Returns current, databases[N] (user databases first) and system[N]. SQLite returns an empty list (one file = one database). On failure returns isError with 'error: ' (e.g. refused statement, unknown table, SQL error).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
connectionYesConnection name exactly as returned by `connections` (e.g. "shop"). Unknown or unexposed names return an error.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.2.2
    • changedInput schema / properties / connection / description
      Previous value: -"Connection name (from `connections`)"New value: +"Connection name exactly as returned by `connections` (e.g. \"shop\"). Unknown or unexposed names return an error."
  2. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), yet the description still adds real behavioral detail: the return shape (current, databases[N] user-first, system[N]), the SQLite edge case returning an empty list, and the failure contract (isError with 'error: <reason>'). That is exactly the beyond-annotations context the agent needs.

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?

Four tight sentences, front-loaded with purpose, then routing, then return shape, then error contract. Every sentence carries information an agent needs; no padding or restatement of the title.

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

Completeness5/5

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

No output schema exists, but the description supplies the return structure and error behavior itself, so an agent knows what it will get back and how failure surfaces. Combined with the explicit sibling routing, nothing material is missing for a one-parameter read tool.

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 coverage is 100% and the sole `connection` parameter is fully documented in the schema, so the baseline is 3. The description does add a downstream usage hint ('pass `database` to later calls'), but that concerns how to use the results rather than clarifying the parameter itself.

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?

Specific verb + resource ('List the databases on a connection's server') plus the extra dimension of which one is current. It explicitly separates itself from the sibling `tables` by naming what that sibling does instead, so an agent can route correctly without opening either schema.

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

Usage Guidelines5/5

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

Gives explicit trigger conditions ('when a connection has no database selected, or to work in another database') and names the alternative tool (`tables`) with the condition that selects it. Nothing is left to inference.

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