Skip to main content
Glama

Edit workflow graph

campaignstack_edit_workflow_graph

Atomically patch or replace one workflow graph. replace supplies the full non-anchor graph. patch starts from the current non-anchor graph, upserts/removes nodes, and replaces edges when supplied. A patched node's config is merged into the stored one: only the keys you send change, and a key sent as null is cleared. Invalid graphs are rejected before persistence; active-lead safety remains enforced by the workflow backend. Optional split-node optimization runs after the graph write.

Input Schema

NameRequiredDescriptionDefault
modeYes
graphNo
patchNo
workflowIdYes
workspaceIdNoWorkspace ID. Omit it when this connection reaches one workspace: a workspace key (cs_) is bound to its own, and a user key (csu_) or connected app whose person belongs to exactly one workspace defaults to that one. Required only when the person belongs to several; the error then lists them, and campaignstack_whoami reports them too.
optimizeSplitNodeIdsNoOptional named split nodes to optimize after a valid graph write.

Output Schema

NameRequiredDescriptionDefault
okNo
resultsNo
warningsNo
workflowIdNo
workspaceIdNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / workspaceId / description
      Previous value: -"Workspace ID. REQUIRED for a user key (csu_), which spans every workspace you belong to; omitted for a workspace key (cs_), which is bound to one and ignores this argument. campaignstack_whoami reports which kind of key you are holding and, for a user key, the workspaces it can reach."New value: +"Workspace ID. Omit it when this connection reaches one workspace: a workspace key (cs_) is bound to its own, and a user key (csu_) or connected app whose person belongs to exactly one workspace defaults to that one. Required only when the person belongs to several; the error then lists them, and campaignstack_whoami reports them too."
  2. Added

TDQS

A4.4/5.0
Behavior4/5

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

Discloses behavior well beyond the annotations: atomicity, validation-before-persistence, config merge with null-clears-key semantics, edge replacement rules, and post-write split-node optimization. The one tension is that 'replace' discards the existing graph while destructiveHint=false, though the tool does not destroy the workflow itself, so this is a scoping nuance rather than a contradiction.

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?

Five tight sentences, front-loaded with the core action and mode split, then merge semantics, then safety and optimization notes. Every sentence carries distinct information; nothing is redundant.

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 mutation tool with a rich nested schema, an output schema, and annotations; the description covers mode behavior, merge semantics, validation, and the optional optimization pass. It lacks only preconditions (permissions, whether active workflows can be edited mid-run) which the description leaves to 'active-lead safety remains enforced by the workflow backend'.

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?

With only 33% schema description coverage, the description does the heavy lifting: it explains mode semantics, the graph-vs-patch relationship, per-node config merging (only sent keys change, null clears), and when patch.edges replaces the edge set. workspaceId is left to the schema, which already documents it thoroughly.

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?

States a specific verb (patch or replace), resource (one workflow graph), and atomicity guarantee. This is clearly distinguished from the sibling campaignstack_edit_workflow, which edits the workflow itself rather than its graph structure.

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

Usage Guidelines4/5

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

Gives precise operational guidance on choosing between the two modes: 'replace supplies the full non-anchor graph' vs 'patch starts from the current non-anchor graph'. It does not, however, state when to prefer one mode over the other or warn against calling this on an active workflow.

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