Skip to main content
Glama

opencode_message_send

Destructive

Send a prompt to an AI session and wait for the response. Specify model, agent, or format to get structured output for coding tasks.

Instructions

Send a prompt message to a session and wait for the AI response. Use parts to send text, and optionally specify a model.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesThe text message to send
agentNoAgent to use
formatNoResponse format: plain text or JSON constrained by a JSON Schema. JSON Schema requires OpenCode permission for the StructuredOutput tool.
systemNoSystem prompt override
modelIDNoModel ID (e.g. 'claude-3-5-sonnet-20241022')
noReplyNoIf true, inject context without triggering AI response (useful for plugins)
variantNoModel variant (e.g. 'fast', 'smart')
directoryNoAbsolute path to the project directory. When provided, the request targets that project. If omitted, the OpenCode server uses its own working directory.
sessionIdYesSession ID
providerIDNoProvider ID (e.g. 'anthropic')

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataNo
textYes
isErrorYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.0.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=true, idempotentHint=false, and openWorldHint=true. The description adds the key behavioral trait of waiting for the AI response, which is useful. It also mentions the format option requiring OpenCode permission for StructuredOutput tool, which is a behavioral constraint. However, it doesn't disclose what 'destructive' means in this context (e.g., does sending a message mutate session state irreversibly?), and it doesn't mention rate limits or side effects beyond the annotation hints. The description adds some value but not rich behavioral context.

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 two sentences with no waste. It front-loads the core action ('Send a prompt message to a session and wait for the AI response') and then adds the key parameter hints. It could be slightly more structured by explicitly naming the async sibling, but it is concise and readable.

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

Completeness3/5

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

The tool has 10 parameters, an output schema, and annotations, so the description doesn't need to explain return values. However, given the complexity (10 params, multiple model-related fields, format options, noReply behavior), the description is thin. It doesn't explain when to use noReply, how format works, or how this differs from the async sibling. The output schema and annotations cover some gaps, but for a tool with this many options, more contextual guidance would help.

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 schema already documents all 10 parameters. The description adds minimal parameter meaning beyond the schema: it mentions 'parts' (which maps to text) and 'optionally specify a model' (modelID). It doesn't explain the relationship between agent, modelID, providerID, and variant, which could be ambiguous. Baseline 3 is appropriate since the schema does the heavy lifting.

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 states a specific verb ('send'), a resource ('prompt message to a session'), and the key behavior ('wait for the AI response'). It also mentions using 'parts' to send text and optionally specifying a model. However, it doesn't explicitly distinguish itself from the sibling opencode_message_send_async, which is a close alternative, so it loses a point on sibling differentiation.

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: send a prompt and wait for the response. It mentions 'optionally specify a model' and 'use parts to send text', giving some context. However, it does not explicitly state when to use this tool versus opencode_message_send_async (the async sibling), nor does it mention when to use noReply or other alternatives. The guidance is implied rather than explicit.

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