Skip to main content
Glama

Test Error Handling

test_error_handling
Read-onlyIdempotent

Throws a chosen error type to verify the MCP server formats and returns errors correctly.

Instructions

Throws a specific type of error to verify the server formats and returns them correctly over MCP.

Input Schema

NameRequiredDescriptionDefault
messageNoTest error message
error_typeNo
use_test_dbNo

Output Schema

NameRequiredDescriptionDefault
codeNoError code (e.g. VALIDATION_ERROR, INTERNAL_ERROR)
errorNoHuman-readable error message
detailsNoAdditional error context
categoryNoError category (validation, query, connection, internal)
suggestionNoSuggested fix for the error
recoverableNoWhether the error is recoverable
aggregated_errorsNoDetails of individual errors in a multi-step operation

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv9.0.0

TDQS

B3.3/5.0
Behavior3/5

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

Annotations already declare `readOnlyHint: true`, `idempotentHint: true`, and `destructiveHint: false`, so the description does not need to restate safety. It adds that the tool intentionally throws an error for verification, but does not disclose whether the call always fails, what side effects `use_test_db` may have, or how the error is surfaced to the caller.

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 a single, front-loaded sentence with no redundant text. It immediately states the tool's purpose and verification context.

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

Completeness3/5

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

An output schema exists, so return formatting need not be explained, and annotations cover safety. However, with 0% schema description coverage across 3 params, the description should provide more guidance on parameter use, especially the `error_type` enum and `use_test_db` flag.

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 0% for all 3 parameters. The description mentions a 'specific type of error' but does not explain the `error_type` enum values, the `message` parameter's role, or what `use_test_db` changes.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific action (throwing an error) and purpose (verifying server error formatting over MCP), so an agent can understand what the tool does. However, it does not distinguish this tool from the sibling `test_simple`, which likely serves a related testing role.

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

Usage Guidelines3/5

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

Usage is implied as a testing/diagnostic tool, but the description gives no explicit when-to-use, when-not-to-use, or alternative guidance. It does not warn against using it in production or explain how to choose among error types.

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

Deploy Server

Other Tools