Skip to main content
Glama

upsert_workflow_knoten

DestructiveIdempotent

Create or update a node of a workflow, matched by schluessel (for imported Pipedrive workflows the schluessel is the stage/phase id). Required: workflow_id, schluessel; name for new nodes. Optional: reihenfolge, art (start|schritt|ende), agent_id (responsible agent), agent_info (what an agent must know/do/check here — shown by get_workflow_status), ausloeser (Trigger when an object ENTERS the node: {art:'keine'} | {art:'mensch', an:<user_id>, nachricht?, wichtigkeit?(0-100), antworten?:[…]} → a handoff in that person's delegation inbox (website/app, no mail/WhatsApp) | {art:'agent', agent_id?, nachricht?} → a task for the agent (defaults to the node's agent_id). nachricht may use {{titel}}, {{objekt_id}}, {{knoten}} and any data field like {{Experte}}. nicht_wenn_offen:[thema,…] skips the trigger while the object already has an open handoff with one of these themes (e.g. the asbest automation's laborder, berichtspruefung, versand), so nothing is duplicated.), erledigt_wenn (Condition JSON over the object's data: {} = always; {feld, op, wert} with op eq|ne|in|nicht_in|enthaelt|exists|leer|gt|gte|lt|lte (feld is a column/field name or dotted path; for Pipedrive deals custom fields work by their NAME, e.g. 'Experte'); combine with {alle:[…]}, {eines:[…]}, {nicht:{…}}. — when the step counts as done), max_tage (overdue after n days), signale (how to recognise — from ANY mailbox of the tenant, whoever did it — that an object REACHED this step or is DONE with it: [{name, von?, an?, betreff?, text? (case-insensitive regexes; at least one), wirkung:'erreicht'|'erledigt', schieben?:boolean (default false: only record the evidence and close the open handoffs of the steps done; true: also move the object forward, in Pipedrive too — never backwards), schliesst_themen?:[thema,…] (extra handoff themes to close, e.g. laborder, berichtspruefung, versand), zuordnung?:'muster'|'adresse' (adresse: for mails without the id, the object is found by street + house number of the open deals; only a unique hit counts)}]. The object id comes from the mail via the workflow's objekt_muster (deals: 'DN 1000'). Checked every 5 minutes over the last 48 h; each hit once. Replaces the node's whole list), rollen (who does the step today and what code/AI could take over: {ausloeser, aktion (plain text), wer_heute:{mensch, code, ki} (plain text), heute:{mensch, code, ki} and potenzial:{mensch, code, ki} (work share in percent, each summing to 100), potenzial_text, aufwand_min (total effort per object today, weight for totals), anteil_objekte (0–1, share of objects passing the step), quelle ('schaetzung'|'gemessen')}. get_workflow returns the weighted totals), vorbereitung (prepare the step's work so a person only says yes/no/adjust (object or list): {name?, wann:'eintritt' (on entering; only objects that entered within the last 2 days) | 'nach_tagen' (tage:[7,21] → one preparation per threshold, counted from entering the node) | 'signal' (after a signal hit at this node), durch:{art:'agent', agent_id? (default the node's agent), auftrag:'what to prepare'} (the agent gets a task and delivers with set_vorbereitung) | {art:'code', regel:'nachfass_mail'} (template follow-up mail to the deal person), an:<user_id> (who decides), an_offene_uebergabe?:thema (instead attach the result text to the object's open handoff with this theme, e.g. berichtspruefung), frage?, antworten?:[{text, aktion:'mail_senden'|'stufe'|'nichts'|'anpassen', stufe?:<node schluessel, forward only>}] (default with a mail: 'Freigeben und senden'; 'Nein' and 'Anpassen: …' are always offered), wichtigkeit?(0-100), nicht_wenn_offen?:[thema,…]}. Nothing is ever sent to a customer without the person's explicit answer. Withdrawn automatically when the object leaves the node or an 'erledigt' signal hits; null removes it).

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": {
      "workflow_id": "<workflow_id>",
      "schluessel": "<schluessel>"
    },
    "name": "upsert_workflow_knoten"
  }
}

Input Schema

