Skip to main content
Glama

list_leads

Read-only

List leads for the current tenant. Filters: search (title/email/phone/best_phone — a search term that looks like a NUMBER is additionally matched against the last nine digits of phone, best_phone and fax, so '017612345678' finds a lead stored as '0176 12345678'. To identify a CALLER use find_by_phone instead: it also covers contacts, accounts and the call history, and states how sure it is), category (exact, case-insensitive), status, campaign_id, no_campaign (true = only leads in no campaign), owner_id, min_score (0-100), stale_days (last activity older than N days). order_by: score|last_activity|created (default score). Returns category + score + last_activity_at. Unless include_memory=false, each lead also carries memory[] (its AI-memory items — any note attached to the lead, newest first, each trimmed to ~memory_tokens total per lead) and memory_truncated (true if some notes/text were omitted for size). For a COMPLETE, untruncated pull of every lead's full fields + all memory + nested contact/account, use export_leads instead.

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

Input Schema

NameRequiredDescriptionDefault
limitNoMax rows (default 20, max 100)
customNoFilter on lead custom fields (list_custom_fields entity 'leads'): { key: value } — value = equals (multiselect: contains), array = any of (multiselect: contains all), null = empty. E.g. { "stufe": "A", "marken": ["KTM"] }.
offsetNoPagination offset (default 0)
searchNoFree-text search term
statusNoOnly entries with this status
categoryNoExact category match (case-insensitive), e.g. 'dgnb'
order_byNoscore | last_activity | created
owner_idNoID of the owner (user)
min_scoreNoOnly leads with at least this score (0-100)
stale_daysNoOnly leads whose last activity is older than N days
campaign_idNoID of the campaign
no_campaignNoOnly leads not assigned to any campaign
memory_tokensNoApprox max tokens of memory per lead (default 200, max 1000); older entries cut off
include_memoryNoAttach recent AI memory per lead (default true)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / properties / campaign_id / description
      Added value: +"ID of the campaign"
    • addedInput schema / properties / min_score / description
      Added value: +"Only leads with at least this score (0-100)"
    • addedInput schema / properties / owner_id / description
      Added value: +"ID of the owner (user)"
    • addedInput schema / properties / search / description
      Added value: +"Free-text search term"
    • addedInput schema / properties / status / description
      Added value: +"Only entries with this status"
  2. First observed

TDQS

A4.6/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, so safety is covered. The description adds real behavioral context beyond that: default memory attachment, per-lead token trimming, and the memory_truncated flag signaling partial data. It stops short of describing pagination behavior or result-size limits, which keeps it from 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.

Conciseness4/5

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

Dense but front-loaded: the core purpose is first, the filter list second, and the two sibling escape hatches at the end. The long parentheticals around search matching cost some readability, but every clause carries information an agent would otherwise have to guess.

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 14 parameters, no output schema and nested memory objects, the description does the heavy lifting: it states what is returned (category, score, last_activity_at), what the nested memory array contains, and how truncation is signaled. An agent has enough to call this correctly and interpret the response.

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 100%, so the baseline would be 3, but the description genuinely extends the schema by explaining that a numeric-looking search term also matches the last nine digits of phone/best_phone/fax with a worked example. It also clarifies no_campaign and the memory_tokens trimming effect, though it leaves custom, limit and offset purely to 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 scoped to the tenant, then enumerates every filter and the ordering options. An agent can immediately tell this is a filtered list of leads, and the closing sentence names export_leads as the complete-pull alternative.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes the agent away from this tool for caller identification ('To identify a CALLER use find_by_phone instead') and away from it for full-fidelity data ('use export_leads instead'), giving the condition that selects each sibling. Nothing about when-not-to-use is left to inference.

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.