Skip to content

[BUG] LiteLLM Integration Fails When /v1/model/info Is Inaccessible #11898

@Syntax-Boldt

Description

@Syntax-Boldt

Extension: Roo Code
Version: 3.51.1
VS Code Version: 1.110.0
Operating System: Windows 11


Description

The LiteLLM integration fails when the endpoint /v1/model/info is not accessible. The extension does not attempt to query /v1/models as a fallback, even though that endpoint successfully can return the list of available models.


Expected Behavior

If /v1/model/info is unreachable or returns an error (e.g., 403 Forbidden), Roo Code should automatically attempt to query /v1/models to retrieve model information.


Actual Behavior

Only /v1/model/info is queried. When that endpoint fails, no fallback request to /v1/models is made, causing the integration to fail and preventing model discovery.


Relevant Endpoint Documentation


Trace / Log Output

[2026-03-09T10:49:14.386Z] Fetching from:: "https://example.com/v1/model/info"
[2026-03-09T10:49:14.858Z] Response status:: "403 Forbidden"
[2026-03-09T10:49:14.859Z] Fetching from:: "https://example.com/v1/models"
[2026-03-09T10:49:15.352Z] Response status:: "200 OK"
[2026-03-09T10:49:15.354Z] Parsed response:: {
  "object": "list",
  "modelCount": 78
}

Suggested Fix

Implement a fallback mechanism:

  1. Attempt to fetch from /v1/model/info.
  2. If the request fails or returns a non‑200 status, automatically retry with /v1/models.
  3. Parse and use whichever endpoint responds successfully.

Context (who is affected and when)

Enterprise or managed LiteLLM users where /v1/model/info is blocked by API gateways or internal policies.
Teams with LiteLLM authentication via base URL and API key
Users behind proxys or vpns, when the endpoint is blocked

Reproduction steps

  1. Open VS Code and launch Roo Code (version 3.51.1).
  2. Configure Roo Code to connect to the LiteLLM base URL and provide the API key.
  3. Set up LiteLLM with API key authentication using a base URL (e.g., https://example.com).
  • Ensure the endpoint /v1/model/info is restricted or returns 403 Forbidden.
  • Verify that /v1/models is accessible and returns a valid model list.
  1. Trigger model fetching

Expected result

If /v1/model/info is unreachable or returns an error (e.g., 403 Forbidden), Roo Code should automatically attempt to query /v1/models to retrieve model information.

Actual result

Only /v1/model/info is queried. When that endpoint fails, no fallback request to /v1/models is made, causing the integration to fail and preventing model discovery.

App Version

3.51.1

API Provider (optional)

LiteLLM

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions