{"record":{"id":"fd1488fe3883a529","repo":"BerriAI/litellm","slug":"unable-to-health-check-wildcard-model-for-provider","errorCode":null,"errorMessage":"Unable to health check wildcard model for provider {custom_llm_provider}. Add a model on your config.yaml or contribute here - https://github.com/BerriAI/litellm/blob/main/model_prices_and_context_window.json","messagePattern":"Unable to health check wildcard model for provider (.+?)\\. Add a model on your config\\.yaml or contribute here - https://github\\.com/BerriAI/litellm/blob/main/model_prices_and_context_window\\.json","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"warning","filePath":"litellm/litellm_core_utils/health_check_helpers.py","lineNumber":33,"sourceCode":"\n\nclass HealthCheckHelpers:\n    @staticmethod\n    async def ahealth_check_wildcard_models(\n        model: str,\n        custom_llm_provider: str,\n        model_params: dict,\n        litellm_logging_obj: \"Logging\",\n    ) -> dict:\n        from litellm import acompletion\n        from litellm.litellm_core_utils.llm_request_utils import (\n            pick_cheapest_chat_models_from_llm_provider,\n        )\n\n        # this is a wildcard model, we need to pick a random model from the provider\n        cheapest_models = pick_cheapest_chat_models_from_llm_provider(custom_llm_provider=custom_llm_provider, n=3)\n        if len(cheapest_models) == 0:\n            raise Exception(\n                f\"Unable to health check wildcard model for provider {custom_llm_provider}. Add a model on your config.yaml or contribute here - https://github.com/BerriAI/litellm/blob/main/model_prices_and_context_window.json\"\n            )\n        if len(cheapest_models) > 1:\n            fallback_models = cheapest_models[1:]  # Pick the last 2 models from the shuffled list\n        else:\n            fallback_models = None\n        model_params[\"model\"] = cheapest_models[0]\n        model_params[\"litellm_logging_obj\"] = litellm_logging_obj\n        model_params[\"fallbacks\"] = fallback_models\n        model_params[\"max_tokens\"] = model_params.get(\"max_tokens\", 16)  # GPT-5 models require max_output_tokens >= 16\n        await acompletion(**model_params)\n        return {}\n\n    @staticmethod\n    def _update_model_params_with_health_check_tracking_information(\n        model_params: dict,\n    ) -> dict:\n        \"\"\"","sourceCodeStart":15,"sourceCodeEnd":51,"githubUrl":"https://github.com/BerriAI/litellm/blob/6c2dcb801bf2b75c18f1bb24140e7cf57465cc4d/litellm/litellm_core_utils/health_check_helpers.py#L15-L51","documentation":"Raised when the proxy health check (or a caller of _run_health_check for a wildcard model) tries to health-check a wildcard deployment such as 'openai/*'. LiteLLM attempts to substitute a concrete cheap model from the known model list (model_prices_and_context_window.json / config.yaml); if the provider has zero known chat models, it cannot pick anything and raises this Exception telling you to add a model.","triggerScenarios":"Hitting the proxy /health or /health/liveliness endpoints (or calling the health-check helper) with a wildcard model deployment like 'vertex_ai/*', 'groq/*' for a provider that has no chat entries in the bundled model_prices_and_context_window.json and no matching model_info entries in your config.yaml.","commonSituations":"Using a niche or new provider with wildcard routing; running an older LiteLLM whose model_prices file lacks entries for your provider; config.yaml that only declares the wildcard model without model_info pricing entries.","solutions":["Add at least one concrete model with model_info for that provider to your config.yaml deployments so the health check has a model to pick","Update LiteLLM so the bundled model_prices_and_context_window.json includes chat models for the provider (pip install -U litellm)","Contribute missing model entries to model_prices_and_context_window.json upstream (the error links the file)","Health-check a concrete model name instead of the wildcard deployment"],"exampleFix":"# before (config.yaml)\nmodel_list:\n  - model_name: \"my-wildcard\"\n    litellm_params:\n      model: \"newprovider/*\"\n      api_key: os.environ/NEWPROVIDER_API_KEY\n\n# after: give the health check a concrete model to sample\nmodel_list:\n  - model_name: \"my-wildcard\"\n    litellm_params:\n      model: \"newprovider/*\"\n      api_key: os.environ/NEWPROVIDER_API_KEY\n  - model_name: \"my-concrete\"\n    litellm_params:\n      model: \"newprovider/known-chat-model\"\n      api_key: os.environ/NEWPROVIDER_API_KEY","handlingStrategy":"try-catch","validationCode":"from litellm.litellm_core_utils.llm_request_utils import pick_cheapest_chat_models_from_llm_provider\n\nif not pick_cheapest_chat_models_from_llm_provider(custom_llm_provider=provider, n=1):\n    print(f'No known chat models for {provider}; add one to config.yaml before health checks')","typeGuard":null,"tryCatchPattern":"try:\n    router.health_check()\nexcept Exception as e:\n    if 'Unable to health check wildcard model' in str(e):\n        # non-fatal: health endpoint only; log and continue\n        logging.warning('Wildcard health check unavailable: %s', e)\n    else:\n        raise","preventionTips":["Always declare at least one concrete model per provider alongside wildcard deployments","Keep litellm updated so model_prices_and_context_window.json is current","Treat wildcard health-check failures as warnings in monitoring, not outages"],"tags":["litellm","health-check","wildcard-model","proxy","config"],"backgroundTag":null,"analyzedSha":"6c2dcb801bf2b75c18f1bb24140e7cf57465cc4d","analyzedAt":"2026-08-15T07:12:03.035Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}