Skip to main content
Glama

run_pipeline

Destructive

Chain approved security tools by piping each step's stdout into the next, replacing unsafe shell pipes with validated, bounded execution.

Instructions

Execute a pipeline of tools, piping stdout from each step into stdin of the next.

Replaces shell piping (e.g. strings binary | grep flag) with a safe, no-shell alternative. Each step is validated individually (allowlist, argument sanitization, policy checks) before any process starts.

Each step's stdout and stderr are bounded to 200KB as they are read, and an intermediate step's bounded stdout is what gets piped into the next step. If any step hits that cap, the returned truncated flag is set and the final stdout carries a truncation marker.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
hostNoReserved for future use. Currently only local execution is supported.
stepsYesList of dicts, each with 'tool' (required) and 'args' (optional) keys. Max 10 steps per pipeline.
timeoutNoGlobal timeout for entire pipeline in seconds (default 120, max 300).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true, openWorldHint=true and readOnlyHint=false, but the description still adds real value: per-step validation before any process starts, a 200KB per-step stdout/stderr cap, a truncation marker, and the returned `truncated` flag. It omits what happens to earlier steps if a later step fails, which matters for a destructive pipeline, so it is strong but not exhaustive.

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 core action, followed by the motivating example, then the safety/bounding guarantees. Every sentence carries concrete information (validation order, 200KB cap, truncation marker) with no filler.

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?

An output schema exists, so return values need not be re-described, and the description covers the semantics an agent needs: step structure, validation, bounding, and truncation signaling. The main residual gap is failure/partial-execution behavior across steps in a destructive multi-step run.

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?

Schema description coverage is 100%, so the schema itself documents `host` (reserved), the step-list shape with the max-10 constraint, and the timeout default/max. The description adds no further parameter-level syntax or semantics, so the baseline 3 applies.

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?

States a specific verb and resource ('Execute a pipeline of tools') plus the precise mechanism (stdout piped to stdin of the next step), which implicitly separates it from the single-invocation siblings run_tool and run_script. It does not explicitly name those alternatives, so an agent still has to infer the routing, keeping it short of a 5.

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

Usage Guidelines4/5

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

Gives clear context for when to reach for it: replacing shell piping such as `strings binary | grep flag` with a safe, no-shell alternative. That is a concrete usage trigger, though it stops short of explicitly contrasting with run_tool/run_script or stating when not to use a pipeline.

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