Skip to main content
Glama

List Livy Sessions

livy_list_sessions

Retrieve all active Livy Spark sessions in a Microsoft Fabric workspace and lakehouse to monitor session IDs, states, and configurations.

Instructions

List all Livy sessions in a workspace/lakehouse.

Retrieves all active Livy sessions for the specified workspace and lakehouse, including session IDs, states, and configuration details.

Parameters: workspace_id: Fabric workspace ID. lakehouse_id: Fabric lakehouse ID.

Returns: Dictionary with sessions list containing id, state, kind, appId, and other details.

Example: ```python result = livy_list_sessions( workspace_id="12345678-1234-1234-1234-123456789abc", lakehouse_id="87654321-4321-4321-4321-210987654321" )

for session in result.get("sessions", []):
    print(f"Session {session['id']}: {session['state']}")
```

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
workspace_idYes
lakehouse_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden. It discloses that the tool retrieves session details (IDs, states, configuration) and returns a dictionary with a sessions list, which adds behavioral context beyond basic listing. However, it doesn't cover important traits like whether this is a read-only operation, potential rate limits, authentication needs, or error handling. The description doesn't contradict any annotations (none exist).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and front-loaded with the core purpose in the first sentence. It efficiently explains parameters and returns in separate sections, and includes a relevant example. Some minor redundancy exists (e.g., repeating 'List all Livy sessions' and 'Retrieves all active Livy sessions'), but overall it's structured and concise with no wasted sentences.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (listing sessions with 2 parameters), no annotations, and an output schema present, the description is fairly complete. It covers purpose, parameters, return structure, and includes an example. However, it could improve by addressing behavioral aspects like read-only nature or error cases, but the output schema likely handles return value details, making this adequate.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description explicitly lists and describes both parameters (workspace_id and lakehouse_id) with clear semantics, adding meaning beyond the input schema which has 0% description coverage. It specifies these as 'Fabric workspace ID' and 'Fabric lakehouse ID,' providing context that the schema lacks. Since there are only 2 parameters and the description covers them fully, it compensates well for the low schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'List all Livy sessions in a workspace/lakehouse' and 'Retrieves all active Livy sessions...' with specific resources (Livy sessions) and scope (workspace/lakehouse). It distinguishes from siblings like livy_create_session or livy_close_session by focusing on listing rather than creating/managing sessions. However, it doesn't explicitly differentiate from other list tools like list_items or list_notebook_executions.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage context by specifying 'for the specified workspace and lakehouse' and mentions retrieving 'active Livy sessions,' suggesting it's for monitoring current sessions. However, it lacks explicit guidance on when to use this versus alternatives (e.g., livy_get_session_status for specific session details) or prerequisites. No when-not-to-use or comparison with sibling tools is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/bablulawrence/ms-fabric-mcp-server'

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