Skip to main content
Glama

get_calls_by_duration

Read-only

Use when the user asks for power-dialer calls that lasted longer than X seconds/minutes. Requires callDurationGreaterThanSeconds. Omit contactId to search ALL calls visible to the user, or provide contactId to restrict results to one contact. Returns newest matching calls with exact durationSeconds, contact, disposition, note, campaign/list context, and speaker-labeled transcription when available. Duration is strictly greater than the threshold using the call recording's length; calls without a recording are excluded. Read-only and paginated via page and limit (default 20, max 50).

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": {
      "callDurationGreaterThanSeconds": "<callDurationGreaterThanSeconds>"
    },
    "name": "get_calls_by_duration"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageNo
limitNo
contactIdNoOptional contact id. Omit it to search all calls visible to the requesting user.
callDurationGreaterThanSecondsYesReturn only calls whose recorded duration (the call recording's length) is strictly greater than this whole number of seconds. Calls without a recording are excluded.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already establish read-only and non-destructive, and the description goes well beyond them: strict greater-than (not greater-or-equal) comparison, exclusion of calls lacking a recording, pagination defaults and hard maximum, and the exact fields returned. These are the details an agent needs to avoid off-by-one threshold errors and pagination surprises.

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?

Five tight sentences, front-loaded with the triggering condition, then parameter routing, then return shape, then comparison semantics and pagination. No filler and no sentence that could be deleted without losing 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 no output schema, the description carries the return-value burden itself and does so by enumerating durationSeconds, contact, disposition, note, campaign context, and transcription. For a four-parameter read tool with annotations covering safety, nothing an agent needs to call it correctly 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 only 50%, and the description closes most of that gap by explaining page and limit behavior (default 20, max 50) and reiterating the omit-vs-provide semantics of contactId. It adds real meaning rather than restating the schema, though it does not explain the 0–86400 bound on the duration parameter.

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 and resource plus the defining filter: calls whose duration exceeds a threshold in seconds. The scope trigger ("power-dialer calls that lasted longer than X") makes the tool immediately recognizable, but it never names a sibling such as get_call_history to disambiguate against a general call listing.

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?

Opens with an explicit use-when condition tied to the user's phrasing, and gives concrete routing for the contactId parameter (omit to search all visible calls, provide to narrow to one contact). It stops short of stating when a different tool would be a better choice.

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.