Skip to main content
Glama
CircleCI-Public

mcp-server-circleci

Official

find_flaky_tests

Retrieve information about flaky tests in CircleCI projects to analyze test reliability and implement targeted fixes.

Instructions

This tool retrieves information about flaky tests in a CircleCI project. 

The agent receiving this output MUST analyze the flaky test data and implement appropriate fixes based on the specific issues identified.

CRITICAL REQUIREMENTS:
1. Truncation Handling (HIGHEST PRIORITY):
   - ALWAYS check for <MCPTruncationWarning> in the output
   - When present, you MUST start your response with:
     "WARNING: The logs have been truncated. Only showing the most recent entries. Earlier build failures may not be visible."
   - Only proceed with log analysis after acknowledging the truncation

Input options (EXACTLY ONE of these THREE options must be used):

Option 1 - Project Slug:
- projectSlug: The project slug obtained from listFollowedProjects tool (e.g., "gh/organization/project")

Option 2 - Direct URL (provide ONE of these):
- projectURL: The URL of the CircleCI project in any of these formats:
  * Project URL: https://app.circleci.com/pipelines/gh/organization/project
  * Pipeline URL: https://app.circleci.com/pipelines/gh/organization/project/123
  * Workflow URL: https://app.circleci.com/pipelines/gh/organization/project/123/workflows/abc-def
  * Job URL: https://app.circleci.com/pipelines/gh/organization/project/123/workflows/abc-def/jobs/xyz

Option 3 - Project Detection (ALL of these must be provided together):
- workspaceRoot: The absolute path to the workspace root
- gitRemoteURL: The URL of the git remote repository

Additional Requirements:
- Never call this tool with incomplete parameters
- If using Option 1, make sure to extract the projectSlug exactly as provided by listFollowedProjects
- If using Option 2, the URLs MUST be provided by the user - do not attempt to construct or guess URLs
- If using Option 3, BOTH parameters (workspaceRoot, gitRemoteURL) must be provided
- If none of the options can be fully satisfied, ask the user for the missing information before making the tool call

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsNo
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes several behavioral traits: the tool's output may be truncated (with specific handling instructions), it requires exactly one of three parameter sets, and it has strict validation requirements for each parameter option. However, it doesn't mention authentication needs, rate limits, or what happens when flaky tests are found (beyond stating the agent should 'implement appropriate fixes').

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

Conciseness3/5

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

The description is appropriately front-loaded with the core purpose, but contains significant redundancy and instructional content that extends beyond tool description. The 'CRITICAL REQUIREMENTS' section includes agent instructions about output handling that belong in a different context. While well-structured with clear sections, it's verbose (over 400 words) with some sentences that don't directly describe the tool's behavior or parameters.

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?

Given the complexity (multiple parameter patterns, no annotations, no output schema), the description provides substantial context about parameter usage, validation rules, and output handling. It adequately covers the tool's operational context despite the lack of structured metadata. However, it doesn't explain what format the flaky test information returns in or what specific data fields are available, which would be helpful given the absence of an output schema.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage (the schema provides only basic parameter names without meaningful descriptions), the description comprehensively compensates by explaining all four parameters in detail. It clarifies the three mutually exclusive usage patterns, provides specific format examples for each parameter, explains relationships between parameters (e.g., Option 3 requires BOTH workspaceRoot and gitRemoteURL), and gives practical guidance on parameter sourcing and validation.

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 tool 'retrieves information about flaky tests in a CircleCI project', providing a specific verb ('retrieves') and resource ('flaky tests'). It distinguishes from sibling tools like 'get_job_test_results' or 'get_build_failure_logs' by focusing specifically on flaky tests rather than general test results or failure logs. However, it doesn't explicitly contrast with these siblings in the description text.

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?

The description provides extensive, explicit guidance on when and how to use this tool through the 'CRITICAL REQUIREMENTS' and 'Input options' sections. It specifies three mutually exclusive parameter options with clear conditions ('EXACTLY ONE of these THREE options must be used'), includes prerequisites ('If using Option 1, make sure to extract the projectSlug exactly as provided by listFollowedProjects'), and gives explicit fallback instructions ('If none of the options can be fully satisfied, ask the user for the missing information before making the tool call').

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

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/CircleCI-Public/mcp-server-circleci'

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