Skip to main content
Glama
Allentgt

dynamodb-mcp-server

by Allentgt

query_table

Read-onlyIdempotent

Query a DynamoDB table using key conditions to find matching items by primary key or index keys, returning sorted results with pagination support.

Instructions

Query a DynamoDB table using key conditions to find matching items.

Queries are efficient because they use the table's primary key or GSI/LSI keys. Results are returned sorted by sort key. Optional filter expressions can further refine results (but don't reduce read capacity consumed).

When to use:

  • To find items by primary key (partition key + optional sort key condition)

  • To find items using a GSI or LSI

  • When you know the partition key value

When NOT to use:

  • When you don't know the partition key (use scan_table instead)

  • For full-table searches (use scan_table with filter)

Returns: Items matching the query with count, scanned_count, and pagination key. Format controlled by 'format' parameter (json or markdown).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
inputYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Beyond the annotations (readOnlyHint, idempotentHint, destructiveHint), the description discloses valuable behavioral traits: results are 'returned sorted by sort key,' filter expressions 'don't reduce read capacity consumed,' and the return includes 'count, scanned_count, and pagination key.' These details are not present in the annotations and help the agent anticipate behavior and side effects.

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?

The description is well-organized with clear sections for purpose, efficiency, usage, and return values. It is concise—each sentence delivers useful information, and the use of bullet points improves scannability without unnecessary verbosity.

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?

For a tool with a complex input schema (wrapped single parameter object containing multiple fields) and rich annotations, the description covers key aspects: when to use, when not to use, sorted results, filter cost, and return payload. It does not elaborate on expression syntax or pagination mechanics, but the schema descriptions and output schema already cover those details, making the description sufficiently complete for agent selection and initial invocation.

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?

The description adds minimal parameter context beyond the schema; it only mentions that the 'format' parameter controls output and gives a high-level example of key conditions. The input schema itself provides rich, detailed descriptions for every parameter (e.g., key_condition_expression, filter_expression, index_name), so the description does not need to compensate, but it also does not add significant new meaning beyond the schema's own documentation.

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's function: 'Query a DynamoDB table using key conditions to find matching items.' It explicitly identifies the resource (DynamoDB table), the action (query), and the mechanism (key conditions), and further distinguishes it from scan_table in the 'When NOT to use' section by naming the alternative.

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?

The description includes dedicated 'When to use' and 'When NOT to use' sections with concrete scenarios, and explicitly points to scan_table as the alternative for full-table searches or when the partition key is unknown. This is clear guidance on selection versus sibling tools.

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/Allentgt/dynamodb-mcp-server'

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