Skip to main content
Glama

test_config

Verify configuration settings and API connectivity for Radarr/Sonarr media management systems.

Instructions

Test the current configuration and API connectivity.

Returns: Configuration status and basic connectivity tests

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the 'test_config' MCP tool. It tests the server configuration and Radarr connectivity, returning a status dictionary. Registered via the @mcp.tool decorator.
    @mcp.tool
    async def test_config() -> Dict[str, Any]:
        """
        Test the current configuration and API connectivity.
        
        Returns:
            Configuration status and basic connectivity tests
        """
        logger.info("Testing configuration...")
        
        if not config:
            return {"error": "No configuration loaded"}
        
        status = {
            "config_loaded": True,
            "radarr_url": config.radarr_url,
            "sonarr_url": config.sonarr_url,
            "radarr_api_key_set": bool(config.radarr_api_key),
            "sonarr_api_key_set": bool(config.sonarr_api_key),
            "tvdb_api_key_set": bool(config.tvdb_api_key),
            "quality_profile_id": config.quality_profile_id,
            "radarr_root_folder": config.radarr_root_folder,
            "sonarr_root_folder": config.sonarr_root_folder
        }
        
        # Test Radarr connectivity
        if config.radarr_api_key:
            try:
                api = MediaServerAPI(config)
                test_results = await api.search_radarr_movies("test")
                status["radarr_search_connectivity"] = "success"
                status["radarr_test_results"] = len(test_results)
            except Exception as e:
                status["radarr_search_connectivity"] = "failed"
                status["radarr_search_error"] = str(e)
        else:
            status["radarr_search_connectivity"] = "no_api_key"
        
        return status

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/omniwaifu/arr-assistant-mcp'

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