Skip to main content
Glama
amocrm-mcp-prm

amocrm-mcp-prm

by m00zz

leads_summary

Aggregate CRM leads server-side into totals, won/lost/open counts, and breakdowns by pipeline, status, owner, loss reason, month, tag, or custom field, with filters for funnel and source reports.

Instructions

Aggregate leads server-side without returning them: totals, won/lost/open, and breakdowns by pipeline, status, responsible user, loss reason, month, tag, or a custom field. Accepts the same filters as list_leads. Use for funnel snapshots, loss-reason and source reports.

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

Input Schema

NameRequiredDescriptionDefault
group_byNoDimensions to break the count down by (default: pipeline + status). Each dimension is reported separately.
statusesNoFilter by statuses: array of {pipeline_id, status_id}
closed_toNoClosed at or before this date
max_pagesNoSafety cap on pages of 250 leads (default 40 = 10,000 leads)
created_toNoCreated at or before this date
updated_toNoUpdated at or before this date
closed_fromNoClosed at or after this date
pipeline_idNoFilter by pipeline ID
created_fromNoCreated at or after this date
updated_fromNoUpdated at or after this date
custom_field_idNoCustom field ID for group_by=custom_field (see list_custom_fields)
responsible_user_idsNoFilter by responsible user IDs

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.3.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the load, and it delivers the single most important behavioral fact: this aggregates server-side and does not return lead records, so the agent should not expect per-record output. It also implies a read-only computation. It does not mention permissions, rate limits, or how the grouping dimensions are combined beyond the schema's note.

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?

Two tight sentences, front-loaded with the core action and the non-returning constraint, then use cases. No filler or redundant restatement of the title.

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?

With 12 optional parameters and no output schema, the description must explain what comes back, and it does name the result shape (totals plus per-dimension breakdowns). It leaves unstated whether results are paginated or how multiple group_by dimensions are composed in the response, which is a minor remaining gap for a reporting tool.

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 100%, so every parameter including group_by, date ranges, and max_pages is already documented. The description's enumeration of breakdown dimensions mostly restates the group_by enum and adds no syntax or default detail beyond the schema. Baseline 3 applies.

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 ('Aggregate leads server-side') plus exactly what is computed ('totals, won/lost/open, and breakdowns by pipeline, status, responsible user, loss reason, month, tag, or a custom field'). The clause 'without returning them' immediately separates it from record-returning siblings like list_leads.

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 explicit use cases ('funnel snapshots, loss-reason and source reports') and ties filter behavior to list_leads, so an agent knows the filter semantics carry over. It stops short of an explicit 'use list_leads instead when you need individual records' exclusion, so the boundary is clear but not fully spelled out.

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