Skip to main content
Glama
avivsinai

langfuse-mcp

get_exception_details

Retrieve detailed exception information from Langfuse traces or spans to debug LLM application errors. Specify output format for summarized or complete data.

Instructions

Get detailed exception info for a trace/span.

Args:
    ctx: Context object containing lifespan context with Langfuse client
    trace_id: The ID of the trace to analyze for exceptions (unique identifier string)
    span_id: Optional span ID to filter by specific span (unique identifier string)
    output_mode: Controls the output format and detail level

Returns:
    Based on output_mode:
    - compact: List of summarized exception details
    - full_json_string: String containing the full JSON response
    - full_json_file: List of summarized exception details with file save info

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
trace_idYesThe ID of the trace to analyze for exceptions (unique identifier string)
span_idNoOptional span ID to filter by specific span (unique identifier string)
output_modeNoControls the output format and action. 'compact' (default): Returns a summarized JSON object optimized for direct agent consumption. 'full_json_string': Returns the complete, raw JSON data serialized as a string. 'full_json_file': Returns a summarized JSON object AND saves the complete data to a file.compact

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses key behavioral traits: it's a read operation (implied by 'Get'), it requires a trace ID, supports optional filtering by span ID, and offers three output modes with detailed explanations of each. However, it doesn't mention rate limits, authentication needs, or error handling.

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-structured and front-loaded with the core purpose, followed by organized sections for Args and Returns. Every sentence adds value, with no redundant or vague phrasing, making it efficient for an agent to parse.

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's moderate complexity (3 parameters, 1 required), 100% schema coverage, and the presence of an output schema (implied by the Returns section), the description is complete. It covers purpose, parameters, and return behaviors adequately without needing to explain basic output values.

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

Parameters4/5

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

Schema description coverage is 100%, so the schema already documents all parameters. The description adds value by explaining the 'ctx' parameter (not in the schema) and providing clear semantics for 'output_mode' with specific return formats for each enum value, going beyond the schema's technical descriptions.

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 purpose with a specific verb ('Get detailed exception info') and resource ('for a trace/span'), distinguishing it from sibling tools like 'find_exceptions' or 'get_error_count' which likely have different scopes or return formats.

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?

The description implies usage by specifying it's for analyzing exceptions in traces/spans, but it doesn't explicitly state when to use this tool versus alternatives like 'find_exceptions' or 'get_error_count'. No exclusions or prerequisites are mentioned.

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/avivsinai/landfuse-mcp'

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