Skip to main content
Glama

Export leads as CSV

lead_export
Read-onlyIdempotent

Captured leads matching a filter, as a compact CSV block (one row per lead, one column per captured field). Filter by date range, agent, capture type, CRM sync status, origin, or a captured field's value (e.g. fieldKey City, fieldValue Pune). Capped at 500 rows; the reply says when it was cut short. Phone numbers appear in the same form as in the lead list. Read only.

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": "lead_export"
  }
}

Input Schema

NameRequiredDescriptionDefault
originNo
agentIdNoOnly leads captured by this agent (the agent's id)
endDateNoISO date, inclusive
maxRowsNoMost rows, default and maximum 500
fieldKeyNoA captured field name, e.g. "City"
startDateNoISO date, inclusive
fieldValueNoThe value that field must have; use with fieldKey
syncStatusNoCRM sync status, e.g. SYNCED, FAILED, NOT_CONFIGURED
captureTypeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / agentId / description
      Previous value: -"Only leads captured by this agent (agent_list id)"New value: +"Only leads captured by this agent (the agent's id)"
  2. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare read-only, idempotent, closed-world, non-destructive, so the safety profile is covered. The description adds genuinely useful behavior beyond that: the 500-row cap, the explicit notice when results are truncated, and that phone numbers keep the same representation as the lead list.

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?

Three tight sentences, front-loaded with the return shape, then filters, then the cap and fidelity caveat. Every clause carries information; nothing restates the title or annotations.

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?

There is no output schema, and the description compensates by specifying the CSV block's row/column structure, the truncation signal, and the phone-number representation. Combined with the annotations, an agent has everything needed to call and interpret it.

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 coverage is 78%, so most parameters are already documented, which sets the baseline at 3. The description adds the fieldKey/fieldValue pairing example (City / Pune) and enumerates usable filter dimensions, but repeats the 500-row limit and adds no syntax detail for dates, origin, or captureType.

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?

"Captured leads matching a filter, as a compact CSV block" names the resource (leads), the operation (export/retrieve filtered), and the return shape (CSV, one row per lead). It is clearly distinct from lead_list/lead_detail in format, though it never names a sibling to sharpen the contrast.

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 through the filter dimensions (date range, agent, capture type, sync status, origin, field value) and the export framing, but there is no explicit "use this when…" or "prefer lead_list for…" statement. An agent can infer the CSV-export case but gets no stated exclusion or prerequisite.

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.