Skip to main content
Glama

session_send

Send a message to a registered bridge session to hand off work and receive its reply. Retries stay idempotent with an operation ID, and busy sessions error instead of queuing.

Instructions

写:给登记册会话发一条消息。带 operationId 幂等键(可传入复用:同一 operationId 已投递成功时不再重发);profile.promptSuffix 非空时在末尾追加该后缀(useSubagent=false 不加);写发送审计(只存哈希)。会话 busy 时直接报错,不排队不叠发。

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "sessionId": "<sessionId>",
      "text": "<text>"
    },
    "name": "session_send"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYes消息正文(原样发送,只按规则追加后缀)
sessionIdYesBridge 会话 ID(必须是本连接器登记册内的会话;session_adopt 是唯一接管入口)
operationIdNo可选幂等键(建议 UUID):超时后重试时传同一个值。同一 operationId 已投递成功的,server 直接返回上次结果、不再发一次。
useSubagentNo默认 true;false 时不追加 promptSuffix

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: idempotency semantics for operationId, the promptSuffix/useSubagent interaction, audit logging that stores only a hash, and hard-fail behavior on busy sessions. Gaps remain around authentication/prerequisites and what a successful send returns, since there is no output schema.

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?

One dense paragraph, front-loaded with a '写:' marker that signals the operation class before details. Parenthetical asides are informative rather than filler, though the sentence is heavily nested and could be split for scanability.

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?

A 4-parameter mutation tool with no annotations needs strong behavioral prose, and this supplies idempotency, side effects, and failure modes. What is missing is the return contract (no output schema exists) and any permission requirements, which an agent would want before calling.

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 baseline is 3. The description does add genuine meaning beyond the schema by explaining the conditional relationship between profile.promptSuffix and useSubagent, but it restates operationId and sessionId semantics already documented in the schema.

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?

Opens with a specific verb+resource stated as '写:给登记册会话发一条消息' (write: send a message to a registered session), and the 'write' framing plus the scoping to sessions in this connector's registry distinguishes it from read-side siblings like session_read. No sibling is named as the alternative, so it stops short of full 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?

Conveys a key usage constraint — a busy session errors immediately, with no queueing or stacking — which tells the agent not to blindly retry. It also explains when to reuse operationId. However it never names an explicit alternative (e.g. session_wait) or states exclusions, leaving routing to inference.

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