Skip to main content
Glama
gander-tools

OpenStreetMap Tagging Schema MCP Server

by gander-tools

Convert Flat Text to JSON

flat_to_json

Convert OSM tags from key=value text format to a clean JSON object. Handles whitespace, comments, and empty lines. Use this input converter to parse flat tag lists for AI workflows.

Instructions

Convert OpenStreetMap tags from flat text format (key=value per line) to JSON object format. This is an INPUT CONVERTER for AI workflows - use it FIRST when you receive tags in flat text format and need to work with them as a JSON object. Handles various text formats including key=value pairs (one per line), whitespace variations, empty lines, and comments (lines starting with #). Returns a clean JSON object with all parsed tags. Essential for processing OSM data from text exports, iD editor output, or JOSM exports.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsYesTags in flat text format with key=value pairs, one per line (e.g., "amenity=restaurant\nname=Test Cafe\ncuisine=italian"). Empty lines and lines starting with # are ignored. Whitespace around keys and values is trimmed automatically.
Behavior3/5

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

With no annotations, the description must carry behavioral disclosure. It explains handling of whitespace, empty lines, comments, and output format. Does not detail error handling or limitations, but covers essential behaviors.

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?

Sentences are generally concise and front-loaded with the main action. Minor redundancy in mentioning AI workflows and essential processing, but overall efficient.

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?

For a simple one-parameter converter without output schema, the description adequately covers input variants, use cases, and output nature. Could mention return type explicitly, but sufficient.

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 100%, so baseline is 3. The description reinforces input format details already in schema, adding context like ignoring comments and trimming whitespace, but no significant new meaning.

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?

The description clearly states the tool converts flat text (key=value per line) to JSON object format. It specifies the exact input format and output, distinguishing it from siblings like json_to_flat.

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 advises using it FIRST when receiving flat text tags, positioning it as an input converter. Mentions specific sources like OSM exports. Lacks explicit when-not-to-use or alternatives, but context suffices.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/gander-tools/osm-tagging-schema-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server