Skip to main content
Glama
Hydrata MCP Server

Hydrata MCP Server

Official
by Hydrata

Divide, merge or move sub-catchments by hand

edit_sub_catchments

Adjust draft sub-catchments manually by dividing, merging, moving nodes, adding forced points, or undoing edits; incorporate culverts and diversions without changing the confirmed version.

Instructions

Change sub-catchments by hand on the draft: divide a sub-catchment, merge two, move a node, add a forced point, undo a dragged boundary, or undo another edit made by hand (its seq), or take the culverts or the diversions in (the diversions: a preview first, then preview false). An edit after a confirm starts a new draft; the confirmed version never changes. The answer names the sub-catchments measured again. Ids change when an edit writes the draft again: read the set again with get_sub_catchments before the next edit.

make_link changes nothing: it is filed as a proposal a person accepts or rejects on the map. Tell the user it is waiting and give them the link (ui_url). It is refused when filed if the link would make a loop, or if the water of the two sub-catchments already ends up in one place (the read lists no note for such a pass). To propose a new boundary, use propose_sub_catchment_boundary.

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": {
      "project_id": "<project_id>",
      "sub_catchments_id": "<sub_catchments_id>",
      "kind": "<kind>"
    },
    "name": "edit_sub_catchments"
  }
}

Input Schema

NameRequiredDescriptionDefault
latNoFor divide, move_node and add_forced_point: latitude (WGS84)
lonNoFor divide, move_node and add_forced_point: longitude (WGS84)
seqNoFor undo: the edit's `seq` (get_sub_catchments, version.hand_edits)
kindYesdivide: a new node on the stream of the sub-catchment at lon/lat (it divides there; aim at a stream get_sub_catchments' streams_of gives); merge: two sub-catchments of one node, or one with the one its water runs into (sub_catchment_ids); move_node: node_id to lon/lat; add_forced_point: a node exactly at lon/lat; undo_drag: take back a dragged boundary (drag_id); undo: take back one other edit made by hand (seq, from the read's hand_edits), as the map's Undo last and History do; make_link: PROPOSE that a 'can share water' note (note_id) becomes a link, with a reason: a person accepts it on the map; take_culverts_in: when the read says 'Culverts have changed since these were created.', place the project's culverts as they are now (the draft is made again, its edits by hand kept; after a confirm, a new draft); take_diversions_in: when the read says 'Diversions changed in step 2.', make the sub-catchments again with the line's diversions as they are now, every edit made by hand made again (after a confirm, a new draft). It previews first (preview, default true).
reasonNoFor make_link: one or two sentences the person reads before accepting (what you saw, and why).
drag_idNoFor undo_drag: the dragged boundary's `drag_id`
node_idNoFor move_node: the node's id
note_idNoFor make_link: the note's id (get_sub_catchments, a sub-catchment's notes)
previewNoFor take_diversions_in: true (default) stores nothing and answers which edits are made again and which cannot be, each with its sentence; false takes the diversions in.
node_kindNoFor add_forced_point: a forced point (default) or a culvert inletforced_point
project_idYesThe project ID (Editor rights)
sub_catchment_idsNoFor merge: the ids of the two sub-catchments
sub_catchments_idYesThe set to change: its `sub_catchments_id`

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.2.6

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the annotations it discloses the draft/confirm lifecycle ('An edit after a confirm starts a new draft; the confirmed version never changes'), the fact that ids change on every write and must be re-read, refusal conditions for `make_link` (loops, water already co-located), and that proposals wait for a human on the map. It also warns that `make_link` changes nothing while other kinds do, which the annotations alone (destructiveHint=false, idempotentHint=false) cannot convey.

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?

The opening sentence does front-load the mode list, which is good for a 9-mode tool, but the prose is a run-on with nested parentheticals ('or take the culverts or the diversions in (the diversions: a preview first, then preview false)') that force re-reading. Given the tool's complexity some length is justified, but bullet-style mode grouping would be substantially clearer.

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 13-parameter, 9-mode mutation tool this covers what an agent needs: mode selection, per-mode prerequisites, draft vs confirmed semantics, id invalidation and re-read requirement, refusal conditions, human-approval flow, and preview behavior. An output schema exists, and the description still notes the response names the re-measured sub-catchments, so nothing material is missing.

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 100%, so the baseline is 3; the description earns a bump by adding procedural meaning the schema fields do not carry, notably the 'preview first, then preview false' sequence for `take_diversions_in` and the provenance of `seq` from `version.hand_edits`. It still does not add much beyond the schema for lat/lon, node_id, or drag_id, which the enum descriptions already explain.

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 and resource ('Change sub-catchments by hand on the draft') and then enumerates all nine operations (divide, merge, move node, forced point, undo_drag, undo, make_link, take_culverts_in, take_diversions_in), so an agent can map its intent to a `kind` value immediately. It also explicitly separates itself from `propose_sub_catchment_boundary` and clarifies that `make_link` only files a proposal, which distinguishes it from the sibling tools.

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?

Each mode carries its own trigger condition, e.g. `take_culverts_in` applies 'when the read says Culverts have changed since these were created' and `take_diversions_in` when 'Diversions changed in step 2.' It names the alternative tool for boundary proposals, states the two-step preview-then-commit workflow for diversions, and gives the required pre-call step ('read the set again with get_sub_catchments before the next edit').

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