Skip to main content
Glama
clidey

whodb-cli

Official

whodb_tables

Read-onlyIdempotent

List all tables in a database schema with metadata like row counts. Optionally include column details to understand table structure in one call.

Instructions

List all tables in a database schema.

Best for: Discovering what tables exist in a schema; getting table metadata like row counts. Not recommended for: When you already know the table name (proceed directly to whodb_columns or whodb_query). Common mistakes: Not specifying schema when the database has multiple schemas with same-named tables.

Usage Example:

{
  "name": "whodb_tables",
  "arguments": {
    "connection": "mydb",
    "schema": "public"
  }
}

Returns: Array of table objects with name and attributes (row count, size, etc.). Note: If schema is omitted, uses the connection's default schema or the first available schema.

Optional parameter: Set "include_columns": true to also return column details (name, type, primary key, foreign keys) for each table. This saves you separate whodb_columns calls and gives you everything needed to write queries in a single round-trip.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
connectionYesConnection name (optional if only one exists)
schemaNoSchema name (uses default if omitted)
include_columnsNoSet true to also return column details for each table in a single call

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
tablesYes
schemaYes
errorNo
request_idNo
Behavior5/5

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

Description adds behavior details beyond annotations: default schema handling, return format (array of table objects with row count, size), and the optional include_columns parameter effect. No contradictions with readOnlyHint and idempotentHint.

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?

Well-structured with clear sections, usage example, and front-loaded purpose. Every sentence adds value without redundancy.

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?

Given the tool has 3 parameters and an output schema, the description covers purpose, usage, parameters, behavior, return format, and example comprehensively.

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?

Schema coverage is 100%, and description adds meaningful context for each parameter: include_columns saves separate whodb_columns calls, schema uses default if omitted, connection is optional if only one exists.

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?

Description clearly states 'List all tables in a database schema' with specific verb and resource. Distinguishes from siblings like whodb_columns and whodb_query by stating when to use which.

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?

Provides explicit best-for, not-recommended-for, and common mistakes sections, naming alternatives and guiding the agent's decision.

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/clidey/whodb'

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