Skip to main content
Glama

Count matching permits

count_permits
Read-only

How many permits match a search (area, category, city, zip, distance, multi-trade projects, dates, minimum value) before paying for the records. Free.

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": {
      "jurisdiction": "<jurisdiction>"
    },
    "name": "count_permits"
  }
}

Input Schema

NameRequiredDescriptionDefault
zipNo
cityNoCity name, case-insensitive
nearNoOnly permits near a zip code in the area or a "lat,lng" point
sinceNoIssued on or after (YYYY-MM-DD)
untilNoIssued on or before (YYYY-MM-DD)
categoryNoPermit category, e.g. roof, pool, solar, hvac, new_residential
minValueNoMinimum job valuation in USD
multiTradeNoOnly permits at addresses with another type of permit within 90 days (usually bigger projects)
radiusMilesNoRadius around near, in miles
jurisdictionYesArea id, e.g. new-york-ny, miami-dade-fl. Use list_coverage for names.
includeRenewalsNoInclude New York renewals of existing permits (left out by default)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / multiTrade
      Added value: +{
      +  "description": "Only permits at addresses with another type of permit within 90 days (usually bigger projects)",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / near
      Added value: +{
      +  "description": "Only permits near a zip code in the area or a \"lat,lng\" point",
      +  "pattern": "^(\\d{5}|-?\\d{1,3}(\\.\\d+)?,\\s*-?\\d{1,3}(\\.\\d+)?)$",
      +  "type": "string"
      +}
    • addedInput schema / properties / radiusMiles
      Added value: +{
      +  "default": 5,
      +  "description": "Radius around near, in miles",
      +  "maximum": 50,
      +  "minimum": 0.1,
      +  "type": "number"
      +}
  2. Changed1 schema field changed
    • addedInput schema / properties / includeRenewals
      Added value: +{
      +  "description": "Include New York renewals of existing permits (left out by default)",
      +  "type": "boolean"
      +}
  3. First observed

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false. The description adds genuinely new behavioral context beyond them: this call is free and records themselves are paid — a pricing/cost trait an agent needs to plan calls. It omits jurisdiction-dependency caveats and return format, keeping it below a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single sentence fragment with zero waste; the resource and filter scope are front-loaded and the free/paid distinction lands at the end. Nothing repeats the title or name unnecessarily.

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 an 11-parameter count tool with strong schema coverage and no output schema, the description correctly signals a count result and the free-preview economics. It could note that jurisdiction is required and how results relate to list_coverage, but nothing critical is missing.

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 91%, so the schema already carries nearly all parameter meaning. The description's filter list mirrors the schema fields without adding syntax, defaults, or constraints beyond it, so baseline 3 applies.

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?

States a specific verb+resource ('How many permits match a search') and enumerates the filter dimensions, making it clearly distinct from the record-returning siblings. It does not name search_permits explicitly, so the differentiation is implied rather than stated.

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?

'before paying for the records. Free.' implies the usage pattern (count first, then pay for records) but never names the alternative tool (search_permits) or states when not to use this. The context is inferable rather than explicit.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources