Skip to main content
Glama

list_environments

Retrieve all available Lenses environments with their current status, metrics, and metadata for managing Kafka clusters.

Instructions

Lists all Lenses environments.

Returns: A list containing all environments with their details including status, metrics, and metadata.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The core handler function for the 'list_environments' tool. Decorated with @mcp.tool() for registration. Fetches and returns a list of all Lenses environments from the API endpoint /api/v1/environments.
    @mcp.tool() async def list_environments() -> List[Dict[str, Any]]: """ Lists all Lenses environments. Returns: A list containing all environments with their details including status, metrics, and metadata. """ result = await api_client._make_request("GET", "/api/v1/environments") return result.get("items", [])
  • Invocation of register_environments(mcp) which registers the 'list_environments' tool (and others) with the main FastMCP instance.
    register_environments(mcp)

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/stereosky/lenses-mcp'

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