Skip to main content
Glama

Change a segment

flow_update_segment
Idempotent

Renames a segment or replaces its filter; a filter given replaces the whole filter, so start from the one flow_get_segment returns. Its members are worked out again after any change, a rename included. filters is one group, e.g. {"operator":"AND","conditions":[{"field":"city","operator":"equals","value":"Zagreb"}]}; a condition is {field, operator, value} or a nested group (5 levels at most). Fields: name, lastName, email, city, address, note (operators equals, notEquals, contains, notContains, startsWith, endsWith, isEmpty, isNotEmpty); status (VERIFIED, UNVERIFIED, INVALID_NUMBER) and gender (Male, Female, Non-binary, Unknown) with equals, notEquals, in, notIn; prefixCountryId, countryId, networkId with the same four, as ids (a country object from flow_get_segment is taken by its id); birthDate (YYYY-MM-DD) with equals, notEquals, before, after, between [from, to]. in and notIn take an array.

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": {
      "id": "<id>"
    },
    "name": "flow_update_segment"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesSegment id, from flow_list_segments
nameNo
brandIdNoThe id of the brand this change is for: the active brand (flow_whoami). Required when the connection covers several brands; the change is refused when another brand is active.
filtersNoThe whole new filter group; see the description

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

The annotations already declare the mutation and idempotency profile, yet the description still adds genuinely non-obvious behavior: the supplied filter replaces the entire existing filter, and membership is recomputed after any change including a rename. It does not discuss the brand-mismatch refusal or what the call returns, but the side-effect disclosures here are well above the annotation baseline.

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 decision-relevant facts (what changes, filter replacement, recompute) are front-loaded in the first sentence. The long semicolon-chained operator roster is dense and harder to scan than a list would be, but nearly every clause carries field or operator detail the agent cannot get from the schema.

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

Completeness3/5

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

For a 4-parameter nested mutation with no output schema, the filter grammar is covered exhaustively and name/id/brandId are already documented in the schema. The remaining gap is return behavior and error conditions, which are neither in an output schema nor in the description, so an agent cannot predict what comes back after a successful update.

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 75% and the filters parameter is an untyped free-form object, so the description does the heavy lifting: it gives a concrete filter example, defines condition shape, caps nesting at 5 levels, enumerates every queryable field with its permitted operators, and specifies value formats such as YYYY-MM-DD and array-taking in/notIn. Enumerated domain values (gender, status) are not in the schema, making this addition substantive rather than redundant.

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?

Opens with a specific verb pair and resource: 'Renames a segment or replaces its filter.' This immediately separates it from flow_create_segment, flow_delete_segment, and the getter sibling, and the reader knows exactly which two mutations the tool performs.

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?

Explicitly tells the agent to read the current filter first via 'start from the one flow_get_segment returns', which is real usage guidance tied to the replacement semantics. It stops short of naming when to choose this over flow_create_segment or of stating that at least one of name/filters should be supplied, so it is not a full when/when-not statement.

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