Skip to main content
Glama
ny-data-registry-mcp

ny-data-registry-mcp

search_datasets

Read-only

Find open data across New York's state, county, city and agency portals by searching dataset titles, tags and column names, then filter by topic, place, portal, format or update date.

Instructions

Search dataset titles, descriptions, tags and column names across the harvested Socrata and ArcGIS portals in New York (needs the harvested index). Filter by topic, place, portal, platform family, download format (csv, geojson, shapefile, kml, api, xlsx) or last-updated date. topic is one of 24 shared topics (list_topics), assigned from each dataset's own categories, tags and department; a dataset can have several. Give a query, a topic, or both; a topic alone lists that topic, most-viewed first. Rows carry their topic ids. One call gives the whole answer. total_matches is the true number of matching datasets. When they all fit, the reply lists them. When they do not, the reply counts every match by portal (auto_grouped: true; top titles when room; groups_size_note says what was cut), lists the best-ranked rows that fit, and writes every match to a CSV (export.path, export.rows; also a resource_link). Use group_by to summarize by entity, county or platform_family instead. Rows are compact (id, name, portal, type, update date, link, formats); detail: 'full' adds description, API endpoint, views, column count and, for Socrata, the domain + 4x4 to hand to the socrata MCP. Replies aim for about 20 KB. Each reply also lists registry portals the index does not search, so no result is not proof that no data exists. When the index is more than 14 days old (NY_DATA_INDEX_STALE_DAYS), the reply carries index_note saying so and how to update it.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "search_datasets"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMost rows to list in the reply. Default 10. More matches than this are summarized by portal and written to the CSV. Not with group_by
placeNoCounty, city, borough or region. Statewide portals are always included
queryNoe.g. 'rodent', 'tax parcels', 'lead service lines'. Optional when topic is given
topicNoOne of the 24 shared topics (list_topics has names and counts), e.g. 'housing', 'transportation', 'elections'
detailNo'compact' (default) or 'full'. Not with group_by
exportNo'auto' (default): write the CSV of every match when the reply cannot list them all. 'always' or 'never'
formatNocsv, json, geojson, shapefile, kml, api, arcgis, xlsx, geopackage, pdf
offsetNoRarely needed: skip this many ranked rows to page by hand (next_offset). Turns off the auto-summary and the automatic CSV. Not with group_by
portalNosource_id, registry_id (every site of that government) or part of a portal name
group_byNoGroup every match by portal, entity, county or platform_family, with counts and top titles per group, instead of a page of results
top_per_groupNoTitles listed per group with group_by. Default 3
updated_sinceNoYYYY-MM-DD
platform_familyNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv0.4.0
    • changedInput schema / properties / portal / description
      Previous value: -"source_id or part of a portal name"New value: +"source_id, registry_id (every site of that government) or part of a portal name"
    • changedInput schema / properties / query / description
      Previous value: -"e.g. 'rodent', 'tax parcels', 'lead service lines'"New value: +"e.g. 'rodent', 'tax parcels', 'lead service lines'. Optional when topic is given"
    • addedInput schema / properties / topic
      Added value: +{
      +  "description": "One of the 24 shared topics (list_topics has names and counts), e.g. 'housing', 'transportation', 'elections'",
      +  "enum": [
      +    "environment",
      +    "government",
      +    "transportation",
      +    "landuse",
      +    "water",
      +    "education",
      +    "boundaries",
      +    "finance",
      +    "recreation",
      +    "health",
      +    "economy",
      +    "utilities",
      +    "safety",
      +    "buildings",
      +    "basemaps",
      +    "demographics",
      +    "social",
      +    "housing",
      +    "property",
      +    "quality_of_life",
      +    "climate",
      +    "elections",
      +    "agriculture",
      +    "sanitation"
      +  ],
      +  "type": "string"
      +}
    • removedInput schema / required
      Removed value: -[
      -  "query"
      -]
  2. Changed6 schema fields changedv0.3.0
    • addedInput schema / properties / detail
      Added value: +{
      +  "description": "'compact' (default) or 'full'. Not with group_by",
      +  "enum": [
      +    "compact",
      +    "full"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / export
      Added value: +{
      +  "description": "'auto' (default): write the CSV of every match when the reply cannot list them all. 'always' or 'never'",
      +  "enum": [
      +    "auto",
      +    "always",
      +    "never"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / group_by
      Added value: +{
      +  "description": "Group every match by portal, entity, county or platform_family, with counts and top titles per group, instead of a page of results",
      +  "enum": [
      +    "portal",
      +    "entity",
      +    "county",
      +    "platform_family"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / limit / description
      Added value: +"Most rows to list in the reply. Default 10. More matches than this are summarized by portal and written to the CSV. Not with group_by"
    • addedInput schema / properties / offset
      Added value: +{
      +  "description": "Rarely needed: skip this many ranked rows to page by hand (next_offset). Turns off the auto-summary and the automatic CSV. Not with group_by",
      +  "maximum": 5000,
      +  "minimum": 0,
      +  "type": "integer"
      +}
    • addedInput schema / properties / top_per_group
      Added value: +{
      +  "description": "Titles listed per group with group_by. Default 3",
      +  "maximum": 10,
      +  "minimum": 0,
      +  "type": "integer"
      +}
  3. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Goes well past the readOnly/openWorld annotations by disclosing the full response contract: total_matches, auto-summary with auto_grouped and groups_size_note, best-ranked rows, CSV written to export.path plus a resource_link, a ~20KB reply budget, offset disabling auto-summary, and index_note driven by NY_DATA_INDEX_STALE_DAYS. For a read-only search this is unusually complete behavioral disclosure.

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?

Purpose and search fields are front-loaded, then result behavior, then parameter-specific notes, so the agent hits the important material first. The single dense paragraph runs ~250 words and a few clauses (e.g. the 4x4 handoff detail) could be trimmed, but nearly every sentence carries actionable information.

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?

With 13 optional parameters and no output schema, the description carries the burden of explaining return values and does so thoroughly: compact vs full rows, the complete-listing vs summarized+CSV branch, grouping behavior, and staleness signaling. Nothing an agent needs in order to call this correctly or interpret the reply 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 already 92%, so the baseline is 3, but the description adds real meaning: topic comes from 24 shared topics assigned from each dataset's own categories/tags/department, a dataset may have several, and rows carry topic ids. It also explains that detail:'full' adds description, API endpoint, views, column count and the Socrata domain/4x4 handoff. Less is said about place or updated_since beyond the schema.

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 and resource plus explicit search fields: 'Search dataset titles, descriptions, tags and column names across the harvested Socrata and ArcGIS portals in New York'. Scope (NY, harvested index) and the prerequisite ('needs the harvested index') are stated up front, so an agent can distinguish it from sibling lookup tools like find_sources or what's_new.

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?

Gives concrete selection rules inside the tool: 'Give a query, a topic, or both; a topic alone lists that topic, most-viewed first', and 'Use group_by to summarize ... instead'. It also routes to list_topics for topic names and warns that 'no result is not proof that no data exists'. It does not contrast itself with sibling tools like find_sources or check_source, so it falls short of full when/when-not coverage across alternatives.

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