Skip to main content
Glama
GautamVhavle

Universal JSON Agent MCP

by GautamVhavle

export_csv

Exports an array of objects from a loaded JSON document to a CSV file, using all keys as columns or a specified field list; nested values are saved as JSON strings.

Instructions

Export an array of objects to a CSV file.

If fields is omitted, all keys found across all objects are used as columns. Nested values (dicts, arrays) are serialized as JSON strings in the CSV.

Args: alias: The alias of the loaded document. path: Dot-notation path to the array of objects. output_path: File path for the output CSV. fields: Optional list of column names to include.

Returns: Confirmation with file path, row count, and column count.

Input Schema

NameRequiredDescriptionDefault
pathYes
aliasYes
fieldsNo
output_pathYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

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

No annotations exist, so the description carries the full burden and does add real context: default column derivation from all keys, JSON-string serialization of nested dicts/arrays, and what the confirmation contains. It omits what happens if output_path already exists (overwrite? error?) and any failure mode when path does not point at an array, which matters for a tool that writes a file.

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 one-line purpose, then defaults/serialization behavior, then Args, then Returns — a sensible order with no filler. The Returns block is largely duplicated by the existing output schema, the only mild waste.

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 file-writing export tool with an output schema present, the description covers input meaning, default column behavior, nested-value handling, and result shape. Missing only edge-case behavior: overwrite semantics on existing output_path and what occurs if the target path resolves to a non-array.

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?

With 0% schema description coverage, the Args block is the only documentation and it does compensate: 'alias of the loaded document', 'dot-notation path to the array of objects', and fields as an optional column list all add meaning beyond bare types. It stops short of specifying path syntax examples or whether output_path is relative to any working directory.

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 ('Export an array of objects to a CSV file') plus the source scope (dot-notation path inside a loaded document alias). This cleanly separates it from the sibling export_json without needing to name it.

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 implied by the name and by the presence of export_json as a sibling, but the description never says when to prefer this over export_json or what preconditions apply (e.g. that alias must be loaded). The 'if fields is omitted' sentence is about behavior, not tool selection.

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