Skip to main content
Glama

Get pipeline step logs

get_pipeline_step_logs
Read-only

Why did an Ankra Pipelines step fail? Reads a pipeline run and one step's archived log tail. Address the run by execution_id (each agent-run pipeline step is its own execution in list_recent_executions), run_id (a UUID), or owner and repo: run_number (run #3630), else the newest run narrowed by branch, pull_request or head_sha (recent_runs lists ten). Find a pull request's run by pull_request, not branch (refs/pull/622/merge reads as pull_request 622). The step read is step (key or display name), else the execution's, else the first failing one. Returns the run (repository, ref, sha, outcome, cluster), each step's outcome and exit code, and log.state: available (text = last max_lines lines), not_archived, or unavailable (unknown, not empty). Read-only; needs pipelines.read. Ankra Pipelines runs are not GitHub Actions runs.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_pipeline_step_logs"
  }
}

Input Schema

NameRequiredDescriptionDefault
repoNoRepository name, with owner.
stepNoStep key or display name whose log to read. Defaults to the execution's step, else the run's first failing step.
ownerNoRepository owner, with repo; repo may also be owner/name.
branchNoWith owner/repo: only runs of this branch (a pull request run's is its base).
run_idNoA run's UUID (a run number is read as run_number).
head_shaNoWith owner/repo: only runs of this full commit SHA.
providerNoSource control provider of owner/repo: github, gitlab, or bitbucket_cloud. Defaults to github.
max_linesNoTrailing log lines to return, 1-400; default 150.
run_numberNoWith owner/repo: the number shown as run #3630.
execution_idNoAn execution id from list_recent_executions or get_execution_details.
pull_requestNoWith owner/repo: only this pull request's runs.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • changedInput schema / properties / branch / description
      Previous value: -"With owner/repo: only runs of this branch."New value: +"With owner/repo: only runs of this branch (a pull request run's is its base)."
    • addedInput schema / properties / head_sha
      Added value: +{
      +  "description": "With owner/repo: only runs of this full commit SHA.",
      +  "type": "string"
      +}
    • addedInput schema / properties / pull_request
      Added value: +{
      +  "description": "With owner/repo: only this pull request's runs.",
      +  "type": "integer"
      +}
    • changedInput schema / properties / run_id / description
      Previous value: -"A pipeline run id."New value: +"A run's UUID (a run number is read as run_number)."
    • addedInput schema / properties / run_number
      Added value: +{
      +  "description": "With owner/repo: the number shown as run #3630.",
      +  "type": "integer"
      +}
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only say readOnlyHint=true; the description goes well beyond that by naming the required permission (pipelines.read), describing the defaulting chain for which step is read, and disclosing the log.state tri-state (available/not_archived/unavailable) including the warning that 'unavailable' means unknown rather than empty. That last point is a genuinely load-bearing behavioral caveat an agent would otherwise misread.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the diagnostic question, then addressing modes, then step selection, then return shape — a sensible order for a tool with 11 parameters. It is dense and long, with a few clauses (e.g. the run_id UUID restatement) that duplicate schema text, but no sentence is filler.

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?

With 11 optional parameters, no output schema, and no enums, the description carries the full burden and does: it explains the returned fields (repository, ref, sha, outcome, cluster, per-step outcome and exit code) and the exact meaning of max_lines. An agent has everything needed to call it correctly and interpret the result.

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 100%, so baseline would be 3, but the description adds real semantics the schema does not: that each agent-run pipeline step is its own execution in list_recent_executions, that run_id is a UUID versus run_number being the '#3630' form, and the precedence between pull_request and branch. Some of this overlaps the schema's own parameter descriptions, which keeps it from a 5.

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?

Opens with a concrete question it answers and a specific verb+resource: reads a pipeline run plus one step's archived log tail. It explicitly disambiguates from the nearest sibling class with 'Ankra Pipelines runs are not GitHub Actions runs', so an agent can separate it from github_get_job_logs without opening either 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?

Enumerates the three ways to address a run (execution_id, run_id, or owner+repo:run_number) and states the fallback when none is given, plus the precedence rules for narrowing by branch/pull_request/head_sha. It also names the companion tools (list_recent_executions, recent_runs) that supply the identifiers and gives an explicit exclusion: find a pull request's run by pull_request, not branch.

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.