Skip to main content
Glama

get_inspection_config

Retrieve configuration for application performance inspections like CPU, memory, or SLO monitoring to analyze and manage observability settings.

Instructions

Get inspection configuration for an application.

Retrieves the current configuration for a specific inspection type (e.g., cpu, memory, slo_availability, slo_latency) for an application.

Args: project_id: Project ID app_id: Application ID (format: namespace/kind/name) inspection_type: Type of inspection (cpu, memory, slo, etc)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYes
app_idYes
inspection_typeYes

Implementation Reference

  • MCP tool handler function that executes the get_inspection_config tool by calling the internal implementation.
    @mcp.tool() async def get_inspection_config( project_id: str, app_id: str, inspection_type: str, ) -> dict[str, Any]: """Get inspection configuration for an application. Retrieves the current configuration for a specific inspection type (e.g., cpu, memory, slo_availability, slo_latency) for an application. Args: project_id: Project ID app_id: Application ID (format: namespace/kind/name) inspection_type: Type of inspection (cpu, memory, slo, etc) """ return await get_inspection_config_impl( # type: ignore[no-any-return] project_id, app_id, inspection_type )
  • Internal implementation of the tool handler that uses the CorootClient to fetch the inspection configuration.
    @handle_errors async def get_inspection_config_impl( project_id: str, app_id: str, inspection_type: str, ) -> dict[str, Any]: """Get inspection configuration.""" config = await get_client().get_inspection_config( project_id, app_id, inspection_type ) return { "success": True, "config": config, }
  • FastMCP tool registration decorator for the get_inspection_config tool.
    @mcp.tool()
  • CorootClient helper method that makes the actual API request to retrieve the inspection configuration.
    async def get_inspection_config( self, project_id: str, app_id: str, inspection_type: str ) -> dict[str, Any]: """Get inspection configuration for an application. Args: project_id: Project ID. app_id: Application ID. inspection_type: Type of inspection (cpu, memory, slo, etc). Returns: Inspection configuration. """ # URL encode the app_id since it contains slashes from urllib.parse import quote encoded_app_id = quote(app_id, safe="") response = await self._request( "GET", f"/api/project/{project_id}/app/{encoded_app_id}/inspection/{inspection_type}/config", ) data: dict[str, Any] = response.json() return data

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