Skip to main content
Glama

opencode_instance_dispose

Destructive

Shut down the running server instance to end the session and release resources. Specify the project directory to target a specific OpenCode project.

Instructions

Dispose the current opencode instance (shuts it down). WARNING: This is destructive and will terminate the server.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
directoryNoAbsolute path to the project directory. When provided, the request targets that project. If omitted, the OpenCode server uses its own working directory.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataNo
textYes
isErrorYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.0.0

TDQS

A4/5.0
Behavior4/5

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

Annotations already carry destructiveHint=true and readOnlyHint=false, and the description reinforces this with an explicit WARNING that the server terminates. It goes beyond the label by clarifying exactly what is destroyed: the current opencode instance/server. This is adequate transparency for a destructive shutdown tool.

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?

Two short sentences front-load the operation and add a necessary warning. Every word earns its place; there is no filler or redundancy.

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?

For a one-optional-parameter destructive tool with an output schema and clear safety annotations, the description covers the essential facts: function, target, and destructive consequence. The optional directory targeting behavior is fully covered by the schema, so no critical selection-time information is missing.

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?

Schema description coverage is 100%, so the directory parameter is fully documented in the schema. The description adds no parameter-specific semantics beyond the schema, matching the baseline for high schema coverage.

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 uses a specific verb, 'Dispose', names the resource ('current opencode instance'), and clarifies with 'shuts it down' and 'terminate the server'. This clearly distinguishes it from session-level tools like opencode_session_delete and from all read-only sibling tools.

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?

Usage is implied: call it to shut down the current opencode instance. However, it does not explicitly state when not to use it or name less destructive alternatives such as session deletion or abort. A sentence like 'Use only when the instance is no longer needed' would strengthen this.

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

Deploy Server

Other Tools