Skip to main content
Glama

testmo_list_run_results

List test results for a test run with optional filters for status, assignee, creator, and creation date.

Instructions

List test results for a run with optional filters.

Args: run_id: The test run ID. status_id: Comma-separated status IDs (1=Untested, 2=Passed, 3=Failed, 4=Retest, 5=Blocked, 6=Skipped). assignee_id: Comma-separated assignee IDs. created_by: Comma-separated user IDs who created results. created_after: Filter results created after (ISO8601 format). created_before: Filter results created before (ISO8601 format). get_latest_result: If true, return only the latest result per test. page: Page number (default: 1). per_page: Results per page (default: 100). Valid: 25, 50, 100. expands: Related entities to include.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
run_idYes
status_idNo
assignee_idNo
created_byNo
created_afterNo
created_beforeNo
get_latest_resultNo
pageNo
per_pageNo
expandsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function testmo_list_run_results that lists test results for a run with optional filters (status_id, assignee_id, created_by, created_after, created_before, get_latest_result, pagination, expands). Makes a GET request to /runs/{run_id}/results.
    @mcp.tool()
    async def testmo_list_run_results(
        run_id: int,
        status_id: str | None = None,
        assignee_id: str | None = None,
        created_by: str | None = None,
        created_after: str | None = None,
        created_before: str | None = None,
        get_latest_result: bool | None = None,
        page: int = 1,
        per_page: int = 100,
        expands: list[str] | None = None,
    ) -> dict[str, Any]:
        """List test results for a run with optional filters.
    
        Args:
            run_id: The test run ID.
            status_id: Comma-separated status IDs (1=Untested, 2=Passed, 3=Failed, 4=Retest, 5=Blocked, 6=Skipped).
            assignee_id: Comma-separated assignee IDs.
            created_by: Comma-separated user IDs who created results.
            created_after: Filter results created after (ISO8601 format).
            created_before: Filter results created before (ISO8601 format).
            get_latest_result: If true, return only the latest result per test.
            page: Page number (default: 1).
            per_page: Results per page (default: 100). Valid: 25, 50, 100.
            expands: Related entities to include.
        """
        params: dict[str, Any] = {"page": page, "per_page": per_page}
        if status_id:
            params["status_id"] = status_id
        if assignee_id:
            params["assignee_id"] = assignee_id
        if created_by:
            params["created_by"] = created_by
        if created_after:
            params["created_after"] = created_after
        if created_before:
            params["created_before"] = created_before
        if get_latest_result is not None:
            params["get_latest_result"] = get_latest_result
        if expands:
            params["expands"] = ",".join(expands)
        return await _request("GET", f"/runs/{run_id}/results", params=params)
  • The input schema is defined via the function signature parameters (run_id, status_id, assignee_id, created_by, created_after, created_before, get_latest_result, page, per_page, expands) with type hints and docstring documenting the valid values.
    @mcp.tool()
    async def testmo_list_run_results(
        run_id: int,
        status_id: str | None = None,
        assignee_id: str | None = None,
        created_by: str | None = None,
        created_after: str | None = None,
        created_before: str | None = None,
        get_latest_result: bool | None = None,
        page: int = 1,
        per_page: int = 100,
        expands: list[str] | None = None,
    ) -> dict[str, Any]:
        """List test results for a run with optional filters.
    
        Args:
            run_id: The test run ID.
            status_id: Comma-separated status IDs (1=Untested, 2=Passed, 3=Failed, 4=Retest, 5=Blocked, 6=Skipped).
            assignee_id: Comma-separated assignee IDs.
            created_by: Comma-separated user IDs who created results.
            created_after: Filter results created after (ISO8601 format).
            created_before: Filter results created before (ISO8601 format).
            get_latest_result: If true, return only the latest result per test.
            page: Page number (default: 1).
            per_page: Results per page (default: 100). Valid: 25, 50, 100.
            expands: Related entities to include.
        """
        params: dict[str, Any] = {"page": page, "per_page": per_page}
        if status_id:
            params["status_id"] = status_id
        if assignee_id:
            params["assignee_id"] = assignee_id
        if created_by:
            params["created_by"] = created_by
        if created_after:
            params["created_after"] = created_after
        if created_before:
            params["created_before"] = created_before
        if get_latest_result is not None:
            params["get_latest_result"] = get_latest_result
        if expands:
            params["expands"] = ",".join(expands)
        return await _request("GET", f"/runs/{run_id}/results", params=params)
  • testmo-mcp.py:15-15 (registration)
    Tool registration is triggered by importing testmo.tools.runs, which causes the @mcp.tool() decorator on testmo_list_run_results to execute.
    import testmo.tools.runs  # noqa: F401
  • testmo/server.py:6-6 (registration)
    The mcp FastMCP instance (used via @mcp.tool() decorator) is created here.
    mcp = FastMCP("testmo-mcp")
  • The _request helper function used by testmo_list_run_results to make the HTTP GET request to the Testmo API.
    async def _request(
        method: str,
        endpoint: str,
        data: dict[str, Any] | None = None,
        params: dict[str, Any] | None = None,
    ) -> dict[str, Any]:
        async with _get_client() as client:
            response = await client.request(
                method=method,
                url=endpoint,
                json=data,
                params=params,
            )
            if response.status_code == 204:
                return {"success": True}
            if response.status_code >= 400:
                try:
                    error_body = response.json()
                except Exception:
                    error_body = response.text
                raise RuntimeError(
                    f"Testmo API error {response.status_code}: "
                    f"{json.dumps(error_body) if isinstance(error_body, dict) else error_body}"
                )
            return response.json()
Behavior3/5

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

No annotations are provided, so the description carries full burden. It discloses pagination behavior (page, per_page defaults) and filter parameters, but does not explicitly state read-only nature, authentication requirements, or potential rate limits. The description is partially transparent but lacks comprehensive behavioral detail.

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?

The description is structured as a clear docstring with a header and parameter list. It is somewhat lengthy but justified given the number of parameters. No superfluous information is included.

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?

With an output schema existing, the description need not explain return values. It covers input parameters thoroughly, including pagination and filters. However, it lacks discussion of error conditions or expected behavior, which slightly diminishes completeness.

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?

The description explains every parameter in detail, including default values and valid ranges (e.g., per_page: 25, 50, 100). The schema only provides titles, so the description adds significant meaning. This fully compensates for the 0% schema description coverage.

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 lists test results for a run with optional filters, which is a specific verb+resource combination. It differentiates from siblings like testmo_list_runs (list runs) and testmo_get_run (single run metadata).

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 does not provide explicit guidance on when to use this tool versus alternatives, nor does it mention prerequisites or exclusions. There is no 'when to use' or 'when not to use' advice.

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/strelec00/testmo-mcp'

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