Skip to main content
Glama

leads_bulk_add_to_segment

The primary way to move prospects from the shared discovery database into the user's workspace. Provide the target segment sqid and a list of {company_guid, person_guid} pairs — person_guid may be null for company-only leads. The endpoint creates one Lead per pair (deduplicated against existing leads by email/linkedin), adds them to the segment, and returns num_created.

Cost. Charges ADD_LEAD_FROM_DISCOVERY per newly-created lead (not per duplicate skip); the current rate is in billing_pricelist. Pre-check with billing_balance for batches >1k.

Async. Currently synchronous for reasonable batch sizes (<500). For larger imports, prefer the CSV import wizard (imports_leads_create → _analyze_create → _execute_create) which returns a task_sqid and runs in the background.

Typical flow. companies_search → company_persons_list → pick the people you want → call this endpoint with their GUIDs.

Method: POST /api/v1/workspaces/{workspace_sqid}/segments/add-leads/

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_bulk_add_to_segment"
  }
}

Input Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

No annotations are supplied, so the description carries the full burden, and it discharges most of it: billing cost per newly-created lead with duplicate skips not charged, the pricing lookup location, sync-vs-async execution boundary, dedup key (email/linkedin), and the returned field num_created. It stops short of auth/permission requirements, per-pair error behavior on partial failures, or what happens if the target segment sqid is invalid — meaningful gaps for a mutating bulk endpoint.

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?

Front-loaded one-line purpose followed by bolded Cost / Async / Typical flow blocks, each answering a distinct question an agent would otherwise have to guess. Every sentence earns its place; nothing is redundant restatement of the name.

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 a charged, deduplicating bulk mutation with no annotations and no output schema, the description covers cost, execution mode, dedup behavior, and the return field — unusually complete. The remaining defect is the empty input schema, which makes the prose-described payload uncallable as published and is not something the description can repair.

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?

Parameter count is 0, which normally earns a 4 baseline, but the description explicitly instructs the caller to supply a segment sqid and a list of {company_guid, person_guid} pairs while the schema declares additionalProperties:false with no properties — an agent following the prose would have its arguments rejected. The description does add real semantics (person_guid nullable for company-only leads, dedup by email/linkedin), but the contract it describes is unenforceable against the published 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?

"The primary way to move prospects from the shared discovery database into the user's workspace" states a specific verb (move/add), a resource (prospects/leads), scope (bulk, into a segment), and the source system — an agent can distinguish it from lead_add_to_segment and leads_bulk_add_to_segment_bulk. It also names the operation's result (one Lead per pair, returns num_created), so the effect is unambiguous.

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?

Explicit when-to-use (batch <500, GUIDs from company_persons_list), explicit when-not-to-use (larger imports should go through imports_leads_create → _analyze_create → _execute_create), and a prerequisite check (billing_balance for batches >1k). It even supplies the canonical call chain companies_search → company_persons_list → this endpoint, which is exactly the routing guidance an agent needs.

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.