Skip to main content
Glama
fabdendev

dagster-mcp

by fabdendev

Get Run Logs

get_run_logs

Fetch structured log events for a Dagster run to investigate failures and step activity. Filter by severity level and paginate through the full event stream.

Instructions

Get structured log events for a run, with optional severity filtering and pagination.

Returns events with __typename, timestamp, message, level, and (where applicable) stepKey and error details. Events include step starts/completions, failures, retries, materializations, and run-level events. EngineEvent events also carry metadataEntries — a list of {label, description, value} dicts (e.g. run worker image, k8s pod name, step keys) surfaced by the engine.

Parameters:

  • run_id: the run to fetch logs for

  • level_filter: only return events at this level or above, ordered DEBUG < INFO < WARNING < ERROR < CRITICAL. Filtering at 'WARNING' therefore also returns ERROR and CRITICAL events. ExecutionStepFailureEvent and RunFailureEvent are always included when filtering at 'ERROR' or below, regardless of their own level field. Default: None (return all events).

  • cursor: pagination cursor returned in previous response. Pass the cursor from the last call to get the next page.

  • limit: max events per page (default 100)

When to use: to investigate what happened during a run. For a quick failure diagnosis, prefer get_run_failure_summary instead — it returns a consolidated view in a single call. Use get_run_logs when you need the full event stream or want to filter by level.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
envNo
limitNo
cursorNo
run_idYes
level_filterNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.8.0

TDQS

A4.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and largely meets it: it enumerates the returned fields (__typename, timestamp, message, level, stepKey, error details) and event categories, and discloses two non-obvious behaviors — the level_filter ordering semantics and that ExecutionStepFailureEvent/RunFailureEvent are always included at ERROR or below regardless of their level. It never explicitly states that the operation is read-only or what happens on a missing/invalid run_id, which is the remaining gap given zero annotation coverage.

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 one-line capability statement, then return contents, then a labeled parameter list, then a labeled 'When to use' block. No sentence is redundant and the structured layout makes the tool skimmable despite its length.

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?

For a read-only log-retrieval tool with no annotations, the description supplies return contents, filtering semantics, pagination mechanics, and sibling routing. The output schema exists, so the return-value detail is bonus rather than a requirement, and nothing an agent needs to call this correctly is missing apart from the minor env omission.

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 0%, so the description has to compensate, and it does for 4 of the 5 parameters — level_filter gets a thorough semantic explanation (ordering, threshold behavior, always-included failure events, default) and cursor/limit/run_id are all clarified. The env parameter is never mentioned in either the schema or the description, so one parameter remains completely opaque.

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 ('Get structured log events for a run') plus the return shape, and explicitly distinguishes itself from the nearest sibling, get_run_failure_summary. An agent can separate this tool from the other 16 siblings without opening any schema.

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?

Contains an explicit 'When to use' section that names the alternative (get_run_failure_summary) and the exact condition that selects it ('quick failure diagnosis'), then states when this tool is preferred ('full event stream or want to filter by level'). Both directions of the routing decision are covered.

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