Skip to main content
Glama
OpenStreetMap MCP

OpenStreetMap MCP

osm_delete_element

Destructive

Delete a node, way, or relation from OpenStreetMap using its current version and changeset; the request fails if the element is still referenced by another way or relation.

Instructions

Delete an element. Fails with 412 if it is still referenced by a way or relation. Nodes need their current lat/lon. Returns the new version. Edits are public and attributed to the authenticated OSM user. Follow the OSM editing guidelines; use OSM_ENV=dev to practise on the sandbox server.

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": {
      "changeset_id": "<changeset_id>",
      "element": "<element>"
    },
    "name": "osm_delete_element"
  }
}

Input Schema

NameRequiredDescriptionDefault
elementYes
changeset_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/5.0
Behavior4/5

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

The annotations already declare destructiveHint=true, openWorldHint=true and readOnlyHint=false, so the safety profile is covered structurally. The description adds genuinely new behavioral facts beyond them: the specific 412 precondition, the requirement for current lat/lon on nodes, the return of a new version, and public, attributed edits — plus a sandbox escape hatch.

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?

Front-loaded with the action and the most important failure mode, then the node-specific requirement, then the return value and safety/attribution notes. Each clause carries information; the only mild padding is the OSM_ENV sandbox tip, which is still actionable for an agent testing edits.

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?

With no output schema, the description correctly supplies the return value ('the new version'), the auth/attribution model, and the principal failure mode. For a destructive write tool with a nested parameter object this is close to sufficient; it could still say what happens to a node's membership or whether a changeset must be open beforehand, but the caller can infer most of that from the sibling tool set.

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

Parameters3/5

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

Schema description coverage is reported at 0% for the top-level parameters, though the nested element object does carry field-level descriptions. The description adds real meaning the schema lacks for lat/lon ('Nodes need their current lat/lon' — implying the value must be current, not arbitrary), which partially compensates for changeset_id and the element wrapper being undocumented.

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 description opens with a specific verb+resource ('Delete an element') and is clear that it removes an existing OSM object. It never names its siblings (osm_update_element, osm_create_element), so the distinction between delete and update is only implicit in the verb, but an agent can still identify the operation unambiguously.

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?

It gives useful usage conditions: the caller must supply current lat/lon for nodes and must not delete objects still referenced by a way or relation (412). However, it does not state what to do instead in that failure case (e.g., detach from the parent first via osm_update_element) or when to prefer a changeset-based bulk upload (osm_upload_diff).

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