Skip to main content
Glama

Turn a chat flow on or off

set_flow_active
Destructive

Turn a chat flow on (active: true) or off (active: false). Turning it ON makes it start answering real contacts at once, in the name of every account it is bound to (connectionIds; empty = every messaging account), with no further confirmation — only call it when the user has asked for this flow to go live, after reading it with get_flow. Turning it off stops new runs; a run already waiting for a reply is not recalled. Calling it again with the same value changes nothing. Writing also needs chat enabled for the organization and an ADMIN or OWNER role in it, and a new flow counts against the plan's flow limit (403 CHAT_FLOW_LIMIT_REACHED) — the same refusals a person gets in the app. Needs the organization's "Let AI assistants create and edit chat flows" setting (mcpFlowsEnabled; only the organization's OWNER can switch it on, in Settings → Organization → General → AI Assistants; without it the api answers 403 MCP_FLOWS_DISABLED) and a connection authorized with the flows permissions — one authorized before they existed must remove PostRite from the assistant and add it again.

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": {
      "flowId": "<flowId>",
      "active": "<active>"
    },
    "name": "set_flow_active"
  }
}

Input Schema

NameRequiredDescriptionDefault
activeYestrue to turn the flow on (it answers real contacts at once), false to turn it off
flowIdYesThe flow's ID (from list_flows)
organizationIdNoOrganization to act in — an id from list_organizations. Required when this connection was authorized for more than one organization; omit it when there is only one.

Output Schema

NameRequiredDescriptionDefault
idNo
nameNo
graphNo
runCountNo
createdAtNo
isEnabledNotrue = live: it answers real contacts
updatedAtNo
triggerTypeNo
connectionIdsNoThe accounts it answers on; empty = every messaging account
isGraphBrokenNoThe stored graph no longer parses; rewrite it with update_flow
triggerConfigNo
cooldownMinutesNo
lastTriggeredAtNo
runCountLast7DaysNo
maxRunsPerContactPerDayNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior4/5

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

Beyond the annotations it discloses real consequences: turning on starts answering real contacts at once in the name of every bound account (connectionIds; empty = all accounts), turning off stops new runs but does not recall a run already awaiting a reply, and it lists the auth prerequisites (ADMIN/OWNER, mcpFlowsEnabled, a flows-permission connection that may need re-authorization) plus concrete refusals (403 CHAT_FLOW_LIMIT_REACHED, 403 MCP_FLOWS_DISABLED). The one patch is 'calling it again with the same value changes nothing,' which sits in tension with idempotentHint=false — best read as scoped to the flow's state while the annotation covers side effects, but it is not reconciled explicitly.

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 most important fact — that this makes the flow answer real contacts immediately with no further confirmation — is front-loaded, and each subsequent clause carries a distinct operational fact. It is a single dense paragraph with some parenthetical UI path detail (Settings → Organization → General → AI Assistants) that could be trimmed, but little is genuinely wasted.

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

Completeness5/5

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

For a destructive, open-world toggle with an output schema, the description covers consequences, confirmation expectations, permission and feature-flag prerequisites, error codes, and re-authorization recovery. An agent has everything needed to decide whether to call it and what to expect if it is refused.

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

Parameters4/5

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

Schema coverage is already 100%, so the parameters are documented; the description nonetheless adds meaning the schema lacks by explaining that connectionIds empty means every messaging account, including the blast radius of that default. It does not add anything for flowId or organizationId, which is acceptable given the schema already covers them.

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 states a specific verb and resource plus the exact parameterization: 'Turn a chat flow on (active: true) or off (active: false).' It is immediately distinguishable from siblings such as get_flow (read), update_flow (edit), and create_flow (create).

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?

It gives an explicit when-to-call gate: 'only call it when the user has asked for this flow to go live, after reading it with get_flow,' and names the sibling to use first. The when-not case (no user request, no confirmation step) is stated directly.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources