Skip to main content
Glama

set_session_control

Idempotent

Change a session's control mode to suspended or manual_handoff to bypass the agent loop for new messages, or engaged to resume normal operation.

Instructions

Change a session's control_mode (engaged, suspended, manual_handoff). When ≠ engaged, the agent loop is bypassed for new messages on that session

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": {
      "session_id": "<session_id>",
      "mode": "<mode>"
    },
    "name": "set_session_control"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeYesengaged resumes normal operation; suspended pauses; manual_handoff transfers control to a human
reasonNoOptional audit reason
messageNoOptional fixed response. Empty means a silent acknowledgement. Applies only when mode is not engaged.
expires_atNoOptional expiry (ISO 8601 with timezone, for example 2026-10-05T12:00:00Z; at most 30 days) for suspended/manual_handoff mode. At expiry, the session returns to engaged automatically. Omitted means no expiry; another call without expires_at CLEARS the previous expiry. Repeat it to change only the message.
session_idYesSession session_id string or UUID

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv2.2.4
    • changedInput schema / properties / expires_at / description
      Previous value: -"Prazo opcional (ISO 8601 com fuso, ex.: 2026-10-05T12:00:00Z; no máximo 30 dias) para mode suspended/manual_handoff. No prazo a sessão volta para engaged sozinha. Omitido = sem prazo — e uma nova chamada sem expires_at APAGA o prazo anterior (repita o prazo para só trocar a mensagem)."New value: +"Optional expiry (ISO 8601 with timezone, for example 2026-10-05T12:00:00Z; at most 30 days) for suspended/manual_handoff mode. At expiry, the session returns to engaged automatically. Omitted means no expiry; another call without expires_at CLEARS the previous expiry. Repeat it to change only the message."
    • changedInput schema / properties / message / description
      Previous value: -"Canned message opcional. Vazia = ACK silencioso (default). Só aplicada quando mode != engaged."New value: +"Optional fixed response. Empty means a silent acknowledgement. Applies only when mode is not engaged."
    • changedInput schema / properties / mode / description
      Previous value: -"engaged = volta ao normal; suspended = pausa; manual_handoff = humano assumiu"New value: +"engaged resumes normal operation; suspended pauses; manual_handoff transfers control to a human"
    • changedInput schema / properties / reason / description
      Previous value: -"Motivo opcional (audit/telemetria)"New value: +"Optional audit reason"
    • changedInput schema / properties / session_id / description
      Previous value: -"session_id text (ou UUID id) da sessão"New value: +"Session session_id string or UUID"
  2. Changed1 schema field changedv2.2.2
    • addedInput schema / properties / expires_at
      Added value: +{
      +  "description": "Prazo opcional (ISO 8601 com fuso, ex.: 2026-10-05T12:00:00Z; no máximo 30 dias) para mode suspended/manual_handoff. No prazo a sessão volta para engaged sozinha. Omitido = sem prazo — e uma nova chamada sem expires_at APAGA o prazo anterior (repita o prazo para só trocar a mensagem).",
      +  "type": "string"
      +}
  3. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, idempotentHint=true and destructiveHint=false, so the safety profile is covered. The description contributes one genuinely useful non-obvious behavior — that non-engaged modes make the agent loop bypass new messages on that session — but says nothing about permission requirements or what a caller observes after the switch.

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?

Two compact sentences with the state change front-loaded and the operational consequence second. The backtick/`≠` shorthand is slightly terse but not wasteful.

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?

No output schema exists, but the mutation's immediate effect is stated and the parameter-level detail lives fully in the schema, so an agent has enough to call it correctly. The only meaningful gap is the lack of differentiation from set_engagement_control.

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%, and the schema already documents each mode, the optional reason, the message behavior, and the expires_at clearing semantics in detail. The description only restates the enum values and the post-condition of a non-engaged mode, adding little beyond the structured fields.

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?

States a specific verb and resource ('Change a session's control_mode') and enumerates the three valid values, so an agent knows exactly what state is being written. It does not, however, distinguish itself from the similarly named sibling set_engagement_control, which could cause a mis-selection.

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

Usage Guidelines2/5

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

The description explains the effect of a non-engaged mode but gives no when-to-use guidance, no prerequisites, and no routing against the overlapping sibling set_engagement_control. The reader must infer the selection criteria from the mode names alone.

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