Skip to main content
Glama

Get Project Health

get_project_health

Analyze project test health by retrieving metrics including pass rate, flaky tests, and trends to assess test suite stability and identify areas for improvement.

Instructions

Get the health metrics for a project.

When using a user API Key (gaf_), you must provide a projectId. Use list_projects first to find available project IDs.

Returns:

  • Health score (0-100): Overall project health based on pass rate and trend

  • Pass rate: Percentage of tests passing

  • Test run count: Number of test runs in the period

  • Flaky test count: Number of tests with inconsistent results

  • Trend: Whether test health is improving (up), declining (down), or stable

Use this to understand the current state of your test suite.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectIdNoProject ID to get health for. Required when using a user API Key (gaf_). Use list_projects to find project IDs.
daysNoNumber of days to analyze (default: 30)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
trendYes
periodYes
passRateYes
healthScoreYes
projectNameYes
testRunCountYes
flakyTestCountYes
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 the return values (health score, pass rate, etc.), which is crucial for a read operation. However, it doesn't mention potential rate limits, error conditions, or authentication requirements beyond the API key note, leaving some behavioral aspects uncovered.

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 well-structured and front-loaded with the core purpose, followed by usage notes, return details, and context. Every sentence adds value: the first states the purpose, the next two provide critical usage guidelines, the bullet points clarify outputs, and the final sentence reinforces the tool's role. There is no wasted text.

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?

Given the tool's moderate complexity (2 parameters, read-only operation), the description is complete. It covers purpose, usage, prerequisites, and return values in detail. With an output schema present, the description doesn't need to explain return structures exhaustively, and it effectively complements the structured data without gaps.

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 already documents both parameters thoroughly. The description adds minimal value beyond the schema by reiterating the projectId requirement for user API Keys and mentioning list_projects for finding IDs. This meets the baseline for high schema coverage without significant additional insight.

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?

The description clearly states the tool's purpose with a specific verb ('Get') and resource ('health metrics for a project'), distinguishing it from siblings like list_projects (which lists projects) or get_flaky_tests (which focuses on flaky tests). It specifies what health metrics are retrieved, making the purpose unambiguous.

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 explicit guidance on when to use this tool: to 'understand the current state of your test suite.' It also specifies prerequisites (use list_projects first to find project IDs) and conditions (projectId required with user API Key). This clearly differentiates it from alternatives like get_coverage_summary or get_test_history.

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/gaffer-sh/mcp'

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