Skip to main content
Glama
onemarc

GitHub Actions MCP Server

by onemarc

get_workflow

Retrieve detailed information about a specific GitHub Actions workflow by providing the repository owner, repository name, and workflow ID or filename.

Instructions

Get details of a specific workflow

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ownerYesRepository owner
repoYesRepository name
workflowIdYesThe ID of the workflow or filename

Implementation Reference

  • The handler function for the 'get_workflow' tool, which retrieves workflow details using the Octokit API.
    const handleGetWorkflow: ToolHandler = async (args, octokit: Octokit) => {
      const { owner, repo, workflowId } = args;
      
      try {
        const response = await octokit.rest.actions.getWorkflow({
          owner,
          repo,
          workflow_id: workflowId
        });
    
        return response.data;
      } catch (error: any) {
        throw new WorkflowError(`Failed to get workflow: ${error.message}`, error.response?.data);
      }
    };
    
    export default handleGetWorkflow;
  • The input schema and definition for the 'get_workflow' tool.
    {
      name: "get_workflow",
      description: "Get details of a specific workflow",
      inputSchema: {
        type: "object",
        properties: {
          owner: { type: "string", description: "Repository owner" },
          repo: { type: "string", description: "Repository name" },
          workflowId: { 
            oneOf: [
              { type: "string" },
              { type: "number" }
            ],
            description: "The ID of the workflow or filename"
          }
        },
        required: ["owner", "repo", "workflowId"]
      }
    },
  • Registration of the 'get_workflow' handler in the toolHandlers map.
    export const toolHandlers: Record<string, ToolHandler> = {
      create_workflow: handleCreateWorkflow,
      list_workflows: handleListWorkflows,
      get_workflow: handleGetWorkflow,
      get_workflow_usage: handleGetWorkflowUsage,
      list_workflow_runs: handleListWorkflowRuns,
      get_workflow_run: handleGetWorkflowRun,
      get_workflow_run_jobs: handleGetWorkflowRunJobs,
      trigger_workflow: handleTriggerWorkflow,
      cancel_workflow_run: handleCancelWorkflowRun,
      rerun_workflow: handleRerunWorkflow,
    };
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states this is a read operation ('Get details'), implying it's non-destructive, but doesn't mention authentication requirements, rate limits, error conditions, or what 'details' include (e.g., YAML content, status, timestamps). This leaves significant gaps for safe and effective use.

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 a single, direct sentence that efficiently conveys the core purpose without unnecessary words. It's front-loaded with the key action and resource, making it easy to parse quickly, which is ideal for tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity of workflows in GitHub (with siblings for runs, lists, etc.), no annotations, and no output schema, the description is insufficient. It doesn't clarify what 'details' are returned (e.g., YAML, status), how this differs from run-related tools, or prerequisites like authentication, leaving the agent under-informed for reliable use.

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%, with clear parameter descriptions in the schema (e.g., 'Repository owner', 'Repository name', 'The ID of the workflow or filename'). The description adds no additional meaning beyond the schema, such as explaining how 'workflowId' relates to filenames or providing examples. This meets the baseline for high schema coverage.

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?

The description clearly states the action ('Get details') and resource ('a specific workflow'), making the purpose immediately understandable. However, it doesn't differentiate this tool from similar siblings like 'get_workflow_run' or 'list_workflows', which would require specifying that this retrieves metadata about the workflow definition itself rather than runs or a list.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. With siblings like 'get_workflow_run' (for run details) and 'list_workflows' (for multiple workflows), the agent must infer usage from the name alone, which could lead to incorrect tool selection in complex scenarios.

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

Related 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/onemarc/github-actions-mcp-server'

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