Skip to main content
Glama
Teja-sudo

postgres-mcp-server

by Teja-sudo

detect_migration_state

Probe databases for migration tool tracker tables to identify managed migrations, returning detected tools, schema, table, count, and latest version.

Instructions

Probe the database for migration tool tracker tables (Liquibase, Flyway, Alembic, Prisma, Knex, Sequelize, Django, Rails, Goose, TypeORM). Returns which tools are detected, the schema and table holding their state, the count of applied migrations, and the latest version. AI agents use this to immediately understand whether the DB is managed by a migration tool before suggesting changes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
schemasNoSchemas to probe. Default: all non-system schemas.
serverNo
databaseNo
schemaNo
Behavior3/5

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

The description indicates a read-only probe ('probe', 'returns'), but without annotations, it does not explicitly state that the tool has no side effects, requires no special permissions, or has any performance impact. The description is adequate but not fully transparent.

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 concise, with two sentences conveying the core functionality and usage context. No redundant information is present, though it could be slightly more streamlined.

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?

The description explains the return values (detected tools, schema/table, count, latest version) reasonably well, compensating for the lack of an output schema. Given the tool's complexity and no output schema, the description provides enough context for an AI agent to understand what to expect.

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

Parameters2/5

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

Schema description coverage is only 25%, with only the 'schemas' parameter documented in the schema. The tool description adds value for 'schemas' (default: all non-system) but provides no additional meaning for 'server', 'database', and 'schema' parameters. With low coverage, the description should compensate more.

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 clearly states the tool probes for migration tool tracker tables and returns specific details (tools detected, schema/table, count, latest version). It also explicitly explains the AI agent use case, distinguishing it from sibling tools that analyze database health or indexes.

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 implies usage before suggesting changes, providing clear context for when to use. However, it lacks explicit exclusions or alternatives, such as when not to use it or what to use instead if migration state is not needed.

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/Teja-sudo/postgres-mcp-server'

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