Skip to main content
Glama

get_request_trace

Read-onlyIdempotent

Everything about ONE request in a single call: its own status/latency/payload, plus every Function invocation it triggered, in order, with each one's status, error text, and captured print() output. This is the tool for 'a request failed, was it my code' — pass the requestId you already have (from a client error, a support ticket, or list_logs) and get the whole story back at once.

request is the client's own top-level request. When a Function calls the project's API during it, those internal calls share the requestId and are listed in subRequests (oldest first, each with internal: true and parentRequestId), never as request.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "request_id": "<request_id>"
    },
    "name": "get_request_trace"
  }
}

Input Schema

NameRequiredDescriptionDefault
project_idNoOptional if whoami returned a default_project_id.
request_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive), so the description focuses on response structure: subRequests are ordered oldest-first, tagged internal:true and parentRequestId, and never appear as `request`. That is genuinely useful behavioral context with no output schema to rely on, though it stops short of covering not-found behavior or payload size limits.

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?

Front-loaded with the outcome and payload contents, then the triggering scenario, then the request/subRequest distinction. Every sentence adds distinct information; nothing is repeated from the schema or annotations.

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 two-parameter read tool with no output schema, the description gives enough about the returned shape to call it confidently. Minor gaps remain: no mention of empty/not-found results or how far back traces are retained.

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 coverage is only 50%, with request_id undocumented in the schema, but the description compensates by explaining what the id identifies (the client's top-level request) and distinguishing it from ids of internal sub-requests that share the same value. project_id is left entirely to the schema, which already marks it optional when whoami supplies a default.

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?

States a specific verb and resource ('everything about ONE request in a single call') and enumerates the payload precisely: status/latency, function invocations in order, error text, print() output. It is clearly distinguishable from the bulk-oriented siblings like list_logs, which it names as an upstream source of the id.

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?

Explicitly frames the situation ('a request failed, was it my code') and tells the agent exactly what to pass and where to obtain it (client error, support ticket, list_logs). No alternative tool competes for this job, so the routing guidance is complete.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources