Skip to main content
Glama
jamesbrink

MCP Server for Coroot

get_application

Retrieve application details and performance metrics including CPU, memory, network data, health checks, SLOs, incidents, and deployment history from the Coroot observability platform.

Instructions

Get application details and metrics.

Retrieves comprehensive information about an application including:

  • Performance metrics (CPU, memory, network)

  • Health checks and SLOs

  • Recent incidents

  • Deployment history

Args: project_id: Project ID app_id: Application ID (format: namespace/kind/name) from_timestamp: Start timestamp for metrics (optional) to_timestamp: End timestamp for metrics (optional)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYes
app_idYes
from_timestampNo
to_timestampNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Core handler implementing the tool logic: URL-encodes app_id and delegates to CorootClient.get_application to fetch application details and metrics.
    async def get_application_impl(
        project_id: str,
        app_id: str,
        from_timestamp: int | None = None,
        to_timestamp: int | None = None,
    ) -> dict[str, Any]:
        """Get application details and metrics."""
        # URL encode the app_id since it contains slashes
        encoded_app_id = quote(app_id, safe="")
    
        app = await get_client().get_application(
            project_id, encoded_app_id, from_timestamp, to_timestamp
        )
        return {
            "success": True,
            "application": app,
        }
  • MCP tool registration via @mcp.tool() decorator. Defines the tool interface, parameters (serving as input schema), and comprehensive docstring describing usage and output.
    @mcp.tool()
    async def get_application(
        project_id: str,
        app_id: str,
        from_timestamp: int | None = None,
        to_timestamp: int | None = None,
    ) -> dict[str, Any]:
        """Get application details and metrics.
    
        Retrieves comprehensive information about an application including:
        - Performance metrics (CPU, memory, network)
        - Health checks and SLOs
        - Recent incidents
        - Deployment history
    
        Args:
            project_id: Project ID
            app_id: Application ID (format: namespace/kind/name)
            from_timestamp: Start timestamp for metrics (optional)
            to_timestamp: End timestamp for metrics (optional)
        """
        return await get_application_impl(  # type: ignore[no-any-return]
            project_id, app_id, from_timestamp, to_timestamp
        )
  • Supporting client method in CorootClient that makes the HTTP GET request to the Coroot API to retrieve application data, handling query parameters for time range.
    async def get_application(
        self,
        project_id: str,
        app_id: str,
        from_timestamp: int | None = None,
        to_timestamp: int | None = None,
    ) -> dict[str, Any]:
        """Get application details and metrics.
    
        Args:
            project_id: Project ID.
            app_id: Application ID (format: namespace/kind/name).
            from_timestamp: Start timestamp for metrics.
            to_timestamp: End timestamp for metrics.
    
        Returns:
            Application metrics and information.
        """
        params = {}
        if from_timestamp:
            params["from"] = str(from_timestamp)
        if to_timestamp:
            params["to"] = str(to_timestamp)
    
        response = await self._request(
            "GET",
            f"/api/project/{project_id}/app/{app_id}",
            params=params,
        )
        data: dict[str, Any] = response.json()
        return data
  • Utility function to lazily initialize and retrieve the shared CorootClient instance used by all MCP tools.
    def get_client() -> CorootClient:
        """Get or create the client instance.
    
        Raises:
            ValueError: If no credentials are configured.
        """
        global _client
        if _client is None:
            try:
                _client = CorootClient()
            except ValueError as e:
                # Re-raise with more context
                raise ValueError(
                    "Coroot credentials not configured. "
                    "Please set COROOT_BASE_URL and either:\n"
                    "  - COROOT_USERNAME and COROOT_PASSWORD for automatic login\n"
                    "  - COROOT_SESSION_COOKIE for direct authentication\n"
                    "  - COROOT_API_KEY for data ingestion endpoints"
                ) from e
        return _client
Behavior3/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 adequately describes what information is retrieved but lacks details about permissions required, rate limits, pagination behavior, or error conditions. The mention of optional timestamp parameters implies time-bound queries but doesn't specify default time ranges or format requirements.

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 well-structured with a clear purpose statement followed by bullet points of retrieved information and a dedicated Args section. While efficient, the bullet points could be more concise, and the structure slightly separates the parameter explanations from the main description flow.

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 tool's moderate complexity (4 parameters, no annotations, but with output schema), the description is reasonably complete. It explains what data is retrieved and documents all parameters. The existence of an output schema means the description doesn't need to explain return values, making this adequate though usage guidance is lacking.

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?

With 0% schema description coverage, the description compensates well by explaining all 4 parameters in the Args section. It clarifies that project_id and app_id are required, provides the format for app_id ('namespace/kind/name'), and explains that timestamps are optional parameters for filtering metrics. This adds significant value beyond the bare schema.

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's purpose with a specific verb ('Retrieves') and resource ('comprehensive information about an application'), listing key data categories like performance metrics and health checks. However, it doesn't explicitly differentiate from sibling tools like 'get_application_logs' or 'get_application_profiling', which appear to retrieve specific subsets of application data.

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 many sibling tools like 'get_application_logs', 'get_application_profiling', and 'get_applications_overview', there's no indication of when this comprehensive retrieval is preferred over more specific tools or when it might be inappropriate.

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/jamesbrink/mcp-coroot'

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