Skip to main content
Glama
SH4RKKK

ibm-i-5250-mcp

by SH4RKKK

session_close

Sign off and close an IBM i 5250 session to release the virtual device, preventing a hung interactive job and 'Attempt to Recover Interactive Job' on the next run.

Instructions

Sign off and close the session, releasing the virtual device. Always do this when finished: just dropping the connection leaves a disconnected interactive job on the box, so the next run meets an "Attempt to Recover Interactive Job" screen instead of the application, and it holds licensed interactive capacity.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sessionNowhich open session to act on. Omit unless you opened more than one (default: "default")
signOffNotype signoff on the command line first, when the screen has one (default: true). Pass false to drop the connection immediately

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

The description discloses important behavioral traits beyond the schema: it releases the virtual device, and it warns that simply dropping the connection leaves a disconnected interactive job that can cause problems on the next run. It also explains the impact on licensed interactive capacity. Since no annotations are provided, the description carries the full burden, and it does so well, though it could mention whether the operation is reversible or if it requires confirmation.

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

Conciseness5/5

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

The description is concise and front-loaded with the core action ('Sign off and close the session, releasing the virtual device'), followed by a clear directive and consequence. Every sentence earns its place, and the warning about the 'Attempt to Recover Interactive Job' screen is valuable context without being verbose.

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 simplicity (2 optional parameters, no output schema), the description is quite complete. It explains the purpose, the consequence of misuse, and the parameter behavior. It could be slightly more complete by mentioning what happens after closing (e.g., whether the session is immediately terminated or if there's a grace period), but overall it provides enough context for an agent to use it correctly.

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

Parameters3/5

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

The schema description coverage is 100%, so the schema already documents both parameters ('session' and 'signOff'). The description adds context about the 'signOff' parameter by explaining the default behavior ('type signoff on the command line first') and the alternative ('Pass false to drop the connection immediately'). However, it doesn't add much beyond what the schema already states, so a baseline of 3 is appropriate.

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

Purpose5/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: 'Sign off and close the session, releasing the virtual device.' It uses a specific verb ('close') and resource ('session'), and distinguishes it from siblings like session_open by focusing on the teardown action. The description also explains the consequence of not using it, which further clarifies its role.

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

Usage Guidelines5/5

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

The description explicitly states when to use this tool: 'Always do this when finished.' It also explains the negative consequence of not using it (leaving a disconnected interactive job, causing an 'Attempt to Recover Interactive Job' screen and holding licensed capacity). This provides clear guidance on when it is necessary, though it doesn't explicitly name alternatives, the context makes it obvious this is the closing counterpart to session_open.

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