get_ai_config
Retrieve AI provider configuration settings used for root cause analysis in the Coroot observability platform.
Instructions
Get AI provider configuration.
Retrieves AI provider settings used for root cause analysis.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/mcp_coroot/client.py:1463-1471 (handler)Core handler method in CorootClient that executes the HTTP GET request to the /api/ai endpoint to retrieve the AI configuration.async def get_ai_config(self) -> dict[str, Any]: """Get AI provider configuration. Returns: AI provider configuration. """ response = await self._request("GET", "/api/ai") data: dict[str, Any] = response.json() return data
- src/mcp_coroot/server.py:1845-1851 (registration)MCP tool registration decorator and function definition that registers 'get_ai_config' as an MCP tool, delegating to the implementation.@mcp.tool() async def get_ai_config() -> dict[str, Any]: """Get AI provider configuration. Retrieves AI provider settings used for root cause analysis. """ return await get_ai_config_impl() # type: ignore[no-any-return]
- src/mcp_coroot/server.py:1834-1843 (helper)Helper implementation function that wraps the client call, handles errors, and formats the response for the MCP tool.@handle_errors async def get_ai_config_impl() -> dict[str, Any]: """Get AI configuration.""" client = get_client() config = await client.get_ai_config() return { "success": True, "config": config, }