NameRequiredDescriptionDefault
artNoNode type: start, regular step or end
nameNoName of the workflow knoten
rollenNoWho does the step today and what code/AI could take over, with work shares
signaleNoMail patterns that show an object reached or finished this step; replaces the list
agent_idNoID of the agent
max_tageNoDays after which an object at this node counts as overdue
ausloeserNoTrigger fired when an object enters the node (keine, mensch or agent)
agent_infoNoWhat an agent must know, do or check at this node
schluesselYesKey of the node within the workflow; for Pipedrive the stage/phase ID
reihenfolgeNoPosition of the node in the workflow order
workflow_idYesID of the workflow
vorbereitungNoObject or list of objects, null to remove.
erledigt_wennNoCondition JSON over the object's data that marks the step as done

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / vorbereitung / type
      Added value: +[
      +  "object",
      +  "array",
      +  "null"
      +]
  2. Changed12 schema fields changed
    • addedInput schema / properties / agent_id / description
      Added value: +"ID of the agent"
    • addedInput schema / properties / agent_info / description
      Added value: +"What an agent must know, do or check at this node"
    • addedInput schema / properties / art / description
      Added value: +"Node type: start, regular step or end"
    • addedInput schema / properties / ausloeser / description
      Added value: +"Trigger fired when an object enters the node (keine, mensch or agent)"
    • addedInput schema / properties / erledigt_wenn / description
      Added value: +"Condition JSON over the object's data that marks the step as done"
    • addedInput schema / properties / max_tage / description
      Added value: +"Days after which an object at this node counts as overdue"
    • addedInput schema / properties / name / description
      Added value: +"Name of the workflow knoten"
    • addedInput schema / properties / reihenfolge / description
      Added value: +"Position of the node in the workflow order"
    • addedInput schema / properties / rollen / description
      Added value: +"Who does the step today and what code/AI could take over, with work shares"
    • addedInput schema / properties / schluessel / description
      Added value: +"Key of the node within the workflow; for Pipedrive the stage/phase ID"
    • addedInput schema / properties / signale / description
      Added value: +"Mail patterns that show an object reached or finished this step; replaces the list"
    • addedInput schema / properties / workflow_id / description
      Added value: +"ID of the workflow"
  3. First observed

TDQS

A4.1/5.0
Behavior5/5

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

Beyond the annotations, the description discloses substantial behavior: triggers fire on entry and land in a delegation inbox with no mail/WhatsApp, signals are 'Checked every 5 minutes over the last 48 h; each hit once', vorbereitung is 'Withdrawn automatically when the object leaves the node', and 'Nothing is ever sent to a customer without the person's explicit answer'. These details are consistent with destructiveHint=true and idempotentHint=true rather than contradicting them.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Required parameters are front-loaded, but the remainder is a single run-on paragraph with deeply nested parentheticals, brace literals and inconsistent delimiters, making it hard to scan. For a 13-parameter tool with nested objects the length is defensible, yet the structure costs readability.

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?

The tool is complex (nested objects, 13 parameters, no output schema), and the description covers node creation, trigger, signal matching and preparation lifecycle thoroughly, including where results surface ('get_workflow returns the weighted totals'). It stops short of describing the upsert response or any permission/precondition requirements, which leaves a small but real gap.

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

Parameters5/5

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

Even with 100% schema coverage, the description adds far more than the schema: it explains the ausloeser variants (keine/mensch/agent) and their inbox consequences, the erledigt_wenn operator set and dotted-path/field-name resolution, the signale regex/wirkung/schieben/zuordnung options, and the rollen percent splits. The terse schema descriptions would not let an agent populate these nested structures correctly on their own.

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 opening clause gives a specific verb and resource ('Create or update a node of a workflow') plus the match key ('matched by schluessel'), so an agent knows exactly what is written and how identity is resolved. It implicitly separates itself from upsert_workflow by scoping to a single node, but never names a sibling or states the boundary explicitly.

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?

Usage is only implied: required fields are listed ('workflow_id, schluessel; name for new nodes') and side effects such as 'Replaces the node's whole list' or 'null removes it' hint at upsert semantics, but there is no explicit when-to-use/when-not guidance or routing to alternatives like upsert_workflow or set_workflow_kanten.

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.